HEX
Server: Apache
System: Linux bd12.noc223.com 4.18.0-553.121.1.lve.el8.x86_64 #1 SMP Thu Apr 30 16:40:41 UTC 2026 x86_64
User: handcraf (1693)
PHP: 8.1.28
Disabled: NONE
Upload Files
File: //usr/local/lib/python3.6/site-packages/agent360/plugins/__pycache__/bird.cpython-36.pyc
3

I9�iI�@s8ddlZddlZGdd�dej�Zedkr4e�j�dS)�Nc@seZdZdZdd�ZdS)�PluginZbirdcCsvi}ttjd�j��|d<ttjd�j��|d<ttjd�j��|d<ttjd�j��|d<ttjd	�j��|d
<|S)z;
        Monitor status of bgp sessions using bird
        z0sudo birdc show proto | /bin/grep -c EstablishedZestablishedz,sudo birdc show proto | /bin/grep -c Connect�connectz+sudo birdc show proto | /bin/grep -c Active�activez?sudo birdc show proto | /bin/grep -c "Connection reset by peer"Z
conn_reset_bpz9sudo birdc show proto | /bin/grep -c "Hold timer expired"Z
hold_timer)�int�os�popen�read)�self�config�data�r�>/root/tmp/pip-build-pyanas3z/agent360/agent360/plugins/bird.py�run	sz
Plugin.runN)�__name__�
__module__�__qualname__rrrrr
rsr�__main__)rZpluginsZ
BasePluginrr�executerrrr
�<module>s