HOME


Mini Shell 1.0
DIR: /usr/lib/python3/dist-packages/sos/report/plugins/__pycache__/
Upload File :
Current File : //usr/lib/python3/dist-packages/sos/report/plugins/__pycache__/filesys.cpython-312.pyc
�

i��d�
��X�ddlmZmZmZmZmZmZGd�deeee�ZGd�dee�Zy)�)�Plugin�RedHatPlugin�DebianPlugin�UbuntuPlugin�	CosPlugin�	PluginOptc�h�eZdZdZdZdZdZeddd��ed	dd
��eddd��gZd
�Z	d�Z
y)�Filesysa�Collects general information about the local filesystem(s) and mount
    points as well as optional information about EXT filesystems. Note that
    information specific filesystems such as XFS or ZFS is not collected by
    this plugin, as there are specific plugins for those filesystem types.

    This plugin will collect /etc/fstab as well as mount information within
    /proc/, and is responsible for the 'mount' and 'df' symlinks that appear
    in an sos archive's root.
    zLocal file systems�filesys)�storage�lsofFz%collect information on all open files)�default�desc�dumpe2fszdump filesystem info�fragz'collect filesystem fragmentation statusc���|jgd��|jddd��|jddd��|jgd��|jd	�|jd
�r|jdd
d�
�d}|jd�rd}d}d}|j	||�D]C}|jd|�d|��d��|jd�s�.|jd|zd���Ey)N)	z	/proc/fs/�/proc/mountsz/proc/filesystemsz/proc/self/mountsz/proc/self/mountinfoz/proc/self/mountstatsz/proc/[0-9]*/mountinfoz	/etc/mtab�
/etc/fstabzmount -l�mount)�root_symlink�tagszdf -al -x autofs�df�df__al)zdf -ali -x autofs�findmnt�lslocksz/proc/fs/panfsr
zlsof -b +M -n -l -P�2)r�priorityz-hr�rz^(/dev/\S+).+ext[234]\s+z	dumpe2fs � �
dumpe2fs_h)rrz
e2freefrag %s�d)r)�
add_copy_spec�add_cmd_output�add_forbidden_path�
get_option�do_regex_find_all)�self�
dumpe2fs_opts�mounts�ext_fs_regex�devs     �</usr/lib/python3/dist-packages/sos/report/plugins/filesys.py�setupz
Filesys.setup%s�����

�
	�	
���J�W�!(�	�	*����.�T�!)�	�	+����
�	�	
��� 0�1��?�?�6�"���� 5�F�)+�
 �
-��
��?�?�:�&��M���2���)�)�,��?�	K�C����M�3� G�%1�
 �
3����v�&��#�#�O�s�$;�c�#�J�	K�c�T�|jddd�d}|jd|d�y)Nrz(password=)[^,\s]*z
\1********z](lsof: (avoiding (.*?)|WARNING: can't stat\(\) (.*?))|Output information may be incomplete.)
r
r)�do_file_sub�do_cmd_output_sub)r'�regexs  r,�postproczFilesys.postprocMs4������!��	
�<��	
���v�u�b�1r.N)�__name__�
__module__�__qualname__�__doc__�
short_desc�plugin_name�profilesr�option_listr-r3�r.r,r
r

sZ���&�J��K��H�	�&�%�>�	@��*�e�2H�I��&�%�@�	B�	�K�&K�P2r.r
c���eZdZ�fd�Z�xZS)�
RedHatFilesysc�L��tt|��|jd�y)Nzls -ltradZ /tmp)�superr>r-r#)r'�	__class__s �r,r-zRedHatFilesys.setup^s���
�m�T�(�*����-�.r.)r4r5r6r-�
__classcell__)rAs@r,r>r>\s
���/�/r.r>N)	�sos.report.pluginsrrrrrrr
r>r<r.r,�<module>rDs4��D�D�L2�f�l�L�)�L2�^/�G�\�/r.