[lxc-devel] [PATCH] have systemd service call lxc-autostart via script

Stéphane Graber stgraber at ubuntu.com
Thu May 1 21:59:58 UTC 2014


On Thu, May 01, 2014 at 09:57:04PM +0000, Serge Hallyn wrote:
> Quoting Stéphane Graber (stgraber at ubuntu.com):
> > On Thu, May 01, 2014 at 05:14:12PM -0400, Michael H. Warfield wrote:
> > > Related to this...  Dwight and I have been bouncing a couple of things
> > > back and forth and I noticed that lxc-autostart is being called from the
> > > sysvinit scripts without the -a parameter.  That means that any
> > > container in a non-null group will not be autostart on boot.  I feel
> > > that's the wrong behavior.  If autoboot = 1 then it should be autobooted
> > > on boot.  What you do after boot is up to you but I would expect it to
> > > be "autoboot = 1" => "autobooted on bootup", not "autoboot = 1" =>
> > > "autobooted on bootup if it's not in a group".
> > 
> > I can see why you'd auto-start both the null group and say a "boot"
> > group, but I don't think we should auto-start them all.
> > 
> > A reason is that I use those groups as a way to easily start a group of
> > interdependent containers, when I need those, I do "lxc-autostart -g
> > blah" and all containers that have lxc.group = blah and lxc.start.auto =
> > 1 will start properly sorted, with the right delays, ...). I however
> > don't necessarily want those to start at boot.
> 
> And...  do you have containers in lxc.cgroup = blah which you do not
> want to have started when you do lxc-autostart -g blah?

At the moment, no because no tool except lxc-autostart currently read
lxc.group, however the fact we put this as lxc.group instead of
lxc.start.group in the original spec suggests that we wanted to
eventually use that for group operations outside of the autostart case.

-- 
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-devel/attachments/20140501/72ccb475/attachment.sig>


More information about the lxc-devel mailing list