landscape-client init script does not wait for the network to be available before checking for EC2 user data
Bug #383336 reported by
Christopher Armstrong
This bug affects 1 person
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
Landscape Client |
Fix Released
|
Critical
|
Christopher Armstrong |
Bug Description
When we started supporting the automatic configuration of cloud-based landscape clients in the init script, we added a hard dependency on the existence of networking support. The init script now downloads user data from the EC2 metadata server, but there are two problems: first, its startup priority is lower than that of "networking" (so I really don't know how it ever works now, but it does), and second, the init script itself does not wait for the interface to come up, which is necessary even if it has a higher priority than the networking startup script, because the networking startup script does not guarantee a working network interface by the time it completes (apparently).
tags: | added: review |
Changed in landscape-client: | |
assignee: | nobody → Christopher Armstrong (radix) |
status: | New → In Progress |
tags: | removed: review |
Changed in landscape-client: | |
status: | In Progress → Fix Committed |
tags: | added: needs-testing |
Changed in landscape-client: | |
status: | Fix Committed → Fix Released |
To post a comment you must log in.
By the way, this is similar to bug #308530 in ubuntu-on-ec2, which they're fixing by putting the following snippet into their startup scripts (or at least, this is the currently-proposed solution):
+def checkServer(): (address, port))
+ for x in range(30*60):
+ s = socket.socket()
+ try:
+ address = '169.254.169.254'
+ port = 80
+ s.connect(
+ s.close()
+ return
+ except socket.error, e:
+ time.sleep(1)
+
+checkServer()