- 论坛徽章:
- 0
|
apt-get install nagios 方式。
在命令行运行正常,在web页面是出错的。
谁能告诉我吧,指点我问题在哪里吗?或者可能是什么?
显示请看图片
我在命令行运行:
host:/etc/nagios-plugins/config# /usr/lib/nagios/plugins/check_nt -H 192.168.2.107 -p 12489 -s 123456 -v SERVICESTATE -d SHOWALL -l W3SVC
W3SVC: Started
host:/etc/nagios-plugins/config# /usr/lib/nagios/plugins/check_nt -H 192.168.2.107 -p 12489 -s 123456 -v PROCSTATE -d SHOWALL -l Explorer.exe
Explorer.EXE: Running
host:/etc/nagios-plugins/config# /usr/lib/nagios/plugins/check_nt -H 192.168.2.107 -p 12489 -s 123456 -v USEDDISKSPACE -l c -w 80 -c 90
c:\ - total: 58.60 Gb - used: 20.32 Gb (35%) - free 38.28 Gb (65%) | 'c:\ Used Space'=20.32Gb;46.88;52.74;0.00;58.60
配置文件:
define host{
use windows-server ; Inherit default values from a template
host_name 107 ; The name we're giving to this host
alias 107Server ; A longer name associated with the host
address 192.168.2.107 ; IP address of the host
}
# Create a service for monitoring the version of NSCLient++ that is installed
# Change the host_name to match the name of the host you defined above
define service{
use generic-service
host_name 107
service_description NSClient++ Version
check_command check_nt!CLIENTVERSION
}
# Create a service for monitoring the uptime of the server
# Change the host_name to match the name of the host you defined above
define service{
use generic-service
host_name 107
service_description Uptime
check_command check_nt!UPTIME
}
# Create a service for monitoring CPU load
# Change the host_name to match the name of the host you defined above
define service{
use generic-service
host_name 107
service_description CPU Load
check_command check_nt!CPULOAD!-l 5,80,90
}
# Create a service for monitoring
# Change the host_name to match the name of the host you defined above
define service{
use generic-service
host_name 107
service_description Memory Usage
check_command check_nt!MEMUSE!-w 80 -c 90
}
# Create a service for monitoring C:\ disk usage
# Change the host_name to match the name of the host you defined above
define service{
use generic-service
host_name 107
service_description C:\ Drive Space
check_command check_nt!USEDDISKSPACE!-l c -w 80 -c 90
}
# Create a service for monitoring the W3SVC service
# Change the host_name to match the name of the host you defined above
define service{
use generic-service
host_name 107
service_description W3SVC
check_command check_nt!SERVICESTATE!-d SHOWALL -l W3SVC
}
# Create a service for monitoring the Explorer.exe process
# Change the host_name to match the name of the host you defined above
define service{
use generic-service
host_name 107
service_description Explorer
check_command check_nt!PROCSTATE!-d SHOWALL -l Explorer.exe
} |
|