%PDF- %PDF-
Direktori : /lib/python3/dist-packages/sos/report/plugins/__pycache__/ |
Current File : //lib/python3/dist-packages/sos/report/plugins/__pycache__/ovn_central.cpython-312.pyc |
� i��d� � �| � d dl mZmZmZmZ d dlZd dlZd dlZ G d� de� Z G d� dee� Z G d� deee� Z y) � )�Plugin�RedHatPlugin�DebianPlugin�UbuntuPluginNc �8 � e Zd ZdZdZdZdZd� Zg fd�Zd� Z d� Z y ) � OVNCentralz OVN Northd�ovn_central)�network�virt)zovn-dbs-bundle.*�ovn_cluster_north_db_serverc � � t j j ||� }| j r�| j d|z | j �� }|d dk7 sd|d vr | j d| j z � |S t j |� }|d j d� D ]5 }|j |� s�t j j ||� c S |S )Nzls %s)� container�statusr � �outputz?Could not retrieve ovn_controller socket path from container %s) �os�path�join�_container_name�exec_cmd� _log_error�re�compile�split�match)�selfr � regex_name�_sfile�res�pattern�filenames �@/usr/lib/python3/dist-packages/sos/report/plugins/ovn_central.py� _find_sockzOVNCentral._find_sock s� � ������d�J�/������-�-��$��$�:N�:N�-�O�C��8�}��!�T��X��%>����(�*.�*>�*>�?�� � � �*�*�Z�0�� #�H� � 3� 3�D� 9� <�H��}�}�X�.�!�w�w�|�|�D�(�;�;�<� � � c � � | j red|z }| j |d d| j �� }|d dk7 r| j d| j z � y t j |d � }n< t | j |� d � 5 } t j |� } d d d � t j d � D �cg c] }||vr|�� c}S # t $ r | j d|z � Y y w xY w# t $ r | j d|z � Y d d d � y w xY w# 1 sw Y ��xY w# t $ r!}| j d |�d|��� Y d }~y d }~ww xY wc c}w # t $ r | j d |z � Y y w xY w)Nzcat %sT)�timeout� foregroundr r r z3Could not retrieve DB schema file from container %sr zCannot parse JSON file %s�rzCould not open DB schema file z: �tablesz DB schema %s has no 'tables' key) r r r �json�loads� Exception�open� path_join�load�IOError�dict�keys�AttributeError) r r! �skip�cmdr �db�f�ex�tables r"