Azure data source assumes use of dhclient
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
cloud-init |
Expired
|
Medium
|
Unassigned |
Bug Description
The Azure data source assumes that all Linux distros use dhclient. Location of a lease file is hard coded to
"""
LEASE_FILE = '/var/lib/
"""
and if the file is not found the data source reports errors:
"""
Failed to read /var/lib/
"""
Further, during the cloud-init local stage cloud-init establishes a temporary dhclient connect but the lease file is written to a temporray location such as:
"""
/var/tmp/
"""
The Azure data source should check if the network is up rather than depending on specific markers in the file system left by specific implementations for dhcp connections. The kernel sysfs provides more reliable methods to detect network connection precense.
Changed in cloud-init: | |
status: | New → Triaged |
importance: | Undecided → Medium |
Tracked in Github Issues as https:/ /github. com/canonical/ cloud-init/ issues/ 3891