Skip to content
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

pystorcli2 is incompatible with storcli2/percli2 #20

Open
dgilbert101 opened this issue Jun 3, 2024 · 3 comments
Open

pystorcli2 is incompatible with storcli2/percli2 #20

dgilbert101 opened this issue Jun 3, 2024 · 3 comments

Comments

@dgilbert101
Copy link
Contributor

I'm encountering more and more raid cards that are only compatible with storcli2/percli2, which is problematic with the current library. For the most part the commands are roughly the same, but the output is different. What do we think is the best way to handle different output like this? It would be relatively simple if the keys were just different in name, but some are nested under varying levels of keys to get the same answer; ie

storcli64 output for getting virtual drive facts

"Response Data" : {
"VD0 Properties" : {
"Strip Size" : "256 KB",

storcli2 output for getting virtual drive facts

"Response Data" : {
"Virtual Drives" : [
{
"VD Info" : {
"DG/VD" : "0/1",
"TYPE" : "RAID6",
"State" : "Optl",
"Access" : "RW",
"CurrentCache" : "NR,AWB",
"DefaultCache" : "NR,AWB",
"Size" : "392.896 TiB",
"Name" : ""
},
"PDs" : [
{
"EID:Slt" : "355:6",
...
"Alt-EID" : "-"
}
],
"VD Properties" : {
"Strip Size" : "256 KiB",
"Block Size" : 4096,
"Number of Blocks" : 1054674616

Is it best to keep it in the same library? Create a new library? Probably goes along the lines the of the factory pattern conversation and pyarcconf.

@dgilbert101 dgilbert101 changed the title pystorcli is incompatible with storcli2/percli2 pystorcli2 is incompatible with storcli2/percli2 Jun 3, 2024
@ralequi
Copy link
Member

ralequi commented Jun 4, 2024

Didn't notice storcli have been replaced that fast with storcli2. All my raid cards still works with storcli64.

The last year, I've been discussing with @ulmitov to provide a single lib that merges all the raid-card controlling software.
Probably, this justifies even more to work in that direction. And, of course, a factory pattern here looks a good idea.

I think the real question here is, should we "update" pystorcli to support all of them "transparently" or should we create a new project for this?

@dgilbert101
Copy link
Contributor Author

Yeah, its a bigger conversation for certain. I do have a need for something sooner than later, so I might attempt to upgrade the current to check for various keys and such. Whether that gets integrated in now or lives as a separate fork is a conversation for a later time.

@ulmitov
Copy link
Collaborator

ulmitov commented Jun 9, 2024

Since it is possible to identify which cli should be used for which card, a single tool for smartctl and all the raid cli's would be great, all of them being used in the same manner and similar design and parsing of results.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants