a >h @sZddlZddlmZmZmZmZGdddeZGdddeeZGdddeeeZdS) N)Plugin RedHatPlugin DebianPlugin UbuntuPluginc@s,eZdZdZdZdZdZddZddZd S) CorosynczCorosync cluster enginecorosync)Zcluster)rc Cs|gd|gd|jddd|dd}||sFdSd}zj|d}t|d d d >}|D](}t||rj|t|| d qjWdn1s0YWn:t y}z"| d |d|WYd}~n d}~00dS)N)z /etc/corosyncz/var/lib/corosync/fdataz/var/log/cluster/corosync.log*)zcorosync-quorumtool -lzcorosync-quorumtool -szcorosync-cpgtoolzcorosync-cfgtool -szcorosync-blackboxzcorosync-objctl -azcorosync-cmapctl -m statszcorosync-cmapctlZcorosync_cmapctl)tagszkillall -USR2 corosyncz/etc/corosync/corosync.confz ^\s*(logging.)?logfile:\s*(\S+)$rzUTF-8)encodingzcould not read from z: ) Z add_copy_specZadd_cmd_outputZexec_cmdZ path_existsZ path_joinopenrematchsearchgroupIOErrorZ _log_warn)selfZ corosync_confpatternZcconffilelineerrr?/usr/lib/python3.9/site-packages/sos/report/plugins/corosync.pysetups$     <zCorosync.setupcCs|ddddS)Nzcorosync-objctlz(.*fence.*\.passwd=)(.*)z\1******)Zdo_cmd_output_sub)rrrrpostproc;s zCorosync.postprocN) __name__ __module__ __qualname__Z short_descZ plugin_nameZprofilesZpackagesrrrrrrr s &rc@seZdZdZdS)RedHatCorosync0 Parent class Corosync's setup() will be called N)rrr__doc__rrrrrCsrc@seZdZdZdZdS)DebianCorosyncr)z/usr/sbin/corosyncN)rrrr filesrrrrr!Gsr!) r Zsos.report.pluginsrrrrrrr!rrrr s6