5

How can I fix this case, my condition :

  1. MAAS Server on VM
  2. Juju in Main server
  3. All ubuntu 14.04

Here is the error

curl(6) "could not resolve host: streams.canonical.com"

Setting up libboost-program-options1.54.0:amd64 (1.54.0-4ubuntu3) ...
Setting up libboost-thread1.54.0:amd64 (1.54.0-4ubuntu3) ...
Setting up libpcrecpp0:amd64 (1:8.31-2ubuntu2) ...
Setting up libunwind8 (1.1-2.2ubuntu3) ...
Setting up libtcmalloc-minimal4 (2.1-2ubuntu1) ...
Setting up libgoogle-perftools4 (2.1-2ubuntu1) ...
Setting up libsnappy1 (1.1.0-1ubuntu1) ...
Setting up juju-mongodb (2.4.9-0ubuntu3) ...
Processing triggers for libc-bin (2.19-0ubuntu6) ...
curl: (6) Could not resolve host: streams.canonical.com tools from https://streams.canonical.com/juju/tools/releases/juju-1.18.3-trusty-amd64.tgz downloaded: HTTP 000; time 9.523s; size 0 bytes; speed 0.000 bytes/s ERROR bootstrap failed: rc: 1 Stopping instance...
Bootstrap failed, destroying environment ERROR rc: 1

I added all dns server ip in /etc/network/interface as dns-nameservers 192.?.?? 10.0.??

and the error changed to

Processing triggers for libc-bin (2.19-0ubuntu6) ... curl: (7) Failed to connect to streams.canonical.com port 443: Connection refused

I can Ping the streams.canonical.com , I think there is some thing wrong with SSL certification! Do I have to set some thing about SSL Certification on my JUJU or MAAS Server?!

I tried to juju boot strap from VM machine as Juju server I got this:

ERROR bootstrap failed: cannot upload bootstrap tools: Juju cannot bootstrap because no tools are available for your environment. You may want to use the 'tools-metadata-url' configuration setting to specify the tools location.

I tried to juju boot strap from VM machine as Juju server I got this:

ERROR bootstrap failed: cannot upload bootstrap tools: Juju cannot bootstrap because no tools are available for your environment. You may want to use the 'tools-metadata-url' configuration setting to specify the tools location.

7
  • check your internet connection May 13, 2014 at 23:00
  • I connected to the internet, everything is ok! and actually it get a lot of tools before that like:
    – Rastin
    May 14, 2014 at 19:37
  • Get:10 archive.ubuntu.com//ubuntu trusty/universe juju-mongodb amd64 2.4.9-0ubuntu3 [6,936 kB] Fetched 7,483 kB in 26s (278 kB/s) Selecting previously unselected package libboost-....Setting up juju-mongodb (2.4.9-0ubuntu3) ... Processing triggers for libc-bin (2.19-0ubuntu6) ... curl: (6) Could not resolve host: streams.canonical.com tools from streams.canonical.com/juju/tools/releases/… downloaded: HTTP 000; time 9.523s; size 0 bytes; speed 0.000 bytes/s ERROR bootstrap failed: rc: 1
    – Rastin
    May 14, 2014 at 19:46
  • Question: Is there any option to download juju-1.18.3-trusty-amd64.tgz and set some where the path to get this file instead of downloading in middle of bootstrap?
    – Rastin
    May 14, 2014 at 22:22
  • Yes, there is - see juju help sync-tools. You can generate local metadata and use it when bootstrapping (it's intended to be used inside private clouds or special scenarios like yours).
    – dimitern
    May 20, 2014 at 14:37

3 Answers 3

1

SSL certificate errors wouldn't lead to Connection Refused; that is a very specific error message that means that a TCP connection was denied, either because the other endpoint doesn't have a listening socket open on that port or because it has been administratively denied by a firewall (one set to REJECT packets rather than DROP packets).

Check the firewalls on all kernels involved -- VM guests, VM host, routers between you and the Internet, etc.

When these error messages get very confusing, it could be because processes have been told to use a proxy and none is available, or the proxy is experiencing trouble, or is misconfigured.

Note that APT can use proxies configured via the Acquire::http::Proxy configuration item in /etc/apt/apt.conf or /etc/apt/apt.conf.d/*. (And it might not be this exact string; best to search for Proxy.) Most everything else will use the http_proxy environment variable.

I hope this helps.

8
  • Thnaks, I have already set the http,https and ftp proxy in /etc/apt/apt.conf in both server ( VM MAAS Server and my JUJU server), what i must do with the /etc/apt/apt.conf.d/?
    – Rastin
    May 16, 2014 at 0:24
  • /etc/apt/apt.conf.d/ is just a convenient place to store configuration snippets; you could either store your changes in your own file in this directory or continue to modify /etc/apt/apt.conf directly. Use whichever seems easiest to you.
    – sarnold
    May 16, 2014 at 21:49
  • As I mentioned I have my proxy set in /etc/apt/apt.conf but the problem is still same!
    – Rastin
    May 19, 2014 at 19:19
  • I tried this : openssl s_client -connect streams.canonical.com:443 -showcerts connect: Connection refused connect:errno=111
    – Rastin
    May 19, 2014 at 23:33
  • Juju natively supports proxy settings specified as environment variables "http_proxy", "https_proxy", "ftp_proxy" or "no_proxy" (and their uppercase equivalents). You can also specify these in your environments.yaml. They will take effect if set before bootstrapping.
    – dimitern
    May 20, 2014 at 14:45
0

I passed those errors:
1) Using ssh session and setting localhost:8080/MAAS as mass address , so juju sync-tools successfully done
2) using ip:80/MAAS address it bypassed the bad gateway and connection refused but i got another error:

ERROR juju.cmd supercommand.go:305 gomaasapi: got error back from server: 401 OK (Expired timestamp: given 1400739722 and now 1400764922 has a greater difference than threshold 300)
3) where is this time out defined ?

2
  • The timeout is coming from MAAS - check out maas.ubuntu.com/docs/… to see if syncing the clocks on the client and server might help.
    – dimitern
    May 22, 2014 at 7:15
  • It would be best to ask your new question as a new question, thanks.
    – sarnold
    May 22, 2014 at 18:44
0

I Fixed the last problem:

Problem ERROR juju.cmd supercommand.go:305 gomaasapi: got error back from server: 401 OK (Expired timestamp: given 1400739722 and now 1400764922 has a greater difference than threshold 300) where does this time out defined ?

I did not find why juju command using UTC!but i set MAAS server and Juju Server to UTC with this command:

sudo dpkg-reconfigure tzdata and finally i successfully boot strapped the juju!

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .