I managed to get a commissioning node to get past enlistment so I could commission with the `allow ssh` option.
I noted a couple of interesting errors from cloud-init logs:
``` 2019-11-05 20:51:47,862 - util.py[DEBUG]: Running command ['/var/lib/cloud/instance/scripts/runcmd'] with allowed return codes [0] (shell=False, capture=False) 2019-11-05 20:51:47,870 - util.py[WARNING]: Failed running /var/lib/cloud/instance/scripts/runcmd [127] 2019-11-05 20:51:47,870 - util.py[DEBUG]: Failed running /var/lib/cloud/instance/scripts/runcmd [127] Traceback (most recent call last): File "/usr/lib/python3/dist-packages/cloudinit/util.py", line 870, in runparts subp(prefix + [exe_path], capture=False) File "/usr/lib/python3/dist-packages/cloudinit/util.py", line 2065, in subp cmd=args) cloudinit.util.ProcessExecutionError: Unexpected error while running command. Command: ['/var/lib/cloud/instance/scripts/runcmd'] Exit code: 127 Reason: - Stdout: - Stderr: - 2019-11-05 20:51:47,877 - util.py[DEBUG]: Running command ['/var/lib/cloud/instance/scripts/user_data.sh'] with allowed return codes [0] (shell=False, capture=False) 2019-11-05 20:52:59,003 - cc_scripts_user.py[WARNING]: Failed to run module scripts-user (scripts in /var/lib/cloud/instance/scripts) 2019-11-05 20:52:59,005 - url_helper.py[DEBUG]: [0/1] open 'http://192-168-2-0--24.maas-internal:5248/MAAS/metadata/status/qdpd87' with {'method': 'POST', 'headers': {'Authorization': 'OAuth oauth _nonce="123063311710824411781572987179", oauth_timestamp="1572987179", oauth_version="1.0", oauth_signature_method="PLAINTEXT", oauth_consumer_key="J4r8FcjhaGmPTkjqwY", oauth_token="FVWwc3fXZDaUSu aPWe", oauth_signature="%26uvQtSWmCthUyFYdUaKTkW4DcNwXnQTuY"'}, 'allow_redirects': True, 'url': 'http://192-168-2-0--24.maas-internal:5248/MAAS/metadata/status/qdpd87'} configuration 2019-11-05 20:52:59,014 - url_helper.py[DEBUG]: Read from http://192-168-2-0--24.maas-internal:5248/MAAS/metadata/status/qdpd87 (204, 0b) after 1 attempts 2019-11-05 20:52:59,015 - handlers.py[DEBUG]: finish: modules-final/config-scripts-user: FAIL: running config-scripts-user with frequency once-per-instance 2019-11-05 20:52:59,015 - 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'>) fail ed 2019-11-05 20:52:59,015 - util.py[DEBUG]: Running module scripts-user (<module 'cloudinit.config.cc_scripts_user' from '/usr/lib/python3/dist-packages/cloudinit/config/cc_scripts_user.py'>) failed Traceback (most recent call last): File "/usr/lib/python3/dist-packages/cloudinit/stages.py", line 812, in _run_modules freq=freq) File "/usr/lib/python3/dist-packages/cloudinit/cloud.py", line 54, in run return self._runners.run(name, functor, args, freq, clear_on_fail) File "/usr/lib/python3/dist-packages/cloudinit/helpers.py", line 188, in run return (True, results) File "/usr/lib/python3.5/contextlib.py", line 77, in __exit__ self.gen.throw(type, value, traceback) File "/usr/lib/python3/dist-packages/cloudinit/helpers.py", line 76, in lock yield self._acquire(name, freq) File "/usr/lib/python3/dist-packages/cloudinit/helpers.py", line 187, in run results = functor(*args) File "/usr/lib/python3/dist-packages/cloudinit/config/cc_scripts_user.py", line 45, in handle util.runparts(runparts_path) File "/usr/lib/python3/dist-packages/cloudinit/util.py", line 877, in runparts % (len(failed), len(attempted))) RuntimeError: Runparts: 1 failures in 2 attempted commands 2019-11-05 20:52:59,039 - stages.py[DEBUG]: Running module ssh-authkey-fingerprints (<module 'cloudinit.config.cc_ssh_authkey_fingerprints' from '/usr/lib/python3/dist-packages/cloudinit/config/cc_ssh_authkey_fingerprints.py'>) with frequency once-per-instance ```
I'll try and post full logs to this bug report...
I managed to get a commissioning node to get past enlistment so I could commission with the `allow ssh` option.
I noted a couple of interesting errors from cloud-init logs:
``` lib/cloud/ instance/ scripts/ runcmd' ] with allowed return codes [0] (shell=False, capture=False) cloud/instance/ scripts/ runcmd [127] cloud/instance/ scripts/ runcmd [127] python3/ dist-packages/ cloudinit/ util.py" , line 870, in runparts python3/ dist-packages/ cloudinit/ util.py" , line 2065, in subp util.ProcessExe cutionError: Unexpected error while running command. lib/cloud/ instance/ scripts/ runcmd' ] lib/cloud/ instance/ scripts/ user_data. sh'] with allowed return codes [0] (shell=False, capture=False) user.py[ WARNING] : Failed to run module scripts-user (scripts in /var/lib/ cloud/instance/ scripts) py[DEBUG] : [0/1] open 'http:// 192-168- 2-0--24. maas-internal: 5248/MAAS/ metadata/ status/ qdpd87' with {'method': 'POST', 'headers': {'Authorization': 'OAuth oauth "12306331171082 441178157298717 9", oauth_timestamp ="1572987179" , oauth_version= "1.0", oauth_signature _method= "PLAINTEXT" , oauth_consumer_ key="J4r8FcjhaG mPTkjqwY" , oauth_token= "FVWwc3fXZDaUSu ="%26uvQtSWmCth UyFYdUaKTkW4DcN wXnQTuY" '}, 'allow_redirects': True, 'url': 'http:// 192-168- 2-0--24. maas-internal: 5248/MAAS/ metadata/ status/ qdpd87'} configuration py[DEBUG] : Read from http:// 192-168- 2-0--24. maas-internal: 5248/MAAS/ metadata/ status/ qdpd87 (204, 0b) after 1 attempts final/config- scripts- user: FAIL: running config-scripts-user with frequency once-per-instance config. cc_scripts_ user' from '/usr/lib/ python3/ dist-packages/ cloudinit/ config/ cc_scripts_ user.py' >) fail config. cc_scripts_ user' from '/usr/lib/ python3/ dist-packages/ cloudinit/ config/ cc_scripts_ user.py' >) failed python3/ dist-packages/ cloudinit/ stages. py", line 812, in _run_modules python3/ dist-packages/ cloudinit/ cloud.py" , line 54, in run run(name, functor, args, freq, clear_on_fail) python3/ dist-packages/ cloudinit/ helpers. py", line 188, in run python3. 5/contextlib. py", line 77, in __exit__ gen.throw( type, value, traceback) python3/ dist-packages/ cloudinit/ helpers. py", line 76, in lock python3/ dist-packages/ cloudinit/ helpers. py", line 187, in run python3/ dist-packages/ cloudinit/ config/ cc_scripts_ user.py" , line 45, in handle runparts( runparts_ path) python3/ dist-packages/ cloudinit/ util.py" , line 877, in runparts fingerprints (<module 'cloudinit. config. cc_ssh_ authkey_ fingerprints' from '/usr/lib/ python3/ dist-packages/ cloudinit/ config/ cc_ssh_ authkey_ fingerprints. py'>) with frequency once-per-instance
2019-11-05 20:51:47,862 - util.py[DEBUG]: Running command ['/var/
2019-11-05 20:51:47,870 - util.py[WARNING]: Failed running /var/lib/
2019-11-05 20:51:47,870 - util.py[DEBUG]: Failed running /var/lib/
Traceback (most recent call last):
File "/usr/lib/
subp(prefix + [exe_path], capture=False)
File "/usr/lib/
cmd=args)
cloudinit.
Command: ['/var/
Exit code: 127
Reason: -
Stdout: -
Stderr: -
2019-11-05 20:51:47,877 - util.py[DEBUG]: Running command ['/var/
2019-11-05 20:52:59,003 - cc_scripts_
2019-11-05 20:52:59,005 - url_helper.
_nonce=
aPWe", oauth_signature
2019-11-05 20:52:59,014 - url_helper.
2019-11-05 20:52:59,015 - handlers.py[DEBUG]: finish: modules-
2019-11-05 20:52:59,015 - util.py[WARNING]: Running module scripts-user (<module 'cloudinit.
ed
2019-11-05 20:52:59,015 - util.py[DEBUG]: Running module scripts-user (<module 'cloudinit.
Traceback (most recent call last):
File "/usr/lib/
freq=freq)
File "/usr/lib/
return self._runners.
File "/usr/lib/
return (True, results)
File "/usr/lib/
self.
File "/usr/lib/
yield self._acquire(name, freq)
File "/usr/lib/
results = functor(*args)
File "/usr/lib/
util.
File "/usr/lib/
% (len(failed), len(attempted)))
RuntimeError: Runparts: 1 failures in 2 attempted commands
2019-11-05 20:52:59,039 - stages.py[DEBUG]: Running module ssh-authkey-
```
I'll try and post full logs to this bug report...