HEX
Server: Apache
System: Linux dinesh8189 5.15.98-grsec-sharedvalley-2.lc.el8.x86_64 #1 SMP Thu Mar 9 09:07:30 -03 2023 x86_64
User: cgmgerenciamento1 (814285)
PHP: 8.1.26
Disabled: apache_child_terminate,dl,escapeshellarg,escapeshellcmd,exec,link,mail,openlog,passthru,pcntl_alarm,pcntl_exec,pcntl_fork,pcntl_get_last_error,pcntl_getpriority,pcntl_setpriority,pcntl_signal,pcntl_signal_dispatch,pcntl_sigprocmask,pcntl_sigtimedwait,pcntl_sigwaitinfo,pcntl_strerror,pcntl_wait,pcntl_waitpid,pcntl_wexitstatus,pcntl_wifexited,pcntl_wifsignaled,pcntl_wifstopped,pcntl_wstopsig,pcntl_wtermsig,php_check_syntax,php_strip_whitespace,popen,proc_close,proc_open,shell_exec,symlink,system
Upload Files
File: //usr/lib/python3.6/site-packages/sos/report/plugins/__pycache__/shmcli.cpython-36.pyc
3

3��d��@s*ddlmZmZmZGdd�dee�ZdS)�)�Plugin�IndependentPlugin�	PluginOptc@s>eZdZdZdZdZdZdZefZe	dd	d
d�gZ
dd
�ZdS)�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)�defaultZdescc
s>|j}dddg}x&|D]}|jd||fd|d�qWg}|jd�}|dd	kr�xJ|d
j�D]:}|j�}t|�dkr`|dj�dkr`|j|j�d
�q`Wtt	|��}ddddddddddg
}|j
d|dd�}|dd	k�r�x�|d
j�dd,�D]�}|j��t�fdd�|D��r��d-}�d	}	x8|D]0}d||||	f}
|
j|d�}|j|
|d��q0W|j
d�r�|jd d!�}d"|||	f}
|
j|d�}d#|}|j|
||d$d%�q�W|j
d&|d'd�}|dd	k�r:xd|d
j�D]T}|j�}t|�d(k�r�|d	d.k�r�d+||d	f}
|
j|d�}|j|
|d��q�WdS)/Nz
list adapterszlist physical enclosureszlist failed drivesz%s %sz	shmcli_%s)�suggest_filenamez	lsscsi -gZstatusr�output�ZDELL�z	list emmszlist drawerszlist emm slotszlist drive slotsz	list fanszlist temp sensorszlist voltage sensorszlist current sensorszlist power supplieszinfo enclosurez%s list enclosuresZshmcli_list_enclosuresc3s|]}|�kVqdS)N�)�.0�m)�_liner�/usr/lib/python3.6/shmcli.py�	<genexpr>MszSHMcli.setup.<locals>.<genexpr>�z%s %s -a=%s -enc=%srr
F)Zmakez%s getdebugcli -a=%s -enc=%sz -outputdir=%si,)rZtimeoutz%s list drivesZshmcli_list_drives��WWN�---z%s info drive -d=%s������)rr)�
shmcli_binZadd_cmd_outputZexec_cmd�
splitlines�split�len�upper�append�list�setZcollect_cmd_output�any�replaceZ
get_optionZget_cmd_output_path)�self�cmdZsubcmdsZsubcmdZmodels�result�lineZwordsZadapt_indexZ	enc_indexZ_cmdZ_fnameZlogpathZ_dcmdZ_dnameZ_odirr)rr�setup sz




zSHMcli.setupN)rrr	)�__name__�
__module__�__qualname__�__doc__Z
short_descZplugin_nameZprofilesr�filesrZoption_listr*rrrrrsrN)Zsos.report.pluginsrrrrrrrr�<module>	s