-
Notifications
You must be signed in to change notification settings - Fork 2
/
Copy pathINSTALL
52 lines (38 loc) · 1.54 KB
/
INSTALL
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
Tested on:
Mac OS X, RedHat , Debian, FreeBSD ( required to run snmp as root )
Prerequisites:
net-snmp server
net-snmp-perl modules
in the order the included sample to work you also need /usr/sbin/ntpdate utility.
Installation:
Standard to GNU.
aclocal
automake --add-missing
autoconf
configure --prefix=/usr --sysconfdir=/etc # if you choose another directories, you have to amend path appropriately below
make install DESTDIR=<target directory>
3. run subagent-shell:
way 1:
add th line to snmpd.conf:
perl do "/etc/snmp/subagent/subagent-shell";
way 2(recommended):
copy subagent-shell.init to /etc/init.d/subagent-shell (Sys V scripts directory)
copy subagent-shell to /usr/bin
start subagent-shell:
/etc/init.d/subagent-shell start
4. optional. read and amend subagent-shell-functions-conf.xml
5. restart snmpd server
Verification:
snmpwalk -v2c -M+/etc/snmp/subagent/mibs -mALL -c public localhost SUBAGENT-SHELL | head -9
SUBAGENT-SHELL-MIB::ssFunctionsCount = INTEGER: 6
SUBAGENT-SHELL-MIB::ssFunctionsSuccessCount = INTEGER: 6
SUBAGENT-SHELL-MIB::ssFunctionsFailedCount = INTEGER: 0
SUBAGENT-SHELL-MIB::ssTimeStamp = STRING: "09-Sep-2013 17:38:59 (1378733939)"
SUBAGENT-SHELL-MIB::ssTotalExecTime = STRING: "0.365"
SUBAGENT-SHELL-NTP-SYNCSTATUS-MIB::ntpSyncStatus = STRING: "-0.001"
SUBAGENT-SHELL-NTP-SYNCSTATUS-MIB::ntpSyncServer = STRING: "ntp"
SUBAGENT-SHELL-NTP-SYNCSTATUS-MIB::ntpSyncFuncExecTime = STRING: "0.321"
SUBAGENT-SHELL-NTP-SYNCSTATUS-MIB::ntpSyncExecStatus = INTEGER: 0
Troubleshuting:
Check system log for errors
Read the source :)