← Back to team overview

openstack team mailing list archive

Re: Libvirt LXC with volume-attach broken ?

 

Quoting Daniel P. Berrange (berrange@xxxxxxxxxx):
> On Thu, Jul 05, 2012 at 03:00:26PM +0100, Daniel P. Berrange wrote:
> > Now, when using 'nova volume-attach':
> > 
> >   # nova volume-attach 05eb16df-03b8-451b-85c1-b838a8757736 a5ad1d37-aed0-4bf6-8c6e-c28543cd38ac /dev/sdf
> > 
> > nova will import an iSCSI LUN from the nova volume service, on the compute
> > node. The kernel will assign it the next free SCSI drive letter, in my
> > case '/dev/sdc'.
> > 
> > The libvirt nova driver will then do a mknod, using the volume name
> > passed to 'nova volume-attach'.
> > eg it will do
> > 
> >   mknod  /var/lib/nova/instances/instance-0000000e/rootfs/dev/sdf
> 
> Opps, I'm slightly wrong here. What it actually does is
> 
>   mount --bind /dev/sdc /var/lib/nova/instances/instance-0000000e/rootfs/dev/sdf
> 
> so you get a 'sdf' device, but with the major/minor number of the 'sdc'
> device. I can't say I particularly like this approach. Ultimately I
> think we need the kernel support to make this work correctly. In any

Yes, that's what the 'devices namespace' is meant to address.  I'm hoping
we can some serious design discussion on that in the next few months.

-serge


Follow ups

References