New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
lsmcli -u hpsa:// ld PLUGIN_BUG(2): Expected key missing from SmartArray ssacli output:'Serial Number' #420
Comments
@cstoyanov-scality Thanks for creating the issue, please open a pull request for review and inclusion. Thanks! |
When picking default values for things that are not available, we need to keep them the same type. For example when we cannot retrieve the |
@cstoyanov-scality Any update on this one? Does my comment above make sense? |
@cstoyanov-scality I'm going to be rolling a new release next week. If you would like this to be included please supply a patch to mailing list or PR soon. Thanks Also as a follow-up to my previous comment, the library does have some constants for things that aren't retrieveable, like when you can't get the RPM. We will want to utilize these where they make sense. #define LSM_DISK_RPM_UNKNOWN -1 |
Resolves: libstorage#420 Note: This change is an adaptation of the one provided by Christophe Stoyanov. Specifically, when we cannot retrieve all the needed values we select default values of the proper type and domain eg. id, disk_name -> string blk_size, blk_count -> unsigned integer rpm -> Disk.RPM_UNKNOWN Signed-off-by: Tony Asleson <tasleson@redhat.com>
Resolves: libstorage#420 Note: This change is an adaptation of the one provided by Christophe Stoyanov. Specifically, when we cannot retrieve all the needed values we select default values of the proper type and domain eg. id, disk_name -> string blk_size, blk_count -> unsigned integer rpm -> Disk.RPM_UNKNOWN Signed-off-by: Tony Asleson <tasleson@redhat.com>
Description
When the Serial Number of the physical disk cannot be retrieved, lsmcli fails with a PLUGIN_BUG error. For example:
Depending on the way the disk is broken, the ssacli report can contains or not some info. In the hpsa plugin of lsm, some information are expected to exist (if not, it raises with a KeyError exception).
the ssacli output which cannot be parsed by lsm is:
The following values does not exist for the failed disk 2I:1:8 compared to a healthy disk:
In using default values for the ones which cannot be find, the problem does not occur anymore. For example, a patch could be:
With this patch, the output looks like:
The text was updated successfully, but these errors were encountered: