Comment 2 for bug 1296485

Revision history for this message
Dave Cheney (dave-cheney) wrote : Re: [Bug 1296485] Re: manual provider fails to remove itself if bootstrapping fails

What about this sequence instead

$ [sudo] stop juju-db
$ [sudo] killall jujud
$ rm /etc/init/juju-* || true

On Mon, Mar 24, 2014 at 12:24 PM, Andrew Wilkins <
<email address hidden>> wrote:

> Yep, the manual provider expects there to be a machine agent to take
> care of the environment destruction. We should (a) permit pkill to fail
> with rc 1, and have fallback code like in the local provider to handle
> failed bootstrap.
>
> --
> You received this bug notification because you are subscribed to the bug
> report.
> https://bugs.launchpad.net/bugs/1296485
>
> Title:
> manual provider fails to remove itself if bootstrapping fails
>
> Status in juju-core:
> Triaged
>
> Bug description:
> The manual provider was unable to setup the machine correctly,
> something went wrong with mongodb so the jujud agent will eventually
> time out.
>
> The manual provider failed to remove /etc/init/juju-db.conf because it
> got confused by the return code from pkill. Pkill returned 1 because
> it couldn't find any matching processes to signal, because that
> process had failed to start.
>
> 2014-03-24 01:02:01 ERROR juju.environs.manual bootstrap.go:102
> bootstrapping failed, removing state file: rc: 1
> 2014-03-24 01:02:01 DEBUG juju.utils.ssh ssh.go:226 using OpenSSH ssh
> client
> 2014-03-24 01:02:01 DEBUG juju.utils.ssh ssh_openssh.go:147 running: ssh
> -o "StrictHostKeyChecking no" -o "PasswordAuthentication no" -i
> "/home/ubuntu/.juju/ssh/juju_id_rsa" "ubuntu@10.245.67.6" 'sudo pkill -6
> jujud'
> 2014-03-24 01:02:06 ERROR juju.cmd.juju common.go:19 Bootstrap failed,
> and the environment could not be destroyed: rc: 1
> 2014-03-24 01:02:06 ERROR juju.cmd supercommand.go:296 rc: 1
>
> To manage notifications about this bug go to:
> https://bugs.launchpad.net/juju-core/+bug/1296485/+subscriptions
>