The Azure DS is removing /var/lib/waagent/SharedConfig.xml on first boot, causing walinuxagent to fail.
Apr 14 11:46:24 ubuntu [CLOUDINIT] util.py[DEBUG]: Attempting to remove /var/lib/waagent/SharedConfig.xml
Apr 14 11:46:24 ubuntu [CLOUDINIT] DataSourceAzure.py[INFO]: removed stale file(s) in '/var/lib/waagent': ['/var/lib/waagent/SharedConfig.xml']
Apr 14 11:46:24 ubuntu [CLOUDINIT] util.py[DEBUG]: Writing to /var/lib/waagent/ovf-env.xml - wb: [384] 1632 bytes
Apr 14 11:46:24 ubuntu [CLOUDINIT] util.py[DEBUG]: Running command hostname with allowed return codes [0] (shell=False, capture=True)
Apr 14 11:46:24 ubuntu [CLOUDINIT] util.py[DEBUG]: Running command ['hostname', 'daily-vivid-0414-1ce494fec4'] with allowed return codes [0] (shell=False, capture=True)
Apr 14 11:46:24 ubuntu [CLOUDINIT] DataSourceAzure.py[DEBUG]: pubhname: publishing hostname [phostname=ubuntu hostname=daily-vivid-0414-1ce494fec4 policy=True interface=eth0]
Apr 14 11:46:24 ubuntu [CLOUDINIT] util.py[DEBUG]: Reading from /proc/uptime (quiet=False)
Apr 14 11:46:24 ubuntu [CLOUDINIT] util.py[DEBUG]: Read 11 bytes from /proc/uptime
Apr 14 11:46:24 ubuntu [CLOUDINIT] util.py[DEBUG]: Running command ['sh', '-xc', 'i=$interface; x=0; ifdown $i || x=$?; ifup $i || x=$?; exit $x'] with allowed return codes [0] (shell=False, capture=False)
Apr 14 11:46:26 ubuntu [CLOUDINIT] util.py[DEBUG]: Reading from /proc/uptime (quiet=False)
Apr 14 11:46:26 ubuntu [CLOUDINIT] util.py[DEBUG]: Read 11 bytes from /proc/uptime
Apr 14 11:46:26 ubuntu [CLOUDINIT] util.py[DEBUG]: publishing hostname took 2.119 seconds (2.12)
Apr 14 11:46:26 ubuntu [CLOUDINIT] DataSourceAzure.py[DEBUG]: invoking agent: ['service', 'walinuxagent', 'start']
Apr 14 11:46:26 ubuntu [CLOUDINIT] util.py[DEBUG]: Running command ['service', 'walinuxagent', 'start'] with allowed return codes [0] (shell=False, capture=True)
Apr 14 11:47:27 ubuntu [CLOUDINIT] util.py[DEBUG]: waiting for files took 60.959 seconds
Apr 14 11:47:27 ubuntu [CLOUDINIT] DataSourceAzure.py[WARNING]: Did not find files, but going on: {'/var/lib/waagent/SharedConfig.xml'}
Apr 14 11:47:27 ubuntu [CLOUDINIT] DataSourceAzure.py[WARNING]: SharedConfig.xml missing, using static instance-id
so, to give an idea on what happens here.
cloud-init boots, finds its on azure, and then runs:
service walinuxagent start
it expects that that will produce some files in some amount of time (60 seconds).
if it does not find those, it complains and goes on.
/var/log/ waagent. log has similar messages about missing sharedconfig.xml
2015/04/14 16:13:44 Finished processing ExtensionsConfi g.xml waagent" , line 4600, in AddSystemInfo minidom. parse(" /var/lib/ waagent/ SharedConfig. xml").childNode s[0] python2. 7/xml/dom/ minidom. py", line 1918, in parse parse(file) python2. 7/xml/dom/ expatbuilder. py", line 922, in parse waagent/ SharedConfig. xml'
2015/04/14 16:13:44 ERROR:Traceback (most recent call last):
2015/04/14 16:13:44 ERROR: File "/usr/sbin/
2015/04/14 16:13:44 ERROR: sharedConfig = xml.dom.
2015/04/14 16:13:44 ERROR: File "/usr/lib/
2015/04/14 16:13:44 ERROR: return expatbuilder.
2015/04/14 16:13:44 ERROR: File "/usr/lib/
2015/04/14 16:13:44 ERROR: fp = open(file, 'rb')
2015/04/14 16:13:44 ERROR:IOError: [Errno 2] No such file or directory: '/var/lib/
2015/04/14 16:13:44 ERROR: