/monitor_agent

Monitor Linux system

Primary LanguagePythonMIT LicenseMIT

monitor_agent

It can be only used with MyPlatform, and can't be used alone.

This Repository is modified based on the Source Repository. If you want to know more information, please access it.

Deploy

  1. Clone Repository

    git clone https://github.com/leeyoshinari/monitor_agent.git
  2. Modify the configuration files config.conf.

  3. Package. Using pyinstaller to package python code.

  • (1) Enter folder, run:
    pyinstaller -F server.py -p performance_monitor.py -p logger.py -p config.py -p common.py -p __init__.py --hidden-import logger --hidden-import performance_monitor --hidden-import common --hidden-import config
  • (2) Copy config.conf to the dist folder, cmd: cp config.conf dist/
  • (3) Enter dist folder, zip files, cmd: zip monitor_agent.zip server config.conf
  • (4) Upload zip file to MyPlatform
  • (5) Deploy monitor_agent

NOTE: For Linux Server, the executable file packaged on the server of the CentOS system X86 architecture can only run on the server of the CentOS system X86 architecture; servers of other system and architecture need to be repackaged.

Note

  1. The server must support the following commands: ps, jstat, iostat, pidstat and netstat, if not, please install them.

  2. The network card of server must be in full duplex mode, if not, the network usage will be incorrect.

  3. The version of sysstat must be 12+, the version of 12.4.0 has been tested, other versions have not been tested, and using old version may cause data abnormalities; please click me to download it.