[libvirt] [PATCH] vz: set mount point for container image-based disks

Daniel P. Berrange berrange at redhat.com
Mon Sep 21 08:44:18 UTC 2015

On Sun, Sep 20, 2015 at 10:17:51PM +0300, Maxim Nestratov wrote:
> From: Maxim Nestratov <mnestratov at virtuozzo.com>
> In order to support not only root disks with type=file for containers,
> we need to specify mount points for them.
> For instance, if a secondary disk is added by the following record in
> xml:
>     <disk type='file' device='disk'>
>       <driver type='ploop' cache='writeback'/>
>       <source file='/vz/some_path_to_image_dir'/>
>       <target bus='sata' dev='sdb'/>
>     </disk>
> we are going to add it to container mounted to '/mnt/sdb' path.

That's not what the <disk> element is for.  <disk> is about exposing
block device nodes to the container. It shouldn't try todo anything
with this device nodes. They might be used as raw data storage by
an application, so we can't assume they should be mounted.

If you want to mount things then you should be using <filesystem>

|: http://berrange.com      -o-    http://www.flickr.com/photos/dberrange/ :|
|: http://libvirt.org              -o-             http://virt-manager.org :|
|: http://autobuild.org       -o-         http://search.cpan.org/~danberr/ :|
|: http://entangle-photo.org       -o-       http://live.gnome.org/gtk-vnc :|

More information about the libvir-list mailing list