how to modify default commissioning scripts?

Asked by osprey

I'm hitting a bug in lshw that is preventing me to use some of my systems with maas.
Basically lshw segfaults during the initial commissioning phase as stated in the bug https://bugs.launchpad.net/ubuntu/+source/lshw/+bug/1815788

However the same lshw command runs successfully if run with --disable SCSI flag.

Since I have no SCSI interfaces on these systems, Is there a way to modify the default commissioning script in order to add the --disable SCSI flag for lshw as a workaround for my problem?

Question information

Language:
English Edit question
Status:
Open
For:
Ubuntu maas Edit question
Assignee:
No assignee Edit question
Last query:
Last reply:
Revision history for this message
osprey (theosprey) said :
#1

As far as I could dig the command can be modified by editing the file /usr/lib/python3/dist-packages/provisioningserver/refresh/node_info_scripts.py provided by package python3-maas-provisioningserver.

However I modified the .py file, but when I try to provision a system, maas seems to run the original command.

I suppose that there is some caching here that is preventing the new script to be used to perform the system commissioning. I'm almost new with python. Is it safe to simply delete the __pycache__ directory in order to force the usage of the new script?

Can you help with this problem?

Provide an answer of your own, or ask osprey for more information if necessary.

To post a message you must log in.