On Mon, Jun 07, 2021 at 01:09:48PM +0200, Johannes Kastl wrote:
> Hi all,
> sorry if this is an old hat, but everything that I found on this does
> not work...
> - proxmox host
> - lxc 4.0.6
> - unprivileged container
> - I need the null and zero special devices inside a container
> I have an older setup where the container was running privileged, and
> I could just use the lxc.cgroup.devices.allow settings.
> Apparently this does not work with unprivileged containers.
> I thought bind-mounting should do the trick, but it fails:
> lxc.mount.entry = /dev/null var/lib/named/dev/null none bind 0 0
When you don't put a leading '/' in the mount target, you're
asking for the path to be relative to the mounted container rootfs.
So you probably wanted
lxc.mount.entry = /dev/null dev/null none bind 0 0
> lxc.mount.entry = /dev/zero var/lib/named/dev/zero none bind 0
> This is the output:
> # pct start 102
> __safe_mount_beneath_at: 1106 Function not implemented - Failed to
> open 51(dev)
> mount_entry: 1953 No such file or directory - Failed to mount
> "/dev/null" on
> lxc_setup: 3353 Failed to setup mount entries
> do_start: 1218 Failed to setup container "102"
> __sync_wait: 36 An error occurred in another process (expected
> sequence number 5)
> __lxc_start: 1999 Failed to spawn container "102"
> startup for container '102' failed
> Not sure if this is proxmox specific, or if I am missing something here?
> Any help is highly appreciated, even if it is just pointing out my
> mistakes... :-)
> Kind Regards,
> You received this message because you are subscribed to the Google Groups "lxc-users" group.
> To unsubscribe from this group and stop receiving emails from it, send an email to lxc-users+...@lists.linuxcontainers.org
> To view this discussion on the web visit https://groups.google.com/a/lists.linuxcontainers.org/d/msgid/lxc-users/37fe9dda-d059-378d-b092-8e543f136a21%40ojkastl.de
pub RSA 4096/AF399D68 2017-02-28 Johannes Kastl <ma...@ojkastl.de
> sub RSA 4096/1AA68976 2017-02-28
> sub RSA 4096/F1ED4237 2017-02-28