3.1 failed to add IPMI host

hello everyone

I have newly deployed a set of Maas 3.1. When adding an IPMI host through the UI, I will prompt “failed to query node’s BMC - incorrect username. Check BMC configuration and try again”

It’s strange that the user, password and IP are correct (I can log in to IPMI normally through IE to restart the server), but Maas just prompts failure

Attached log:

Thu, 23 Dec. 2021 16:08:48 Failed to power on node - Power on for the node failed: Could not authenticate to node’s BMC: Incorrect username. Check BMC configuration and try again.
Thu, 23 Dec. 2021 16:08:48 Node changed status - From ‘Commissioning’ to ‘Failed commissioning’
Thu, 23 Dec. 2021 16:08:48 Marking node failed - Power on for the node failed: Could not authenticate to node’s BMC: Incorrect username. Check BMC configuration and try again.
Thu, 23 Dec. 2021 16:08:48 Powering on
Thu, 23 Dec. 2021 16:08:48 Node changed status - From ‘New’ to ‘Commissioning’
Thu, 23 Dec. 2021 16:08:48 Commissioning
1 Like

I’m having the same problem. It looks to be an issue with the bmc_config commision script again:

INFO: Loading IPMI kernel modules...
INFO: Checking for HP Moonshot...
INFO: Checking for IPMI...
INFO: IPMI detected!
INFO: Reading current IPMI BMC values...
INFO: Configuring IPMI Lan_Channel...
INFO: Configuring IPMI Lan_Channel_Auth...
INFO: Lan_Channel_Auth settings unavailable!
INFO: Configuring IPMI cipher suite ids...
INFO: Gathering supported cipher suites and current configuration...
INFO: BMC supports the following ciphers - [0, 1, 2, 3, 6, 7, 8, 11, 12, 15, 16, 17]
INFO: Current cipher suite configuration - XXXaXXXXXXXaXXX
INFO: Disabling insecure cipher suite 11...
INFO: New cipher suite configuration - XXXaXXXXXXXXXXX
INFO: MAAS will use IPMI cipher suite id "17" for BMC communication
INFO: Found existing K_g BMC key!
INFO: Configuring IPMI Serial_Channel...
INFO: Serial_Channel settings unavailable!
INFO: Configuring IPMI SOL_Conf...
INFO: Found existing IPMI user "maas"!
INFO: Configuring IPMI BMC user "maas"...
INFO: IPMI user number - User5
INFO: IPMI user privilege level - Administrator
INFO: IPMI Version - LAN_2_0
INFO: IPMI boot type - efi

It’s incorrectly setting the cipher suite configuration…

Looks like the issue is with this line:

for i, c in enumerate(current_suite_privs):

It’s assuming the ciphers are sequential from 0 without gaps, but this isn’t the case.

Hi there, this has actually been fixed in MAAS’ development branch https://bugs.launchpad.net/maas/+bug/1916860, and will be available in the next release.

Thanks

I patched the script on 3.1 doing this on the db:

update metadataserver_script set "default"=FALSE where name='30-maas-01-bmc-config'; 

Then:

wget "https://git.launchpad.net/maas/plain/src/metadataserver/builtin_scripts/commissioning_scripts/bmc_config.py?id=b0956f649955f27657bcc635c04cb3e7809c4060" -O bmc_config.py
maas REGION node-script update 30-maas-01-bmc-config script@=bmc_config.py

And setting back to default:

update metadataserver_script set "default"=TRUE where name='30-maas-01-bmc-config';