On Mon, Apr 4, 2016 at 10:02 AM, Paul Schroeder <paul.schroe...@nimbix.net>
wrote:

>
>
> On Fri, Apr 1, 2016 at 8:21 PM, Joe Zeff <j...@zeff.us> wrote:
>
>> On 04/01/2016 08:05 AM, Paul Schroeder wrote:
>>
>>> I tried both.  Neither solution seemed to keep the mount from happening.
>>>
>>
>> Have you considered using umount to remove the unwanted mount in
>> /etc/rc.d/rc.local?  It's not exactly elegant, but it should do the trick.
>>
>> Yea.  That won't really work:
>
> # umount /dev
> umount: /dev: target is busy.
>         (In some cases useful info about processes that use
>          the device is found by lsof(8) or fuser(1))
>
>
>
It would appear that the LXC config option for the container,
lxc.automount, determines whether or not LXC decides to mount devtmpfs on
/dev.  When lxc.automount = 1, it is obviously on and always does this.
After digging through the LXC code, if the option is not specified, LXC
autodetects whether or not systemd is used inside the container.  If it is
detected, LXC automatically turns automount on.  (I wish this had been
documented somewhere.)  So to stop LXC from mounting /dev, one has to
explicitly set lxc.automount = 0..

However, this causes problems inside the container, causing it to freeze on
boot.  It would appear that systemd within my CentOS container is still
trying to mount /dev when it can't.  I believe that I have all of the udev
services masked properly, so this must be coming from somewhere else within
systemd.  Any further ideas out there?

$ sudo lxc-start -n c7
Failed to mount devtmpfs at /dev: Permission denied
Failed to mount cgroup at /sys/fs/cgroup/systemd: Permission denied
[!!!!!!] Failed to mount API filesystems, freezing.

Thanks!  Paul...
--
users mailing list
users@lists.fedoraproject.org
To unsubscribe or change subscription options:
http://lists.fedoraproject.org/admin/lists/users@lists.fedoraproject.org
Fedora Code of Conduct: http://fedoraproject.org/code-of-conduct
Guidelines: http://fedoraproject.org/wiki/Mailing_list_guidelines
Have a question? Ask away: http://ask.fedoraproject.org

Reply via email to