o
    id	                     @   s6   d dl mZmZmZ d dlmZ G dd deeZdS )    )PluginRedHatPlugin	PluginOptis_executablec                   @   sJ   e Zd ZdZdZdZeddeddgZdd	 Z	d
d Z
dd Zdd ZdS )NaviclizEMC Naviclinavicli)storagehardwareipaddrs z-space-delimited list of CLARiiON IP addresses)defaultval_typedescc                 C   s   t dS )Nr   r   self r   </usr/lib/python3/dist-packages/sos/report/plugins/navicli.pycheck_enabled   s   zNavicli.check_enabledc                 C   s   |  g d dS )zH EMC Navisphere Host Agent NAVICLI specific information - files
        )z/etc/Navisphere/agent.configz/etc/Navisphere/Navimon.cfgz/etc/Navisphere/Quietmode.cfgz/etc/Navisphere/messages/[a-z]*z/etc/Navisphere/log/[a-z]*N)add_copy_specr   r   r   r   get_navicli_config   s   zNavicli.get_navicli_configc                 C   s\   |  d| d| d| d| d| d| d| d| d	| d
| d| d| d| g dS )z^ EMC Navisphere Host Agent NAVICLI specific
        information - CLARiiON - commands
        znavicli -h %s getallznavicli -h %s getsptime -spaznavicli -h %s getsptime -spbznavicli -h %s getlogznavicli -h %s getdiskznavicli -h %s getcacheznavicli -h %s getlunz>navicli -h %s getlun -rg -type -default -owner -crus -capacityznavicli -h %s lunmapinfoznavicli -h %s getcrusznavicli -h %s port -list -allz navicli -h %s storagegroup -listznavicli -h %s spportspeed -getN)add_cmd_output)r   
SP_addressr   r   r   get_navicli_SP_info)   s"   
zNavicli.get_navicli_SP_infoc                 C   sD   |    t| d D ]}| d| d dkr| | qd S )Nr   znavicli -h %s getsptimestatusr   )r   set
get_optionsplitexec_cmdr   )r   ipr   r   r   setup>   s   
zNavicli.setupN)__name__
__module____qualname__
short_descplugin_nameprofilesr   stroption_listr   r   r   r    r   r   r   r   r      s    r   N)sos.report.pluginsr   r   r   sos.utilitiesr   r   r   r   r   r   <module>   s   