[SOLVED] LXC move disk to another container at Ceph

CvH

Well-Known Member
Oct 16, 2020
31
4
48
Germany
Hello,

I have a LXC container that includes several disks (mount points) from different ceph pools.
Now we want to move a disk to another LXC container (disk includes just files from a smb share).
So basically LXC (100) vm-100-disk-3 -> LXC (200) vm-200-disk-3.

Backup Restore is not really a option (size/timewise).

I could edit the /etc/pve/lxc/100.conf and remove the disk.
Additionally add it at 200.conf mp3: pool_hdd:vm-100-disk-3,mp=/somewhere,size=20T.
Adding a different ID-Disk to a LXC sounds rather wrong to me and it might create problems at the future.

Is there a handy way in doing it ? Search didn't find anything reasonable, or I looked for the wrong terms :)
 
Adding a different ID-Disk to a LXC sounds rather wrong to me and it might create problems at the future.
Yup, it will create problems. Best also rename the image to match the VMID as well.
 
tx for pointer

just for the record, that worked for me
rbd -p my_pool_name mv vm-100-disk-3 vm-200-disk-3
 
  • Like
Reactions: Alwin