[PVE-User] pve-user Digest, Vol 91, Issue 22

hackru hackru at gmail.com
Wed Oct 14 19:01:55 CEST 2015


Thanks for pointing out! It really works when manually adding to container config, but not automatically.

How should i do this on creation of CT?
i tried with(storage is created before creating container)
pvesh create /nodes/$(hostname)/lxc -vmid $id  \
    -hostname $hostname \
    -memory $mem \
    -swap $swap \
    -storage rbd -ostemplate local:vztmpl/$template \
    -mp0 volume=rbd:vm-$id-disk-2,mp=/mnt/ \
    -onboot yes

and without volume=, no success? is it implemented?

> On 14 Oct 2015, at 13:00, pve-user-request at pve.proxmox.com wrote:
> 
> yes, you can do quite a lot with container mountpoints
> you have two alternatives
> 
> mp0: local:102/vm-102-disk-3.raw,mp=/mnt/,size=1G
> mp1: /dev/dm-3,mp=/mnt1/,size=1G
> 
> 
> mp0 will mount here a disk image to /mnt
> mp1 will mount the block device /dev/dm-3 to /mnt1 inside the container
> 
> I advise you to use the first type of mountpoints, as it allows you to
> get all the boni of the pve storage backends (ex: direct resizing via
> pct resize, storage independance so you can put the image on a a NFS
> server)
> 
> The second type of mountpoints would be mostly interesting, if you want
> for instance to pass a plugged in USB device from the host to the guest.
> 
> Emmanuel




More information about the pve-user mailing list