cloud init script should have better preference for IP addresses for agent binaries

Bug #1654943 reported by John A Meinel
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Canonical Juju
Expired
Medium
Unassigned
2.1
Fix Released
High
Andrew Wilkins

Bug Description

Currently if the Controller has many IP addresses, we configure the cloud init script to download the agent binaries from the controller via all known addresses. This "works" but it can take a long time for 'curl' to timeout trying to download the tools from addresses that it doesn't have a route to.

However, Juju should be able to infer if there is a server IP address that is more likely to work for this instance than all the other addresses. (If the machine/container is in a space, try to use the Controller address in that space, else fall back to one that is known-to-be-routable to that space.)

Eventually we need the routing information to give the best results, but if we just start with "in same space" we're likely to get some quick wins.

Revision history for this message
John A Meinel (jameinel) wrote :

One 'quick fix' is to pass '--connect-timeout X' to specify a number of seconds that curl should wait to connect to download agent binaries. Certainly if we are connecting to the controller in the same network, we would expect it to be quite fast. We may not want to set it for the initial tool download from streams.canonical.com but we should be able to set something much lower than the default (which I think is ~2minutes) for connecting to the controller machine.

Revision history for this message
Andrew Wilkins (axwalk) wrote :

I've made the --connect-timeout change to fix lp:1622531. Will leave this one open for the complete fix, i.e. using knowledge of spaces.

Revision history for this message
Anastasia (anastasia-macmood) wrote :

Andrew, John

Thank you for a quick solution for 2.1 \o/

For posterity, as per bug referred to in comment # 2, this solution is provided in https://github.com/juju/juju/pull/6980.

Based on that, I'll mark this as Fix Committed in 2.1.0 but will leave it open in 2.2 to allow for complete fix.

Changed in juju:
milestone: none → 2.2.0
Curtis Hovey (sinzui)
Changed in juju:
milestone: 2.2-beta1 → 2.2-beta2
Curtis Hovey (sinzui)
Changed in juju:
milestone: 2.2-beta2 → 2.2-beta3
Changed in juju:
milestone: 2.2-beta3 → 2.2-beta4
Changed in juju:
milestone: 2.2-beta4 → 2.2-rc1
Tim Penhey (thumper)
Changed in juju:
importance: High → Medium
milestone: 2.2-rc1 → none
Revision history for this message
Canonical Juju QA Bot (juju-qa-bot) wrote :

This bug has not been updated in 5 years, so we're marking it Expired. If you believe this is incorrect, please update the status.

Changed in juju:
status: Triaged → Expired
tags: added: expirebugs-bot
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.