[lxc-users] Block devices not permitted on file system

Serge Hallyn serge.hallyn at ubuntu.com
Sun Feb 1 07:38:57 UTC 2015


Quoting Christian Brauner (subroutinecall at gmail.com):
> Hello,
> 
> booting unprivileged ubuntu trusty and vivid container I get the
> following messaged when shutting them down:
> 
>     umount: /dev/zero: block devices are not permitted on filesystem

Apparently this is an error emitted by umount.c in util-linux when it
gets a -EACCES.  My guess is that your underlying fs has real blockdevs,
and the fs is MS_NODEV, and umount is somehow finding that unmounting
the file mounted over those files would violate MS_NODEV.  I say somehow
bc I don't see the code doing that check.

Though it's also possible that umount is misdiagnosing the EACCES.
Just to be sure, you could try booting the container without apparmor:

lxc.aa_profile = unconfined

and see if that still does it.


>     umount: /dev/urandom: block devices are not permitted on filesystem
>     umount: /dev/tty: block devices are not permitted on filesystem
>     umount: /dev/random: block devices are not permitted on filesystem
>     umount: /dev/null: block devices are not permitted on filesystem
>     umount: /dev/full: block devices are not permitted on filesystem
>     umount: /dev/console: block devices are not permitted on filesystem
> 
> that goes for basically all device bind-mounts:
> 
>     umount: /dev/fb0: block devices are not permitted on filesystem
>     umount: /dev/video0: block devices are not permitted on filesystem
>     umount: /dev/dri: block devices are not permitted on filesystem
>     umount: /dev/snd: block devices are not permitted on filesystem
>     umount: /dev/zero: block devices are not permitted on filesystem
>     umount: /dev/urandom: block devices are not permitted on filesystem
>     umount: /dev/tty: block devices are not permitted on filesystem
>     umount: /dev/random: block devices are not permitted on filesystem
>     umount: /dev/null: block devices are not permitted on filesystem
>     umount: /dev/full: block devices are not permitted on filesystem
>     umount: /dev/console: block devices are not permitted on filesystem
> 
> Can someone explain this?
> 
> Best,
> Christian
> _______________________________________________
> lxc-users mailing list
> lxc-users at lists.linuxcontainers.org
> http://lists.linuxcontainers.org/listinfo/lxc-users


More information about the lxc-users mailing list