[SOLVED] Enable KRBD on non-KRBD Ceph Pool

wahmed

Famous Member
Oct 28, 2012
1,095
39
113
Calgary, Canada
www.symmcom.com
I do not have a test Ceph cluster to test this with, so wondering if anybody got some info.

I have always used 2 ceph pools for KVM and LXC disk images. On LXC Ceph pool I had KRBD enabled while the pool for KVM disk images had KRBD disabled.

My question is, can I enable KRBD on the non-KRDB pool which has live VM disk images and move LXC disk images onto it or will enabling KRBD on it will mess up data?

Basically trying to eliminate unnecessary Ceph pools to reduce the number of PGs. How are you Ceph users using pools?
 
I would like to hear what others have to say about it too. Someone mentioned there was pros and cons for having KRBD enabled or not enabled.
 
I do not have a test Ceph cluster to test this with, so wondering if anybody got some info.

I have always used 2 ceph pools for KVM and LXC disk images. On LXC Ceph pool I had KRBD enabled while the pool for KVM disk images had KRBD disabled.

My question is, can I enable KRBD on the non-KRDB pool which has live VM disk images and move LXC disk images onto it or will enabling KRBD on it will mess up data?

Basically trying to eliminate unnecessary Ceph pools to reduce the number of PGs. How are you Ceph users using pools?

You can add a second storage pool using the same ceph pool, one with krbd and one without, and no, it doesnt mess up any data :) This is also the default behavior when you use the proxmox gui to create a ceph pool.
 
I think my initial post was not clear enough. I am already using 2 pools, one for KVM disk images with KRBD disabled, and the other for LXC containers with KRBD enabled.
My question was if I can enable KRBD for the non KRBD pool and start storing LXC containers along with KVM disk images on the same Ceph pool. The non-KRBD pool right now holds a lot of KVM disk images. So was wondering enabling KRBD option on to the non-KRBD pool does anything to the disk images it currently holds.
 
My question was if I can enable KRBD for the non KRBD pool and start storing LXC containers along with KVM disk images on the same Ceph pool.
Yes. krbd doesnt have anything to do with CEPH, it has to do with how you are mounting the devices on your host. As long as you create a second PROXMOX storage pool, you can attach the same CEPH pool.

eg: rbd_ct and rbd_vm actually point to the same ceph pool:

upload_2019-3-15_11-21-59.png

upload_2019-3-15_11-23-8.png
upload_2019-3-15_11-23-44.png

If you check on your ceph pool, rbd ls will show you both your containers and your vm disks as they all coexist :)
 
I want to throw in, that with the latest PVE version for containers the KRBD option doesn't need to be set anymore. As a container needs to use KRBD anyway to get a mapped device.
 

About

The Proxmox community has been around for many years and offers help and support for Proxmox VE, Proxmox Backup Server, and Proxmox Mail Gateway.
We think our community is one of the best thanks to people like you!

Get your subscription!

The Proxmox team works very hard to make sure you are running the best software and getting stable updates and security enhancements, as well as quick enterprise support. Tens of thousands of happy customers have a Proxmox subscription. Get yours easily in our online shop.

Buy now!