add sas2ircu and sas3ircu support#595
add sas2ircu and sas3ircu support#595lkx007 wants to merge 1 commit intoRackHD:masterfrom lkx007:master
Conversation
There was a problem hiding this comment.
Unit test must be added as well.
You add "Scripts" in the megaraid catalog task download url, but there is no this item in the option, so it will throw some error when executing.
You could use downloadUrl to get the script from RackHD in runtime, instead of building it in docker. Otherwise it won't work in the discovery workflow who uses discovery docker without this script and tools
| var self = this; | ||
| this._subscribeRequestProperties(function() { | ||
| return self.options; | ||
| }); |
There was a problem hiding this comment.
You could use linux command job for template rendering, and don't need to modify the basic catalog job here which might bring side effect.
There was a problem hiding this comment.
Once upon a time, my raid card could not get catalog info successfully, a certain RackHd developer told me to modify these code. I could not find slack Threads for this.If it is not a bug, I think here code is useless.
| perccliVirtualDiskInfo = 'sudo /opt/MegaRAID/perccli/perccli64 /c0 /vall show all J', | ||
| perccliVersionInfo = 'sudo /opt/MegaRAID/perccli/perccli64 -v', | ||
| sas2ircuInfo = 'sudo python /opt/sas_info.py /opt/sas2ircu', | ||
| sas3ircuInfo = 'sudo python /opt/sas_info.py /opt/sas2ircu', |
| } | ||
| return Promise.resolve({ data: parsed, source: 'megaraid-controllers', store: store }); | ||
| } catch (e) { | ||
| return Promise.resolve({ source: 'megaraid-controllers', error: e }); |
There was a problem hiding this comment.
is the source here still "megaraid-controllers"?
There was a problem hiding this comment.
I am not very familiar with sas2008/sas3008 raid card series, if these cards are mega series?
For convenience, I just put these catalogs to "megaraid-controllers",and my python "/opt/sas_info.py" code stdout is also in "megaraid-controllers" json format.
If these cards not mega series, I think it is better renew a catalog for it.
My inspur server has a raid card (type sas2008) which can not support "perccli" and "storccli", and only support "sas2ircu".
so I add "catalog-sasraid" task using
sudo python /opt/sas_info.py /opt/sas2ircuI put "sas_info.py","sas2ircu","sas3ircu" in docker image ( secure.erase.docker.tar.xz) directory "/opt".
sas_info.py is a python script to parse "sas2ircu" and "sas3ircu" command output to json output.
sas2ircu is a raid command tool which support sas2008 raid card.
sas3ircu is a raid command tool which support sas3008 raid card.