container failed to start with lxc-clone-aufs=true in utopic. on the other hand without lxc-clone-aufs, a container will be created.
$ apt-cache policy juju-core
juju-core:
Installed: 1.20.6-0ubuntu1~14.10.1~juju1
Candidate: 1.20.6-0ubuntu1~14.10.1~juju1
Version table:
*** 1.20.6-0ubuntu1~14.10.1~juju1 0
500 http://ppa.launchpad.net/juju/stable/ubuntu/ utopic/main amd64 Packages
100 /var/lib/dpkg/status
How to reproduce:
1. add "lxc-clone-aufs: true" in ~/.juju/environments.yaml
2. juju switch local
3. juju bootstrap
4. juju deploy cs:trusty/ubuntu
2014-09-03 13:13:58 ERROR juju.container.lxc lxc.go:249 container failed to start: container failed to start
2014-09-03 13:13:58 ERROR juju.provisioner provisioner_task.go:418 cannot start instance for machine "1": container failed to start
Admittedly juju deploy fails in 1.20.6 if lxc-clone-auf is set to true. However it works in the latest development version.
BUT:
The latest development version fails to deploy if there is a leftover container that failed to start in the previous deploy (say using juju version 1.20.6). Because juju fails to destroy a container that failed to start.
FIX:
Use lxc-destroy to clean up the leftover containers.
Looking into fixing this issue in the code. A question that pops to mind is why are we reusing containers anyway.
Thank you for you patience..