[lxc-devel] call to setup_dev_symlinks with lxc.autodev

Dwight Engen dwight.engen at oracle.com
Mon Apr 21 14:57:01 UTC 2014


On Thu, 17 Apr 2014 10:23:00 -0500
Serge Hallyn <serge.hallyn at ubuntu.com> wrote:

> Quoting William Dauchy (wdauchy at gmail.com):
> > On Thu, Apr 17, 2014 at 5:07 PM, Michael H. Warfield
> > <mhw at wittsend.com> wrote:
> > > Ok...  Now I see what you're doing.  Thank you.
> > >
> > > When your initial scripts create the system disk image and
> > > populate the /dev directory, why are they not creating those
> > > symlinks.  They are required per the kernel's
> > > Documentation/devices.txt doc.  They're listed in the
> > > "Compulsory" section meaning your custom image is not in
> > > compliance with the Linux kernel documentation (i.e. broken).
> > 
> > hm. I said in a previous post they are already created.
> > the symlink function is just not returning EEXIST unless I'm listing
> > the directory.
> 
> That's the intriguing part :)

Sorry I'm late to the party, was out last week. FWIW I agree with Mike
that its not really related to autodev, so using that option doesn't make
sense.

We could allow the container to start if the symlinks can't be created
(just return 0 instead of -1), or check for both EROFS and EEXIST
(if indeed EROFS is what is being returned in this case). This would
revert us to our old behavior since we didn't used to insist the
symlinks were there. It seems a little dangerous however, since as Mike
pointed out Harald's case was a pretty simple shell redirection. I'm
not sure what else might rely on them.

Better would be figuring out why we don't see EEXIST until an ls is
done, which seems quite strange.

> So what does /dev look like on the physical media?
> _______________________________________________
> lxc-devel mailing list
> lxc-devel at lists.linuxcontainers.org
> http://lists.linuxcontainers.org/listinfo/lxc-devel



More information about the lxc-devel mailing list