Juju bootstrap localhost hangs

I’m trying juju for the first time. I have used LXD before.

juju bootstrap localhost --debug hangs after displaying:

10:49:38 INFO cmd bootstrap.go:481 Running machine configuration script…

I can ssh to LXD container as user ubuntu, but this message is displayed:

Failed to connect to . Check your Internet connection or proxy settings

I can’t curl to that url, but I can ping it

I can curl archive.ubuntu.com/ubuntu

ubuntu@juju-4fceea-0:~$ sudo tail -f /var/log/cloud-init-output.log
show failures trying to get to archive.ubuntu.com/ubuntu

ubuntu@juju-4fceea-0:~$ cat /etc/os-release
VERSION=“20.04.2 LTS (Focal Fossa)”

From my desktop

Karl@Nordström ~:$ cat /etc/lsb-release

Karl@Nordström ~:$ lxd --version

Karl@Nordström ~:$ juju --version

Does anyone have a suggestion on how to get this fixed?

When juju brings up a new machine/container, it will refresh the apt packages on that machine as part of the “machine configuration” script. And it seems that is failing as you mention.

Are you able to lxc launch a LXD container manually and reach the archive? Is your host machine behind a proxy of some sort? You may need to configure juju to use a proxy to reach the archives.

I had two bridges: lxdbr0 and lxdbr1 defined. I found this out by including the --show-log on the the bootstrap command.

juju bootstrap localhost --debug --show-log

I deleted lxdbr1 and the bootstrap worked

1 Like

Great, glad you got it working :slight_smile:

1 Like