Hi,
I have been trying to bootstrap a focal juju controller to deploy CDK and I am facing the same issue as mentioned in the post:
I realized that the bootstrap fails because commissioning a focal VM itself fails.
I am using the following versions of juju and maas:
$ juju version
2.9.14-ubuntu-amd64
$ sudo snap list
Name Version Rev Tracking Publisher Notes
<snipped>
maas 2.9.2-9165-g.c3e7848d1 12555 2.9/stable canonical✓ -
maas-cli 0.6.5 13 latest/stable canonical✓ -
$ lsb_release -a
No LSB modules are available.
Distributor ID: Ubuntu
Description: Ubuntu 20.04.2 LTS
Release: 20.04
Codename: focal
The commissioning of focal VM fails with the following error in the event logs:
TIME | EVENT |
---|---|
Tue, 21 Sep. 2021 03:47:41 | Marking node failed - Commissioning failed, cloud-init reported a failure (refer to the event log for more information) |
Tue, 21 Sep. 2021 03:47:41 | Node commissioning failure - ‘cloudinit’ running modules for config |
These are some of the errors I could spot from syslog, I am not quite sure which one is causing cloud-init to fail.
2021-09-21T02:02:33+00:00 my-host-01 udisksd[641]: failed to load module mdraid: libbd_mdraid.so.2: cannot open shared object file: No such file or directory
2021-09-21T02:02:33+00:00 my-host-01 networkd-dispatcher[632]: No valid path found for iwconfig
2021-09-21T02:02:33+00:00 my-host-01 networkd-dispatcher[632]: No valid path found for iw
2021-09-21T02:02:33+00:00 my-host-01 udisksd[641]: Failed to load the 'mdraid' libblockdev plugin
2021-09-21T02:03:29+00:00 my-host-01 cloud-init[1296]: Cloud-init v. 21.2-3-g899bfaa9-0ubuntu2~20.04.1 running 'modules:config' at Tue, 21 Sep 2021 02:03:24 +0000. Up 80.87 seconds.
2021-09-21T02:03:29+00:00 my-host-01 cloud-init[1296]: 2021-09-21 02:03:29,572 - util.py[WARNING]: Running module apt-configure (<module 'cloudinit.config.cc_apt_configure' from '/usr/lib/python3/dist-packages/cloudinit/config/cc_apt_configure.py'>) failed
2021-09-21T02:03:29+00:00 my-host-01 systemd[1]: cloud-config.service: Failed with result 'exit-code'.
2021-09-21T02:03:29+00:00 my-host-01 systemd[1]: Failed to start Apply the settings specified in cloud-config.
2021-09-21T02:04:35+00:00 my-host-01 cloud-init[2314]: request to http://10-5-1-0--24.maas-internal:5248/MAAS/metadata/2012-03-01/ failed. sleeping 32.: HTTP Error 401: Unauthorized
2021-09-21T02:04:36+00:00 my-host-01 cloud-init[2314]: FAIL: HTTP error [401]Traceback (most recent call last):
2021-09-21T02:04:36+00:00 my-host-01 cloud-init[2314]: File "/tmp/user_data.sh.iHWIap/bin/maas-run-remote-scripts", line 1755, in <module>
2021-09-21T02:04:36+00:00 my-host-01 cloud-init[2314]: main()
2021-09-21T02:04:36+00:00 my-host-01 cloud-init[2314]: File "/tmp/user_data.sh.iHWIap/bin/maas-run-remote-scripts", line 1731, in main
2021-09-21T02:04:36+00:00 my-host-01 cloud-init[2314]: has_content = download_and_extract_tar(
2021-09-21T02:04:36+00:00 my-host-01 cloud-init[2314]: File "/tmp/user_data.sh.iHWIap/bin/maas-run-remote-scripts", line 153, in download_and_extract_tar
2021-09-21T02:04:36+00:00 my-host-01 cloud-init[2314]: ret = geturl(url, creds)
2021-09-21T02:04:36+00:00 my-host-01 cloud-init[2314]: File "/tmp/user_data.sh.iHWIap/bin/maas_api_helper.py", line 115, in geturl
2021-09-21T02:04:36+00:00 my-host-01 cloud-init[2314]: raise error
2021-09-21T02:04:36+00:00 my-host-01 cloud-init[2314]: File "/tmp/user_data.sh.iHWIap/bin/maas_api_helper.py", line 95, in geturl
2021-09-21T02:04:36+00:00 my-host-01 cloud-init[2314]: return urllib.request.urlopen(req)
2021-09-21T02:04:36+00:00 my-host-01 cloud-init[2314]: File "/usr/lib/python3.8/urllib/request.py", line 222, in urlopen
2021-09-21T02:04:36+00:00 my-host-01 cloud-init[2314]: return opener.open(url, data, timeout)
2021-09-21T02:04:36+00:00 my-host-01 cloud-init[2314]: File "/usr/lib/python3.8/urllib/request.py", line 531, in open
2021-09-21T02:04:36+00:00 my-host-01 cloud-init[2314]: response = meth(req, response)
2021-09-21T02:04:36+00:00 my-host-01 cloud-init[2314]: File "/usr/lib/python3.8/urllib/request.py", line 640, in http_response
2021-09-21T02:04:36+00:00 my-host-01 cloud-init[2314]: response = self.parent.error(
2021-09-21T02:04:36+00:00 my-host-01 cloud-init[2314]: File "/usr/lib/python3.8/urllib/request.py", line 569, in error
2021-09-21T02:04:36+00:00 my-host-01 cloud-init[2314]: return self._call_chain(*args)
2021-09-21T02:04:36+00:00 my-host-01 cloud-init[2314]: File "/usr/lib/python3.8/urllib/request.py", line 502, in _call_chain
2021-09-21T02:04:36+00:00 my-host-01 cloud-init[2314]: result = func(*args)
2021-09-21T02:04:36+00:00 my-host-01 cloud-init[2314]: File "/usr/lib/python3.8/urllib/request.py", line 649, in http_error_default
2021-09-21T02:04:36+00:00 my-host-01 cloud-init[2314]: raise HTTPError(req.full_url, code, msg, hdrs, fp)
2021-09-21T02:04:36+00:00 my-host-01 cloud-init[2314]: urllib.error.HTTPError: HTTP Error 401: Unauthorized
2021-09-21T02:04:36+00:00 my-host-01 cloud-init[2314]: Cloud-init v. 21.2-3-g899bfaa9-0ubuntu2~20.04.1 running 'modules:final' at Tue, 21 Sep 2021 02:03:30 +0000. Up 87.15 seconds.
2021-09-21T02:04:36+00:00 my-host-01 cloud-init[2314]: 2021-09-21 02:04:36,123 - cc_scripts_user.py[WARNING]: Failed to run module scripts-user (scripts in /var/lib/cloud/instance/scripts)
2021-09-21T02:04:36+00:00 my-host-01 cloud-init[2314]: 2021-09-21 02:04:36,144 - util.py[WARNING]: Running module scripts-user (<module 'cloudinit.config.cc_scripts_user' from '/usr/lib/python3/dist-packages/cloudinit/config/cc_scripts_user.py'>) failed
2021-09-21T02:04:36+00:00 my-host-01 systemd[1]: cloud-final.service: Main process exited, code=exited, status=1/FAILURE
2021-09-21T02:04:36+00:00 my-host-01 systemd[1]: cloud-final.service: Failed with result 'exit-code'.
2021-09-21T02:04:36+00:00 my-host-01 systemd[1]: Failed to start Execute cloud user/final scripts.
2021-09-21T02:04:36+00:00 my-host-01 systemd[1]: Reached target Cloud-init target.
2021-09-21T02:04
2021-09-21T03:05:58+00:00 my-host-01 systemd-modules-load[392]: Failed to find module 'msr'
2021-09-21T03:05:58+00:00 my-host-01 systemd-sysctl[404]: Not setting net/ipv4/conf/all/promote_secondaries (explicit setting exists).
2021-09-21T03:05:58+00:00 my-host-01 systemd-sysctl[404]: Not setting net/ipv4/conf/default/promote_secondaries (explicit setting exists).
2021-09-21T03:05:58+00:00 my-host-01 systemd-sysctl[404]: Couldn't write 'fq_codel' to 'net/core/default_qdisc', ignoring: No such file or directory
Any clue where should I dig further to find out what’s going wrong?
Would be grateful for any help.
Thanks & Regards,
Sana