_get_host_sysinfo_serial_os fails with different exceptions if the machine-id file is not present or if it is empty
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
OpenStack Compute (nova) |
Fix Released
|
Medium
|
Andrea Rosa |
Bug Description
When the sysinfo_serial config parameter for the libvirt driver is set to 'os', the defined behavior is:
- return the value found in /etc/machine-id file or
- return an error if the file is not present.
There is an additional scenario where the file is present but it is empty
(https:/
At the moment the missing file and an empty file return different exceptions:
- IOError for a missing file
- IndexError for an empty file
Both of these errors are too general and don't give a big help in debugging the issue.
Please note that we do not want to fix the issue about a missing/empty machine-id file, that is something related to a bad OS installation/
Changed in nova: | |
assignee: | nobody → Andrea Rosa (andrea-rosa-m) |
tags: | added: low-hanging-fruit |
summary: |
- _get_host_sysinfo_serial_os fails if the machine-id file is empty + _get_host_sysinfo_serial_os fails with different exceptions if the file + is not present or if it is empty |
description: | updated |
summary: |
- _get_host_sysinfo_serial_os fails with different exceptions if the file - is not present or if it is empty + _get_host_sysinfo_serial_os fails with different exceptions if the + machine-id file is not present or if it is empty |
Changed in nova: | |
assignee: | Andrea Rosa (andrea-rosa-m) → Alexis Lee (alexisl) |
Changed in nova: | |
assignee: | Alexis Lee (alexisl) → Andrea Rosa (andrea-rosa-m) |
Changed in nova: | |
milestone: | none → liberty-3 |
status: | Fix Committed → Fix Released |
Changed in nova: | |
milestone: | liberty-3 → 12.0.0 |
Changed in nova: | |
importance: | Undecided → High |
tags: | added: libvirt |
Changed in nova: | |
importance: | High → Medium |
Fix proposed to branch: master /review. openstack. org/202640
Review: https:/