Performance testing is always to monitor the server, do the ZABBIX monitoring after the important collection of monitoring data, here to share how I do.
Preparing files
python2.7
pypa-setuptools.tar.gzinstalling third-party expansion pack Tools
ArgparseIt is the recommended tool for writing command -line programs in the Python standard library
zabbix-img.py from the attachment, or in the SVN directory folderrun.xlsx Generate Execute command Excel function
zabbix-img.py, run.xlsx :
Http://files.cnblogs.com/files/snifferhu/zabbix-img.rar
Environment Preparation
phpserialize Installation Method:MVPypa-setuptools.Tar. Gz.bak Pypa-setuptools.Tar. gz
Tar-XVF Pypa-setuptools.Tar. gz
CD pypa-*
Python setup.py
Basic Execution zabbix-img.pyPython zabbix-img.py-s20150430083000-P3600-path/home/dbtools/tmp/-G681-N cpu_utilization
parameter Description
- -S: Intercept start time, accurate to seconds
- -P: Duration, seconds
- -path: Picture-Preserving Directory
- -G: For picture ID: corresponds to
- -N: Save picture name
Run.xlse Instructions for use:
Basic command: Execute zabbix-img.py Basic Commands
Start Time parameter:intercept start time, accurate to seconds, note: adjust each time according to the corresponding start timesContinuous monitoring time parameters:duration, seconds, Note: Each test is adjusted according to the corresponding durationsave File Path parameter Step2: This path is "save File Path parameter step1"+" Save file name parameter parent directory "build, do not adjust every timesave File Path parameter Step1: Save picture file Path parameter, Note: save file path every time you write a file according to the testSave Picture ID parameter: Fill in with the ID of the desired saved monitor imagesave file Name parameter parent directory: Fill in the parent address information required to save the file name
save file name parameter corresponding file name:save According to your needscorresponding picture file namefill in the information
Final command: Every time you want to capture the monitor image, copy this column to execute
Create File Address command description:
/root...action/: This line equals "Save file Path parameter Step1 "The following lines are required to manually fill in the parameter parent directory that needs to be generated"
To create a directory script command:This column has functions and does not have to be entered manually
Zabbix Monitoring System _ Monitoring collection script use share