3 ܓi @s.ddlZddlmZmZGdddeeZdS)N)Plugin RedHatPluginc@s,eZdZdZdZd Zd ZddZd d Zd S)LustrezLustre filesystemlustrestoragenetworkcluster lustre-clientcCs&|jddj|d|dddS)zZUse lctl get_param to collect a selection of parameters into a file. zlctl get_param  zparams-F)Zsuggest_filenamestderrN)add_cmd_outputjoin)selfnameZ param_listr/usr/lib/python3.6/lustre.py get_paramsszLustre.get_paramscs|jdddddg|jdd}dfd d |jD}|jd ||jd d ddg|jd|jddg|jdddddg|jddddg|jddg|jddd g|jd!|jd"d#g|jd$r|jd%|jd&d'g|jd(d(gdS))Nzlctl debug_kernelzlctl device_listzlctl list_nidszlctl route_listzlnetctl net show -v 4zlctl list_param -R *outputzn.*@.*|.*dump_page_cache|peers|.*quota.*|osd-.*|.*osc.*|mgs.*|.*mgc_irstate|ldlm.*state|.*job_stats|.*exports.*csg|]}tj|s|qSr)rematch).0item)excluderr +sz Lustre.setup..allZbasicversionZ health_checkdebugz/etc/lnet.confzlfs dfz lfs df -iZ osc_clientzosc.*.max_dirty_mbzosc.*.max_pages_per_rpczosc.*.checksumszosc.*.max_rpcs_in_flightZosdz9osd-*.*.{blocksize,brw_stats,enable_projid_xattr,extent*}z8osd-*.*.{fallocate_*,full_scrub_*,files*,kbytes*,mntdev}z7osd-*.*.{nonrotational,oi_scrub,pdo,stats,read*,write*}Zquotaz)osd-*.*.quota_slave.{info,limit_*,acct_*}Zmgszmgs.MGS.ir_timeoutzmgs.MGS.live.*z */mb_groupsz/sys/fs/ldiskfsz/proc/fs/ldiskfsZall_logsz/tmp/lustre-log.*z job-statsz *.*.job_statsZpeers)r Zexec_cmd splitlinesrZ add_copy_specZadd_forbidden_pathZ get_option)rrZparamsr)rrsetupsH      z Lustre.setupN)rrr)rr ) __name__ __module__ __qualname__Z short_descZ plugin_nameZprofilesZpackagesrrrrrrr s  r)rZsos.report.pluginsrrrrrrr s