MAAS errors on formatting micron disks if nvme command returns non-standard characters
| Affects | Status | Importance | Assigned to | Milestone | |
|---|---|---|---|---|---|
| MAAS |
Triaged
|
High
|
Unassigned | ||
Bug Description
When doing a format of the disk, MAAS runs ./maas_wipe.py
For us, it was producing the following error:
Traceback (most recent call last):
File "/home/
main()
File "/home/
disk_info = get_disk_info()
File "/home/
return {kname: get_disk_
File "/home/
return {kname: get_disk_
File "/home/
return get_nvme_
File "/home/
output = output.decode()
UnicodeDecodeError: 'utf-8' codec can't decode byte 0xfc in position 392: invalid start byte
The underlying issue was that it was failing to decode the output of the "nvme" command. In our case when we ran the following command in the ephemeral OS: sudo nvme id-ctrl /dev/nvme1n1
It returned the line: fguid : :8w�
The non-standard character at the end is causing the error on the line:
output = output.decode()
The fix that we've come up with is to change the line to this:
output = output.
I'd like to find a way to apply this patch because we're running into the issue pretty frequently when we upgrade the firmware on our Micron disks.
| Changed in maas: | |
| status: | New → Triaged |
| importance: | Undecided → High |
| milestone: | none → 3.6.0 |

Same problem to this bug report? /bugs.launchpad .net/ubuntu/ +source/ nvme-cli/ +bug/2051299
https:/