[lxc-users] fstab vs lxc.mount.entry
Stéphane Graber
stgraber at ubuntu.com
Sat Dec 20 20:10:01 UTC 2014
On Sat, Dec 20, 2014 at 09:00:50PM +0100, BB wrote:
> Hi,
>
> is there any significant difference between the configuration of mounts in
> the container's fstab file versus lxc.mount.entry entries in the
> container's config file?
> I am currently using only the former method.
>
> Best regards,
>
> BB
So there are at least three ways you can handle mounts in a container:
1) Use lxc.mount.entry in the container's config
2) Use lxc.mount pointing to a file on the host
3) Use /etc/fstab inside the container's rootfs
1) and 2) are essentially identical as any entry in the fstab-like file
pointed to by lxc.mount is parsed using the same parse as
lxc.mount.entry.
3) Is different in that it's the parser in the rootfs which will process
this and do any required mounts. In this case, your mounts may be
rejected due to apparmor, selinux, seccomp or user namespaces
restrictions and also will not allow you to bind-mount resources from
the host.
--
Stéphane Graber
Ubuntu developer
http://www.ubuntu.com
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 819 bytes
Desc: Digital signature
URL: <http://lists.linuxcontainers.org/pipermail/lxc-users/attachments/20141220/1db8f5d8/attachment.sig>
More information about the lxc-users
mailing list