Using Ceph to host LXC Containers

Sep 19, 2019
5
0
6
65
Is it possible to use Ceph to host the disk of an LXC container ?
When I add Ceph as a cluster storage it is only available for "VZDump..", "ISO Images" , "Container template" and "Snippets".
I am using Proxmox 6, with ceph installed in the same cluster nodes using the web gui.
 
Is it possible to use Ceph to host the disk of an LXC container ?
yes.

When I add Ceph as a cluster storage it is only available for "VZDump..", "ISO Images" , "Container template" and "Snippets".

That's if you add a CephFS storage. If you add a Ceph RBD pool then you can place CTs and VMs on that one.
(CephFS is a normal Filesystem, and Ceph RBD are block devices)
 
Thanks.
Is is possible to add a Ceph RBD pool from the Proxmox web GUI?
If not, how can I configure that? (I am nw to Proxmox and Ceph configuration)

I have tried to follow the instructions: https://pve.proxmox.com/wiki/Storage:_RBD
Adding the following storage description to /etc/pve/storage.cfg:

rbd: ceph-rbd
content rootdir,images
krbd 1
monhost ......
pool ceph-rbd
username admin

It appears as an stoage now, but when I tried to restore a container I get this error:

TASK ERROR: unable to restore CT 137 - error with cfs lock 'storage-ceph-rbd': rbd error: rbd: listing images failed: (95) Operation not supported
 
Last edited:
Is is possible to add a Ceph RBD pool from the Proxmox web GUI?
Yes sure. If you did not created any Pool yet just select a Node and go to Ceph -> Pools, click the Create Button there. "Add as Storage" should be preselected, give it a name and you should be good for a basic setup.

If you already created a Ceph Pool and just want to add it as Ceph Storage go to Datacenter -> Storage, Click on "Add -> RBD" here the pools should be already listed if this is a PVE Ceph cluster (and not a external Ceph Cluster)
 
I created the RDB (PVE) using the web GUI and everything is working now. I removed the ceph-rdb storage that I created earlier.
It is a little confusing at the beginning, but thank to your help I was able to configure it.