Multiple package installs with subordinates?

Clint Byrum clint at ubuntu.com
Mon Dec 3 16:13:50 UTC 2012


Excerpts from Jorge O. Castro's message of 2012-12-03 06:21:53 -0800:
> Liam Young has a merge proposal for gunicorn this morning that checks
> for an apt lock before continuing :
> https://code.launchpad.net/~gnuoy/charms/precise/gunicorn/gunicorn-apt-lock-checking
> 
> And looking at it reminded me that we should start to discuss multiple
> installations on the same instance, possible at the same time.
> 
> There's a tool called aptdcon[1] which can do "aptdcon -i packagename"
> and will then hand off the install to aptdaemon, which is nice because
> if that takes a while and then a subordinate gets installed and also
> uses aptdcon it will just add the new packages to it's installation
> queue and continue.
> 

The trouble with atpdaemon and aptdcon is that they are not installed
by default. So you can still conflict installing aptdaemon.

Perhaps the right thing to do is go down the path that I had suggested
with charmhelper2 which is to have a declarative file listing packages
desired, and then we can solve the problem by iterating on a single tool
rather than all charms.

A super lightweight solution is to wrap apt-get and dpkg to use flock
when called from within charms:

flock /var/lib/juju/serialize.hooks apt-get install foo

Would totally work.

> But before we do things like recommend aptdcon and/or go through all
> the charms fixing them up I'd like to get consensus on how to solve
> this problem. Also I've heard people talking about using things like
> LXC so that the subordinate and "master" never need to clash, but I
> don't know if that's a planned feature for subordinates or what.

The whole point of subordinates is that they are *not* separated from
the primary charm by containers.



More information about the Juju mailing list