%PDF- %PDF-
Mini Shell

Mini Shell

Direktori : /lib/python3/dist-packages/sos/report/plugins/__pycache__/
Upload File :
Create Path :
Current File : //lib/python3/dist-packages/sos/report/plugins/__pycache__/shmcli.cpython-312.pyc

�

i��d���0�ddlmZmZmZGd�dee�Zy)�)�Plugin�IndependentPlugin�	PluginOptc�D�eZdZdZdZdZdZdZefZe	ddd�	�gZ
d
�Zy)�SHMcliashmcli pulls hardware information from PowerVault/Dell
    Storage JBOD's attached to server.
    It provides information of the adapters, emms, drives,
    enclosures, fans, power supplies and the sensory data of
    temp, voltage, and current sensors.
    zDell Server Hardware Manager�shmcli)�system�storage�hardwarezC/opt/dell/ServerHardwareManager/ServerHardwareManagerCLI/bin/shmcli�debugFzcapture support debug data)�default�descc	����|j}gd�}|D]}|j|�d|��d|z���g}|jd�}|ddk(rp|dj�D]Z}|j	�}t|�d	kDs�"|d	j
�d
k(s�9|j|j	�d��\tt|��}gd�}|jd
|zd��}|ddk(r�|dj�d	dD]�}|j	��t�fd�|D��s�(�d}�d}	|D]4}|�d|�d|�d|	��}
|
j|d�}|j|
|���6|jd�s�}|jd��}|�d|�d|	��}
|
j|d�}d|z}|j|
|z|d����|jd|zd��}|ddk(ro|dj�D]X}|j	�}t|�dkDs�"|ddvs�*|�d |d��}
|
j|d�}|j|
|���Zyy)!N)z
list adapterszlist physical enclosureszlist failed drives� z	shmcli_%s)�suggest_filenamez	lsscsi -g�statusr�output��DELL�)
z	list emmszlist drawerszlist emm slotszlist drive slotsz	list fanszlist temp sensorszlist voltage sensorszlist current sensorszlist power supplieszinfo enclosurez%s list enclosures�shmcli_list_enclosures���c3�&�K�|]}|�v���
y�w)N�)�.0�m�_lines  ��;/usr/lib/python3/dist-packages/sos/report/plugins/shmcli.py�	<genexpr>zSHMcli.setup.<locals>.<genexpr>Ms�����2�a�q�E�z�2�s����z -a=z -enc=rrF)�makez getdebugcli -a=z -outputdir=%si,)r�timeoutz%s list drives�shmcli_list_drives�)�WWNz---z info drive -d=)�
shmcli_bin�add_cmd_output�exec_cmd�
splitlines�split�len�upper�append�list�set�collect_cmd_output�any�replace�
get_option�get_cmd_output_path)�self�cmd�subcmds�subcmd�models�result�line�words�adapt_index�	enc_index�_cmd�_fname�logpath�_dcmd�_dname�_odirrs                @r�setupzSHMcli.setup s�����o�o��
���	9�F������'�!,��!7�
 �
9�	9�
�����{�+���(��q� ��x�(�3�3�5�
3���
�
�����J��N�u�Q�x�~�~�'7�6�'A��M�M�$�*�*�,�q�/�2�
3��c�&�k�"��
���(�(� �C�(�5�)�
���(��q� ��x�(�3�3�5�a��;�
���
�
����2�6�2�2�"'��)�K� %�a��I�")�K��#&���Y�!H��!%���c�8�!<���+�+�D�6�+�J�	K�
���w�/�"&�":�":��":�"F��$'��i�"A��!&���s�H�!=��!1�W�!=���+�+�!�E�M�F�$'�,��!
�*�(�(���$�1�)�
���(��q� ��x�(�3�3�5�
K���
�
�����J��N��a���6�#&��a��!2��!%���c�8�!<���+�+�D�6�+�J�
K�!�N)�__name__�
__module__�__qualname__�__doc__�
short_desc�plugin_name�profilesr&�filesr�option_listrErrFrrrsC���0�J��K�1�H�7�J�
�M�E�	�'�5�/K�L��K�LKrFrN)�sos.report.pluginsrrrrrrFr�<module>rQs!��D�C�`K�V�&�`KrF

Zerion Mini Shell 1.0