If you have a dedicated server or VPS, it is also necessary to do basic monitoring on it. When I used VPS in the past, good VPS didn’t do monitoring because after adding some servers, I became even more nervous about its performance. There are also many foreign server performance monitoring websites, but it is a bit difficult for people like good VPS who rely on Google to read English. So, today we will share the simple server performance monitoring implemented using SNMP+ Monitoring Bao .
Monitoring Bao recommends using NET-SNMP, so this article also uses this as an example.
First, we install NET-SNMP.
yum install net-snmp net-snmp-devel net-snmp-utils
Next we start configuring NET-SNMP.
Before configuring, we need to confirm that SELinux is turned off (note for CentOS systems), and then temporarily stop NET-SNMP.
service snmpd stop
Then, add a read-only account (such as vpsaa.com), create a password (such as 123456), and transfer it in MD5
| 1 |
net-snmp-config --create-snmpv3-user -ro -A 123456 -a MD5 vpsaa.com |
Next, start NET-SNMP
service snmpd start
Add NET-SNMP to the startup items
chkconfig snmpd on
Then we check NET-SNMP
| 1 |
snmpwalk -v 3 -u vpsaa.com -a MD5 -A "123456" -l authNoPriv 127.0.0.1 sysDescr |
If everything is fine, you will see some information in the output.
Finally, since the VPS server here has iptables turned on, you need to add the monitoring IP address of Monitorbao SNMP to the rules:
iptables -I INPUT -p udp -s 60.195.252.107 –dport 161 -j ACCEPT
iptables -I INPUT -p udp -s 60.195.252.110 –dport 161 -j ACCEPT
Okay, after completing the above work, we log in to our Monitoring Bao account (if not, please register yourself, address: www.jiankongbao.com)
![]()
As shown above, in Select "Monitoring" in the account - "Server Performance Monitoring ", then click "Add Server" on the right, fill in the necessary information in the picture below, and finally add it.
![]()
![]()
After completion, you can directly click "Add Monitoring Project" on the next page
![]()
Finally, the server monitoring is added. What needs to be noted here is that if you use it to monitor VPS based on the OpenVZ architecture, the last disk IO will prompt "Your server does not support For this monitoring project, please add diskio module for Snmp Agent". OpenVZ users please cancel this option.
Well, the simple application of using SNMP+Monitoring to monitor server performance is the above process. You can use it to monitor your own server or VPS.