nagiosの立ち上げ〜その2〜

Nagiosの起動

yumでのインストールを間違って覚えてるのかもしれない。 nagiosプラグインフォルダが空だったので、

[root@linux38 httpd]# cd /usr/lib/nagios/plugins/
[root@linux38 plugins]# ls -la
合計 0
drwxr-xr-x 3 nagios nagios 26 10月 24 09:58 .
drwxr-xr-x 4 nagios nagios 34 10月 24 09:58 ..
drwxr-xr-x 2 nagios nagios  6  8月  3 13:33 eventhandlers
[root@linux38 plugins]# pwd
/usr/lib/nagios/plugins

もう一度yumを使ってインストールしてみた。すると、プラグインフォルダにたくさんのファイルがインストールされた。

インストールログ

yumの正しい使い方をわかってないようだ。

[root@linux38 plugins]# yum -y install nagios*
Loading "installonlyn" plugin
Setting up Install Process
Setting up repositories
core [1/3]
http://redhat.secsup.org/fedora/core/5/i386/os/repodata/repomd.xml: [Errno 12] Timeout:
Trying other mirror.
core 100% |=========================| 1.1 kB 00:00
updates [2/3]
updates 100% |=========================| 1.2 kB 00:00
extras [3/3]
extras 100% |=========================| 1.1 kB 00:00
Reading repository metadata in from local files
ls
Parsing package install arguments
Resolving Dependencies
--> Populating transaction set with selected packages. Please wait.
---> Downloading header for nagios-plugins-mrtg to pack into transaction set.
nagios-plugins-mrtg-1.4.3 100% |=========================| 5.1 kB 00:00
---> Package nagios-plugins-mrtg.i386 0:1.4.3-20.fc5 set to be updated
---> Downloading header for nagios-plugins-nagios to pack into transaction set.
nagios-plugins-nagios-1.4 100% |=========================| 5.2 kB 00:00
---> Package nagios-plugins-nagios.i386 0:1.4.3-20.fc5 set to be updated
---> Downloading header for nagios-plugins-udp to pack into transaction set.
nagios-plugins-udp-1.4.3- 100% |=========================| 5.2 kB 00:00
---> Package nagios-plugins-udp.i386 0:1.4.3-20.fc5 set to be updated
---> Downloading header for nagios-plugins-mysql to pack into transaction set.
nagios-plugins-mysql-1.4. 100% |=========================| 5.5 kB 00:00
---> Package nagios-plugins-mysql.i386 0:1.4.3-20.fc5 set to be updated
---> Downloading header for nagios-plugins-by_ssh to pack into transaction set.
nagios-plugins-by_ssh-1.4 100% |=========================| 5.2 kB 00:00
---> Package nagios-plugins-by_ssh.i386 0:1.4.3-20.fc5 set to be updated
---> Downloading header for nagios-plugins-ping to pack into transaction set.
nagios-plugins-ping-1.4.3 100% |=========================| 5.2 kB 00:00
---> Package nagios-plugins-ping.i386 0:1.4.3-20.fc5 set to be updated
---> Downloading header for nagios-plugins-all to pack into transaction set.
nagios-plugins-all-1.4.3- 100% |=========================| 5.4 kB 00:00
---> Package nagios-plugins-all.i386 0:1.4.3-20.fc5 set to be updated
---> Downloading header for nagios-plugins-hpjd to pack into transaction set.
nagios-plugins-hpjd-1.4.3 100% |=========================| 5.2 kB 00:00
---> Package nagios-plugins-hpjd.i386 0:1.4.3-20.fc5 set to be updated
---> Downloading header for nagios-plugins-smtp to pack into transaction set.
nagios-plugins-smtp-1.4.3 100% |=========================| 5.2 kB 00:00
---> Package nagios-plugins-smtp.i386 0:1.4.3-20.fc5 set to be updated
---> Downloading header for nagios-plugins-rpc to pack into transaction set.
nagios-plugins-rpc-1.4.3- 100% |=========================| 5.0 kB 00:00
---> Package nagios-plugins-rpc.i386 0:1.4.3-20.fc5 set to be updated
---> Downloading header for nagios-plugins-nwstat to pack into transaction set.
nagios-plugins-nwstat-1.4 100% |=========================| 5.2 kB 00:00
---> Package nagios-plugins-nwstat.i386 0:1.4.3-20.fc5 set to be updated
---> Downloading header for nagios-plugins-perl to pack into transaction set.
nagios-plugins-perl-1.4.3 100% |=========================| 4.9 kB 00:00
---> Package nagios-plugins-perl.i386 0:1.4.3-20.fc5 set to be updated
---> Downloading header for nagios-plugins-tcp to pack into transaction set.
nagios-plugins-tcp-1.4.3- 100% |=========================| 6.5 kB 00:00
---> Package nagios-plugins-tcp.i386 0:1.4.3-20.fc5 set to be updated
---> Downloading header for nagios-plugins-disk to pack into transaction set.
nagios-plugins-disk-1.4.3 100% |=========================| 5.2 kB 00:00
---> Package nagios-plugins-disk.i386 0:1.4.3-20.fc5 set to be updated
---> Downloading header for nagios-plugins-mrtgtraf to pack into transaction set.
nagios-plugins-mrtgtraf-1 100% |=========================| 5.1 kB 00:00
---> Package nagios-plugins-mrtgtraf.i386 0:1.4.3-20.fc5 set to be updated
---> Downloading header for nagios-plugins-ircd to pack into transaction set.
nagios-plugins-ircd-1.4.3 100% |=========================| 5.0 kB 00:00
---> Package nagios-plugins-ircd.i386 0:1.4.3-20.fc5 set to be updated
---> Downloading header for nagios-plugins-load to pack into transaction set.
nagios-plugins-load-1.4.3 100% |=========================| 5.2 kB 00:00
---> Package nagios-plugins-load.i386 0:1.4.3-20.fc5 set to be updated
---> Downloading header for nagios-plugins-ldap to pack into transaction set.
nagios-plugins-ldap-1.4.3 100% |=========================| 5.3 kB 00:00
---> Package nagios-plugins-ldap.i386 0:1.4.3-20.fc5 set to be updated
---> Downloading header for nagios-plugins-game to pack into transaction set.
nagios-plugins-game-1.4.3 100% |=========================| 5.1 kB 00:00
---> Package nagios-plugins-game.i386 0:1.4.3-20.fc5 set to be updated
---> Downloading header for nagios-plugins-mailq to pack into transaction set.
nagios-plugins-mailq-1.4. 100% |=========================| 5.0 kB 00:00
---> Package nagios-plugins-mailq.i386 0:1.4.3-20.fc5 set to be updated
---> Downloading header for nagios-plugins-fping to pack into transaction set.
nagios-plugins-fping-1.4. 100% |=========================| 5.2 kB 00:00
---> Package nagios-plugins-fping.i386 0:1.4.3-20.fc5 set to be updated
---> Downloading header for nagios-plugins-ntp to pack into transaction set.
nagios-plugins-ntp-1.4.3- 100% |=========================| 5.1 kB 00:00
---> Package nagios-plugins-ntp.i386 0:1.4.3-20.fc5 set to be updated
---> Downloading header for nagios-plugins-procs to pack into transaction set.
nagios-plugins-procs-1.4. 100% |=========================| 5.2 kB 00:00
---> Package nagios-plugins-procs.i386 0:1.4.3-20.fc5 set to be updated
---> Downloading header for nagios-plugins-dhcp to pack into transaction set.
nagios-plugins-dhcp-1.4.3 100% |=========================| 5.2 kB 00:00
---> Package nagios-plugins-dhcp.i386 0:1.4.3-20.fc5 set to be updated
---> Downloading header for nagios-plugins-log to pack into transaction set.
nagios-plugins-log-1.4.3- 100% |=========================| 4.9 kB 00:00
---> Package nagios-plugins-log.i386 0:1.4.3-20.fc5 set to be updated
---> Downloading header for nagios-plugins-ifoperstatus to pack into transaction set.
nagios-plugins-ifoperstat 100% |=========================| 5.1 kB 00:00
---> Package nagios-plugins-ifoperstatus.i386 0:1.4.3-20.fc5 set to be updated
---> Downloading header for nagios-plugins-radius to pack into transaction set.
nagios-plugins-radius-1.4 100% |=========================| 5.2 kB 00:00
---> Package nagios-plugins-radius.i386 0:1.4.3-20.fc5 set to be updated
---> Downloading header for nagios-plugins-breeze to pack into transaction set.
nagios-plugins-breeze-1.4 100% |=========================| 5.0 kB 00:00
---> Package nagios-plugins-breeze.i386 0:1.4.3-20.fc5 set to be updated
---> Downloading header for nagios-plugins-dns to pack into transaction set.
nagios-plugins-dns-1.4.3- 100% |=========================| 5.2 kB 00:00
---> Package nagios-plugins-dns.i386 0:1.4.3-20.fc5 set to be updated
---> Downloading header for nagios-plugins-overcr to pack into transaction set.
nagios-plugins-overcr-1.4 100% |=========================| 5.2 kB 00:00
---> Package nagios-plugins-overcr.i386 0:1.4.3-20.fc5 set to be updated
---> Downloading header for nagios-plugins-pgsql to pack into transaction set.
nagios-plugins-pgsql-1.4. 100% |=========================| 5.2 kB 00:00
---> Package nagios-plugins-pgsql.i386 0:1.4.3-20.fc5 set to be updated
---> Downloading header for nagios-plugins-sensors to pack into transaction set.
nagios-plugins-sensors-1. 100% |=========================| 4.9 kB 00:00
---> Package nagios-plugins-sensors.i386 0:1.4.3-20.fc5 set to be updated
---> Downloading header for nagios-plugins-http to pack into transaction set.
nagios-plugins-http-1.4.3 100% |=========================| 5.2 kB 00:00
---> Package nagios-plugins-http.i386 0:1.4.3-20.fc5 set to be updated
---> Downloading header for nagios-plugins-real to pack into transaction set.
nagios-plugins-real-1.4.3 100% |=========================| 5.2 kB 00:00
---> Package nagios-plugins-real.i386 0:1.4.3-20.fc5 set to be updated
---> Downloading header for nagios-plugins-dig to pack into transaction set.
nagios-plugins-dig-1.4.3- 100% |=========================| 5.2 kB 00:00
---> Package nagios-plugins-dig.i386 0:1.4.3-20.fc5 set to be updated
---> Downloading header for nagios-devel to pack into transaction set.
nagios-devel-2.5-2.fc5.i3 100% |=========================| 7.0 kB 00:00
---> Package nagios-devel.i386 0:2.5-2.fc5 set to be updated
---> Downloading header for nagios-plugins-ups to pack into transaction set.
nagios-plugins-ups-1.4.3- 100% |=========================| 5.2 kB 00:00
---> Package nagios-plugins-ups.i386 0:1.4.3-20.fc5 set to be updated
---> Downloading header for nagios-plugins-nt to pack into transaction set.
nagios-plugins-nt-1.4.3-2 100% |=========================| 5.2 kB 00:00
---> Package nagios-plugins-nt.i386 0:1.4.3-20.fc5 set to be updated
---> Downloading header for nagios-plugins-time to pack into transaction set.
nagios-plugins-time-1.4.3 100% |=========================| 5.2 kB 00:00
---> Package nagios-plugins-time.i386 0:1.4.3-20.fc5 set to be updated
---> Downloading header for nagios-plugins-swap to pack into transaction set.
nagios-plugins-swap-1.4.3 100% |=========================| 5.2 kB 00:00
---> Package nagios-plugins-swap.i386 0:1.4.3-20.fc5 set to be updated
---> Downloading header for nagios-plugins-snmp to pack into transaction set.
nagios-plugins-snmp-1.4.3 100% |=========================| 5.2 kB 00:00
---> Package nagios-plugins-snmp.i386 0:1.4.3-20.fc5 set to be updated
---> Downloading header for nagios-plugins-dummy to pack into transaction set.
nagios-plugins-dummy-1.4. 100% |=========================| 5.2 kB 00:00
---> Package nagios-plugins-dummy.i386 0:1.4.3-20.fc5 set to be updated
---> Downloading header for nagios-plugins-flexlm to pack into transaction set.
nagios-plugins-flexlm-1.4 100% |=========================| 5.0 kB 00:00
---> Package nagios-plugins-flexlm.i386 0:1.4.3-20.fc5 set to be updated
---> Downloading header for nagios-plugins to pack into transaction set.
nagios-plugins-1.4.3-20.f 100% |=========================| 7.5 kB 00:00
---> Package nagios-plugins.i386 0:1.4.3-20.fc5 set to be updated
---> Downloading header for nagios-plugins-wave to pack into transaction set.
nagios-plugins-wave-1.4.3 100% |=========================| 5.0 kB 00:00
---> Package nagios-plugins-wave.i386 0:1.4.3-20.fc5 set to be updated
---> Downloading header for nagios-plugins-icmp to pack into transaction set.
nagios-plugins-icmp-1.4.3 100% |=========================| 5.2 kB 00:00
---> Package nagios-plugins-icmp.i386 0:1.4.3-20.fc5 set to be updated
---> Downloading header for nagios-plugins-users to pack into transaction set.
nagios-plugins-users-1.4. 100% |=========================| 5.2 kB 00:00
---> Package nagios-plugins-users.i386 0:1.4.3-20.fc5 set to be updated
---> Downloading header for nagios-plugins-ide_smart to pack into transaction set.
nagios-plugins-ide_smart- 100% |=========================| 5.1 kB 00:00
---> Package nagios-plugins-ide_smart.i386 0:1.4.3-20.fc5 set to be updated
---> Downloading header for nagios-plugins-file_age to pack into transaction set.
nagios-plugins-file_age-1 100% |=========================| 5.1 kB 00:00
---> Package nagios-plugins-file_age.i386 0:1.4.3-20.fc5 set to be updated
---> Downloading header for nagios-plugins-ssh to pack into transaction set.
nagios-plugins-ssh-1.4.3- 100% |=========================| 5.2 kB 00:00
---> Package nagios-plugins-ssh.i386 0:1.4.3-20.fc5 set to be updated
---> Downloading header for nagios-plugins-oracle to pack into transaction set.
nagios-plugins-oracle-1.4 100% |=========================| 4.9 kB 00:00
---> Package nagios-plugins-oracle.i386 0:1.4.3-20.fc5 set to be updated
---> Downloading header for nagios-plugins-ifstatus to pack into transaction set.
nagios-plugins-ifstatus-1 100% |=========================| 5.1 kB 00:00
---> Package nagios-plugins-ifstatus.i386 0:1.4.3-20.fc5 set to be updated
---> Downloading header for nagios-plugins-snmp-disk-proc to pack into transaction set.
nagios-plugins-snmp-disk- 100% |=========================| 3.0 kB 00:00
---> Package nagios-plugins-snmp-disk-proc.i386 0:1.0-1.fc5 set to be updated
---> Downloading header for nagios-plugins-disk_smb to pack into transaction set.
nagios-plugins-disk_smb-1 100% |=========================| 5.1 kB 00:00
---> Package nagios-plugins-disk_smb.i386 0:1.4.3-20.fc5 set to be updated
--> Running transaction check
--> Processing Dependency: perl(Net::SNMP) for package: nagios-plugins-ifstatus
--> Processing Dependency: qstat for package: nagios-plugins-game
--> Processing Dependency: perl(Net::SNMP) for package: nagios-plugins-ifoperstatus
--> Processing Dependency: libradiusclient-ng.so.2 for package: nagios-plugins-radius
--> Processing Dependency: /usr/sbin/fping for package: nagios-plugins-fping
--> Restarting Dependency Resolution with new changes.
--> Populating transaction set with selected packages. Please wait.
---> Downloading header for perl-Net-SNMP to pack into transaction set.
perl-Net-SNMP-5.2.0-1.fc5 100% |=========================| 7.2 kB 00:00
---> Package perl-Net-SNMP.noarch 0:5.2.0-1.fc5 set to be updated
---> Downloading header for qstat to pack into transaction set.
qstat-2.10-5.fc5.i386.rpm 100% |=========================| 6.1 kB 00:00
---> Package qstat.i386 0:2.10-5.fc5 set to be updated
---> Downloading header for fping to pack into transaction set.
fping-2.4b2-6.fc5.i386.rp 100% |=========================| 3.6 kB 00:00
---> Package fping.i386 0:2.4b2-6.fc5 set to be updated
---> Downloading header for radiusclient-ng to pack into transaction set.
radiusclient-ng-0.5.2-3.f 100% |=========================| 4.7 kB 00:00
---> Package radiusclient-ng.i386 0:0.5.2-3.fc5 set to be updated
--> Running transaction check
--> Processing Dependency: perl(Crypt::DES) for package: perl-Net-SNMP
--> Restarting Dependency Resolution with new changes.
--> Populating transaction set with selected packages. Please wait.
---> Downloading header for perl-Crypt-DES to pack into transaction set.
perl-Crypt-DES-2.05-2.fc5 100% |=========================| 3.5 kB 00:00
---> Package perl-Crypt-DES.i386 0:2.05-2.fc5 set to be updated
--> Running transaction check

Dependencies Resolved

=============================================================================
Package Arch Version Repository Size
=============================================================================
Installing:
nagios-devel i386 2.5-2.fc5 extras 8.3 k
nagios-plugins i386 1.4.3-20.fc5 extras 141 k
nagios-plugins-all i386 1.4.3-20.fc5 extras 5.9 k
nagios-plugins-breeze i386 1.4.3-20.fc5 extras 6.5 k
nagios-plugins-by_ssh i386 1.4.3-20.fc5 extras 20 k
nagios-plugins-dhcp i386 1.4.3-20.fc5 extras 19 k
nagios-plugins-dig i386 1.4.3-20.fc5 extras 19 k
nagios-plugins-disk i386 1.4.3-20.fc5 extras 23 k
nagios-plugins-disk_smb i386 1.4.3-20.fc5 extras 8.6 k
nagios-plugins-dns i386 1.4.3-20.fc5 extras 20 k
nagios-plugins-dummy i386 1.4.3-20.fc5 extras 13 k
nagios-plugins-file_age i386 1.4.3-20.fc5 extras 7.0 k
nagios-plugins-flexlm i386 1.4.3-20.fc5 extras 8.0 k
nagios-plugins-fping i386 1.4.3-20.fc5 extras 20 k
nagios-plugins-game i386 1.4.3-20.fc5 extras 17 k
nagios-plugins-hpjd i386 1.4.3-20.fc5 extras 18 k
nagios-plugins-http i386 1.4.3-20.fc5 extras 28 k
nagios-plugins-icmp i386 1.4.3-20.fc5 extras 16 k
nagios-plugins-ide_smart i386 1.4.3-20.fc5 extras 15 k
nagios-plugins-ifoperstatus i386 1.4.3-20.fc5 extras 10 k
nagios-plugins-ifstatus i386 1.4.3-20.fc5 extras 9.7 k
nagios-plugins-ircd i386 1.4.3-20.fc5 extras 8.3 k
nagios-plugins-ldap i386 1.4.3-20.fc5 extras 17 k
nagios-plugins-load i386 1.4.3-20.fc5 extras 16 k
nagios-plugins-log i386 1.4.3-20.fc5 extras 7.6 k
nagios-plugins-mailq i386 1.4.3-20.fc5 extras 10 k
nagios-plugins-mrtg i386 1.4.3-20.fc5 extras 15 k
nagios-plugins-mrtgtraf i386 1.4.3-20.fc5 extras 15 k
nagios-plugins-mysql i386 1.4.3-20.fc5 extras 22 k
nagios-plugins-nagios i386 1.4.3-20.fc5 extras 17 k
nagios-plugins-nt i386 1.4.3-20.fc5 extras 19 k
nagios-plugins-ntp i386 1.4.3-20.fc5 extras 10 k
nagios-plugins-nwstat i386 1.4.3-20.fc5 extras 21 k
nagios-plugins-oracle i386 1.4.3-20.fc5 extras 8.1 k
nagios-plugins-overcr i386 1.4.3-20.fc5 extras 17 k
nagios-plugins-perl i386 1.4.3-20.fc5 extras 6.7 k
nagios-plugins-pgsql i386 1.4.3-20.fc5 extras 17 k
nagios-plugins-ping i386 1.4.3-20.fc5 extras 21 k
nagios-plugins-procs i386 1.4.3-20.fc5 extras 20 k
nagios-plugins-radius i386 1.4.3-20.fc5 extras 16 k
nagios-plugins-real i386 1.4.3-20.fc5 extras 17 k
nagios-plugins-rpc i386 1.4.3-20.fc5 extras 8.9 k
nagios-plugins-sensors i386 1.4.3-20.fc5 extras 6.0 k
nagios-plugins-smtp i386 1.4.3-20.fc5 extras 21 k
nagios-plugins-snmp i386 1.4.3-20.fc5 extras 23 k
nagios-plugins-snmp-disk-proc i386 1.0-1.fc5 extras 18 k
nagios-plugins-ssh i386 1.4.3-20.fc5 extras 16 k
nagios-plugins-swap i386 1.4.3-20.fc5 extras 17 k
nagios-plugins-tcp i386 1.4.3-20.fc5 extras 22 k
nagios-plugins-time i386 1.4.3-20.fc5 extras 16 k
nagios-plugins-udp i386 1.4.3-20.fc5 extras 17 k
nagios-plugins-ups i386 1.4.3-20.fc5 extras 19 k
nagios-plugins-users i386 1.4.3-20.fc5 extras 16 k
nagios-plugins-wave i386 1.4.3-20.fc5 extras 6.6 k
Installing for dependencies:
fping i386 2.4b2-6.fc5 extras 31 k
perl-Crypt-DES i386 2.05-2.fc5 extras 17 k
perl-Net-SNMP noarch 5.2.0-1.fc5 extras 108 k
qstat i386 2.10-5.fc5 extras 152 k
radiusclient-ng i386 0.5.2-3.fc5 extras 43 k

Transaction Summary
=============================================================================
Install 59 Package(s)
Update 0 Package(s)
Remove 0 Package(s)
Total download size: 1.3 M
Downloading Packages:
(1/59): nagios-plugins-mr 100% |=========================| 15 kB 00:00
(2/59): nagios-plugins-na 100% |=========================| 17 kB 00:00
(3/59): nagios-plugins-ud 100% |=========================| 17 kB 00:00
(4/59): nagios-plugins-my 100% |=========================| 22 kB 00:00
(5/59): nagios-plugins-by 100% |=========================| 20 kB 00:00
(6/59): nagios-plugins-pi 100% |=========================| 21 kB 00:00
(7/59): nagios-plugins-al 100% |=========================| 5.9 kB 00:00
(8/59): nagios-plugins-hp 100% |=========================| 18 kB 00:00
(9/59): nagios-plugins-sm 100% |=========================| 21 kB 00:00
(10/59): nagios-plugins-r 100% |=========================| 8.9 kB 00:00
(11/59): nagios-plugins-n 100% |=========================| 21 kB 00:00
(12/59): nagios-plugins-p 100% |=========================| 6.7 kB 00:00
(13/59): nagios-plugins-t 100% |=========================| 22 kB 00:00
(14/59): nagios-plugins-d 100% |=========================| 23 kB 00:00
(15/59): nagios-plugins-m 100% |=========================| 15 kB 00:00
(16/59): nagios-plugins-i 100% |=========================| 8.3 kB 00:00
(17/59): nagios-plugins-l 100% |=========================| 16 kB 00:00
(18/59): nagios-plugins-l 100% |=========================| 17 kB 00:00
(19/59): nagios-plugins-g 100% |=========================| 17 kB 00:00
(20/59): perl-Net-SNMP-5. 100% |=========================| 108 kB 00:03
(21/59): nagios-plugins-m 100% |=========================| 10 kB 00:00
(22/59): nagios-plugins-f 100% |=========================| 20 kB 00:00
(23/59): nagios-plugins-n 100% |=========================| 10 kB 00:00
(24/59): nagios-plugins-p 100% |=========================| 20 kB 00:00
(25/59): nagios-plugins-d 100% |=========================| 19 kB 00:00
(26/59): qstat-2.10-5.fc5 100% |=========================| 152 kB 00:04
(27/59): nagios-plugins-l 100% |=========================| 7.6 kB 00:00
(28/59): nagios-plugins-i 100% |=========================| 10 kB 00:00
(29/59): nagios-plugins-r 100% |=========================| 16 kB 00:00
(30/59): nagios-plugins-b 100% |=========================| 6.5 kB 00:00
(31/59): nagios-plugins-d 100% |=========================| 20 kB 00:00
(32/59): perl-Crypt-DES-2 100% |=========================| 17 kB 00:00
(33/59): nagios-plugins-o 100% |=========================| 17 kB 00:00
(34/59): nagios-plugins-p 100% |=========================| 17 kB 00:00
(35/59): nagios-plugins-s 100% |=========================| 6.0 kB 00:00
(36/59): nagios-plugins-h 100% |=========================| 28 kB 00:00
(37/59): nagios-plugins-r 100% |=========================| 17 kB 00:00
(38/59): nagios-plugins-d 100% |=========================| 19 kB 00:00
(39/59): nagios-devel-2.5 100% |=========================| 8.3 kB 00:00
(40/59): nagios-plugins-u 100% |=========================| 19 kB 00:00
(41/59): nagios-plugins-n 100% |=========================| 19 kB 00:00
(42/59): nagios-plugins-t 100% |=========================| 16 kB 00:00
(43/59): fping-2.4b2-6.fc 100% |=========================| 31 kB 00:00
(44/59): nagios-plugins-s 100% |=========================| 17 kB 00:00
(45/59): nagios-plugins-s 100% |=========================| 23 kB 00:00
(46/59): nagios-plugins-d 100% |=========================| 13 kB 00:00
(47/59): nagios-plugins-f 100% |=========================| 8.0 kB 00:00
(48/59): radiusclient-ng- 100% |=========================| 43 kB 00:00
(49/59): nagios-plugins-1 100% |=========================| 141 kB 00:03
(50/59): nagios-plugins-w 100% |=========================| 6.6 kB 00:00
(51/59): nagios-plugins-i 100% |=========================| 16 kB 00:00
(52/59): nagios-plugins-u 100% |=========================| 16 kB 00:00
(53/59): nagios-plugins-i 100% |=========================| 15 kB 00:00
(54/59): nagios-plugins-f 100% |=========================| 7.0 kB 00:00
(55/59): nagios-plugins-s 100% |=========================| 16 kB 00:00
(56/59): nagios-plugins-o 100% |=========================| 8.1 kB 00:00
(57/59): nagios-plugins-i 100% |=========================| 9.7 kB 00:00
(58/59): nagios-plugins-s 100% |=========================| 18 kB 00:00
(59/59): nagios-plugins-d 100% |=========================| 8.6 kB 00:00
Running Transaction Test
Finished Transaction Test
Transaction Test Succeeded
Running Transaction
Installing: nagios-plugins ####################### [ 1/59]
Installing: nagios-plugins-perl ####################### [ 2/59]
Installing: nagios-plugins-rpc ####################### [ 3/59]
Installing: nagios-plugins-ircd ####################### [ 4/59]
Installing: nagios-plugins-mailq ####################### [ 5/59]
Installing: nagios-plugins-ntp ####################### [ 6/59]
Installing: nagios-plugins-breeze ####################### [ 7/59]
Installing: nagios-plugins-flexlm ####################### [ 8/59]
Installing: nagios-plugins-wave ####################### [ 9/59]
Installing: nagios-plugins-file_age ####################### [10/59]
Installing: nagios-plugins-disk_smb ####################### [11/59]
Installing: nagios-plugins-mrtg ####################### [12/59]
Installing: nagios-plugins-nagios ####################### [13/59]
Installing: nagios-plugins-udp ####################### [14/59]
Installing: nagios-plugins-mysql ####################### [15/59]
Installing: nagios-plugins-by_ssh ####################### [16/59]
Installing: nagios-plugins-ping ####################### [17/59]
Installing: nagios-plugins-hpjd ####################### [18/59]
Installing: nagios-plugins-smtp ####################### [19/59]
Installing: nagios-plugins-nwstat ####################### [20/59]
Installing: nagios-plugins-tcp ####################### [21/59]
Installing: nagios-plugins-disk ####################### [22/59]
Installing: nagios-plugins-mrtgtraf ####################### [23/59]
Installing: nagios-plugins-load ####################### [24/59]
Installing: nagios-plugins-ldap ####################### [25/59]
Installing: nagios-plugins-procs ####################### [26/59]
Installing: nagios-plugins-dhcp ####################### [27/59]
Installing: nagios-plugins-log ####################### [28/59]
Installing: nagios-plugins-dns ####################### [29/59]
Installing: nagios-plugins-overcr ####################### [30/59]
Installing: nagios-plugins-pgsql ####################### [31/59]
Installing: nagios-plugins-sensors ####################### [32/59]
Installing: nagios-plugins-http ####################### [33/59]
Installing: nagios-plugins-real ####################### [34/59]
Installing: nagios-plugins-dig ####################### [35/59]
Installing: nagios-plugins-ups ####################### [36/59]
Installing: nagios-plugins-nt ####################### [37/59]
Installing: nagios-plugins-time ####################### [38/59]
Installing: nagios-plugins-swap ####################### [39/59]
Installing: nagios-plugins-snmp ####################### [40/59]
Installing: nagios-plugins-dummy ####################### [41/59]
Installing: nagios-plugins-icmp ####################### [42/59]
Installing: nagios-plugins-users ####################### [43/59]
Installing: nagios-plugins-ssh ####################### [44/59]
Installing: nagios-plugins-oracle ####################### [45/59]
Installing: radiusclient-ng ####################### [46/59]
[root@linux38 plugins]# yum -y install nagios*
Loading "installonlyn" plugin
Setting up Install Process
Setting up repositories
core [1/3]
updates [2/3]
extras [3/3]
Reading repository metadata in from local files
Parsing package install arguments
Resolving Dependencies
--> Populating transaction set with selected packages. Please wait.
---> Package nagios-plugins-game.i386 0:1.4.3-20.fc5 set to be updated
---> Package nagios-plugins-all.i386 0:1.4.3-20.fc5 set to be updated
---> Package nagios-plugins-ide_smart.i386 0:1.4.3-20.fc5 set to be updated
---> Package nagios-plugins-ifoperstatus.i386 0:1.4.3-20.fc5 set to be updated
---> Package nagios-plugins-fping.i386 0:1.4.3-20.fc5 set to be updated
---> Package nagios-devel.i386 0:2.5-2.fc5 set to be updated
---> Package nagios-plugins-ifstatus.i386 0:1.4.3-20.fc5 set to be updated
---> Package nagios-plugins-snmp-disk-proc.i386 0:1.0-1.fc5 set to be updated
---> Package nagios-plugins-radius.i386 0:1.4.3-20.fc5 set to be updated
--> Running transaction check
--> Processing Dependency: perl(Net::SNMP) for package: nagios-plugins-ifstatus
--> Processing Dependency: qstat for package: nagios-plugins-game
--> Processing Dependency: /usr/sbin/fping for package: nagios-plugins-fping
--> Processing Dependency: perl(Net::SNMP) for package: nagios-plugins-ifoperstatus
--> Restarting Dependency Resolution with new changes.
--> Populating transaction set with selected packages. Please wait.
---> Package fping.i386 0:2.4b2-6.fc5 set to be updated
---> Package qstat.i386 0:2.10-5.fc5 set to be updated
---> Package perl-Net-SNMP.noarch 0:5.2.0-1.fc5 set to be updated
--> Running transaction check
--> Processing Dependency: perl(Crypt::DES) for package: perl-Net-SNMP
--> Restarting Dependency Resolution with new changes.
--> Populating transaction set with selected packages. Please wait.
---> Package perl-Crypt-DES.i386 0:2.05-2.fc5 set to be updated
--> Running transaction check

Dependencies Resolved

=============================================================================
Package Arch Version Repository Size
=============================================================================
Installing:
nagios-devel i386 2.5-2.fc5 extras 8.3 k
nagios-plugins-all i386 1.4.3-20.fc5 extras 5.9 k
nagios-plugins-fping i386 1.4.3-20.fc5 extras 20 k
nagios-plugins-game i386 1.4.3-20.fc5 extras 17 k
nagios-plugins-ide_smart i386 1.4.3-20.fc5 extras 15 k
nagios-plugins-ifoperstatus i386 1.4.3-20.fc5 extras 10 k
nagios-plugins-ifstatus i386 1.4.3-20.fc5 extras 9.7 k
nagios-plugins-radius i386 1.4.3-20.fc5 extras 16 k
nagios-plugins-snmp-disk-proc i386 1.0-1.fc5 extras 18 k
Installing for dependencies:
fping i386 2.4b2-6.fc5 extras 31 k
perl-Crypt-DES i386 2.05-2.fc5 extras 17 k
perl-Net-SNMP noarch 5.2.0-1.fc5 extras 108 k
qstat i386 2.10-5.fc5 extras 152 k

Transaction Summary
=============================================================================
Install 13 Package(s)
Update 0 Package(s)
Remove 0 Package(s)
Total download size: 429 k
Downloading Packages:
Running Transaction Test
Finished Transaction Test
Transaction Test Succeeded
Running Transaction
Installing: perl-Crypt-DES ####################### [ 1/13]
Installing: perl-Net-SNMP ####################### [ 2/13]
Installing: qstat ####################### [ 3/13]
Installing: nagios-plugins-game ####################### [ 4/13]
Installing: fping ####################### [ 5/13]
Installing: nagios-plugins-fping ####################### [ 6/13]
Installing: nagios-plugins-all ####################### [ 7/13]
Installing: nagios-plugins-ide_smart ####################### [ 8/13]
Installing: nagios-plugins-ifoperstatus ####################### [ 9/13]
Installing: nagios-devel ####################### [10/13]
Installing: nagios-plugins-ifstatus ####################### [11/13]
Installing: nagios-plugins-snmp-disk-pro ####################### [12/13]
Installing: nagios-plugins-radius ####################### [13/13]

Installed: nagios-devel.i386 0:2.5-2.fc5 nagios-plugins-all.i386 0:1.4.3-20.fc5 nagios-plugins-fping.i386 0:1.4.3-20.fc5 nagios-plugins-game.i386 0:1.4.3-20.fc5 nagios-plugins-ide_smart.i386 0:1.4.3-20.fc5 nagios-plugins-ifoperstatus.i386 0:1.4.3-20.fc5 nagios-plugins-ifstatus.i386 0:1.4.3-20.fc5 nagios-plugins-radius.i386 0:1.4.3-20.fc5 nagios-plugins-snmp-disk-proc.i386 0:1.0-1.fc5
Dependency Installed: fping.i386 0:2.4b2-6.fc5 perl-Crypt-DES.i386 0:2.05-2.fc5 perl-Net-SNMP.noarch 0:5.2.0-1.fc5 qstat.i386 0:2.10-5.fc5
Complete!
[root@linux38 plugins]# pwd
/usr/lib/nagios/plugins
[root@linux38 plugins]# pwd
/usr/lib/nagios/plugins
[root@linux38 plugins]# ls
check_breeze check_flexlm check_imap check_mysql check_pgsql check_snmp check_udp2
check_by_ssh check_fping check_ircd check_mysql_query check_ping check_snmp_disk check_ups
check_clamd check_ftp check_jabber check_nagios check_pop check_snmp_proc check_users
check_dhcp check_game check_ldap check_nntp check_procs check_spop check_wave
check_dig check_hpjd check_ldaps check_nntps check_radius check_ssh eventhandlers
check_disk check_http check_load check_nt check_real check_ssmtp negate
check_disk_smb check_icmp check_log check_ntp check_rpc check_swap urlize
check_dns check_ide_smart check_mailq check_nwstat check_sensors check_tcp utils.pm
check_dummy check_ifoperstatus check_mrtg check_oracle check_simap check_time utils.sh
check_file_age check_ifstatus check_mrtgtraf check_overcr check_smtp check_udp
[root@linux38 plugins]# ls -la
合計 1232
drwxr-xr-x 3 root root 4096 10月 24 22:57 .
drwxr-xr-x 4 root root 34 9月 30 02:18 ..
-rwxr-xr-x 1 root root 2271 9月 30 02:18 check_breeze
-rwxr-xr-x 1 root root 28916 9月 30 02:18 check_by_ssh
lrwxrwxrwx 1 root root 9 10月 24 22:56 check_clamd -> check_tcp
-rwsr-x--- 1 root nagios 27540 9月 30 02:18 check_dhcp
-rwxr-xr-x 1 root root 26880 9月 30 02:18 check_dig
-rwxr-xr-x 1 root root 35680 9月 30 02:18 check_disk
-rwxr-xr-x 1 root root 8165 9月 30 02:18 check_disk_smb
-rwxr-xr-x 1 root root 31792 9月 30 02:18 check_dns
-rwxr-xr-x 1 root root 14476 9月 30 02:18 check_dummy
-rwxr-xr-x 1 root root 3230 9月 30 02:18 check_file_age
-rwxr-xr-x 1 root root 6397 9月 30 02:18 check_flexlm
-rwxr-xr-x 1 root root 29156 9月 30 02:18 check_fping
lrwxrwxrwx 1 root root 9 10月 24 22:56 check_ftp -> check_tcp
-rwxr-xr-x 1 root root 22716 9月 30 02:18 check_game
-rwxr-xr-x 1 root root 26948 9月 30 02:18 check_hpjd
-rwxr-xr-x 1 root root 50660 9月 30 02:18 check_http
-rwsr-x--- 1 root root 18796 9月 30 02:18 check_icmp
-rwxr-xr-x 1 root root 19296 9月 30 02:18 check_ide_smart
-rwxr-xr-x 1 root root 15289 9月 30 02:18 check_ifoperstatus
-rwxr-xr-x 1 root root 12855 9月 30 02:18 check_ifstatus
lrwxrwxrwx 1 root root 9 10月 24 22:56 check_imap -> check_tcp
-rwxr-xr-x 1 root root 7434 9月 30 02:18 check_ircd
lrwxrwxrwx 1 root root 9 10月 24 22:56 check_jabber -> check_tcp
-rwxr-xr-x 1 root root 22676 9月 30 02:18 check_ldap
lrwxrwxrwx 1 root root 10 10月 24 22:56 check_ldaps -> check_ldap
-rwxr-xr-x 1 root root 21020 9月 30 02:18 check_load
-rwxr-xr-x 1 root root 6035 9月 30 02:18 check_log
-rwxr-xr-x 1 root root 20746 9月 30 02:18 check_mailq
-rwxr-xr-x 1 root root 20076 9月 30 02:18 check_mrtg
-rwxr-xr-x 1 root root 18800 9月 30 02:18 check_mrtgtraf
-rwxr-xr-x 1 root root 23988 9月 30 02:18 check_mysql
-rwxr-xr-x 1 root root 22616 9月 30 02:18 check_mysql_query
-rwxr-xr-x 1 root root 22460 9月 30 02:18 check_nagios
lrwxrwxrwx 1 root root 9 10月 24 22:56 check_nntp -> check_tcp
lrwxrwxrwx 1 root root 9 10月 24 22:56 check_nntps -> check_tcp
-rwxr-xr-x 1 root root 28512 9月 30 02:18 check_nt
-rwxr-xr-x 1 root root 14380 9月 30 02:18 check_ntp
-rwxr-xr-x 1 root root 36532 9月 30 02:18 check_nwstat
-rwxr-xr-x 1 root root 8293 9月 30 02:18 check_oracle
-rwxr-xr-x 1 root root 24388 9月 30 02:18 check_overcr
-rwxr-xr-x 1 root root 22836 9月 30 02:18 check_pgsql
-rwxr-xr-x 1 root root 32932 9月 30 02:18 check_ping
lrwxrwxrwx 1 root root 9 10月 24 22:56 check_pop -> check_tcp
-rwxr-xr-x 1 root root 31500 9月 30 02:18 check_procs
-rwxr-xr-x 1 root root 22596 9月 30 02:18 check_radius
-rwxr-xr-x 1 root root 23860 9月 30 02:18 check_real
-rwxr-xr-x 1 root root 9709 9月 30 02:18 check_rpc
-rwxr-xr-x 1 root root 1176 9月 30 02:18 check_sensors
lrwxrwxrwx 1 root root 9 10月 24 22:56 check_simap -> check_tcp
-rwxr-xr-x 1 root root 33556 9月 30 02:18 check_smtp
-rwxr-xr-x 1 root root 38316 9月 30 02:18 check_snmp
-rwxr-xr-x 1 root root 10052 10月 10 20:13 check_snmp_disk
-rwxr-xr-x 1 root root 9412 10月 10 20:13 check_snmp_proc
lrwxrwxrwx 1 root root 9 10月 24 22:56 check_spop -> check_tcp
-rwxr-xr-x 1 root root 21328 9月 30 02:18 check_ssh
lrwxrwxrwx 1 root root 9 10月 24 22:56 check_ssmtp -> check_tcp
-rwxr-xr-x 1 root root 23804 9月 30 02:18 check_swap
-rwxr-xr-x 1 root root 31328 9月 30 02:18 check_tcp
-rwxr-xr-x 1 root root 23204 9月 30 02:18 check_time
-rwxr-xr-x 1 root root 24768 9月 30 02:18 check_udp
lrwxrwxrwx 1 root root 9 10月 24 22:56 check_udp2 -> check_tcp
-rwxr-xr-x 1 root root 28704 9月 30 02:18 check_ups
-rwxr-xr-x 1 root root 20988 9月 30 02:18 check_users
-rwxr-xr-x 1 root root 3021 9月 30 02:18 check_wave
drwxr-xr-x 2 nagios nagios 6 8月 3 13:33 eventhandlers
-rwxr-xr-x 1 root root 21064 9月 30 02:18 negate
-rwxr-xr-x 1 root root 20584 9月 30 02:18 urlize
-rw-r--r-- 1 root root 2471 9月 30 02:18 utils.pm
-rwxr-xr-x 1 root root 860 9月 30 02:18 utils.sh
[root@linux38 plugins]# ls
check_breeze check_flexlm check_imap check_mysql check_pgsql check_snmp check_udp2
check_by_ssh check_fping check_ircd check_mysql_query check_ping check_snmp_disk check_ups
check_clamd check_ftp check_jabber check_nagios check_pop check_snmp_proc check_users
check_dhcp check_game check_ldap check_nntp check_procs check_spop check_wave
check_dig check_hpjd check_ldaps check_nntps check_radius check_ssh eventhandlers
check_disk check_http check_load check_nt check_real check_ssmtp negate
check_disk_smb check_icmp check_log check_ntp check_rpc check_swap urlize
check_dns check_ide_smart check_mailq check_nwstat check_sensors check_tcp utils.pm
check_dummy check_ifoperstatus check_mrtg check_oracle check_simap check_time utils.sh
check_file_age check_ifstatus check_mrtgtraf check_overcr check_smtp check_udp
[root@linux38 plugins]# pwd
/usr/lib/nagios/plugins

internalservererrorを直す

現在の未解決エラーはapacheのエラーログ。

[Tue Oct 24 23:19:36 2006] [error] [client 192.168.10.23] (13)Permission denied: exec of '/usr/lib/nagios/cgi-bin/statusmap.cgi' failed, referer: http://192.168.10.38/nagios/side.html
[Tue Oct 24 23:19:36 2006] [error] [client 192.168.10.23] Premature end of script headers: statusmap.cgi, referer: http://192.168.10.38/nagios/side.html

その1

/etc//httpd/conf.d/nagios.conf のベーシック認証のところを全て復活させて、 /etc/nagios/ディレクトリにて

#htpasswd -c passwd nagios

コマンドにて、nagiosユーザ用のベーシック認証用のパスワードファイルを作った。
httpd再起動後、
http://192.168.10.38/nagios/ でベーシック認証が出て、先ほど作ったアカウント、パスワードで無事通過した。だけど、まだ、各動的コンテンツは500エラーのまま。

その2

効果なし
編集前

/etc/httpd/conf/httpd.conf
#ScriptAlias /cgi-bin/ "/var/www/cgi-bin/"

編集後

/etc/httpd/conf/httpd.conf
ScriptAlias /cgi-bin/ "/var/www/cgi-bin/"
SELinuxの話に首を突っ込む

http://pocketstudio.jp/logbook/linux/FedoraCore3/error.html

[root@linux38 targeted]# ls -la --context /usr/lib/nagios/cgi-bin/status.cgi
[root@linux38 targeted]#

Oct 24 23:54:31 linux38 kernel: audit(1161701671.020:92): avc: denied { execute_no_trans } for pid=9165 comm="httpd" name="statusmap.cgi" dev=hda2 ino=1107480 scontext=user_u:system_r:httpd_t:s0 tcontext=system_u:object_r:lib_t:s0 tclass=file

system_u:object_r:lib_tが該当してる。

http://pocketstudio.jp/logbook/linux/FedoraCore3/selinux-docroot.html
ここら辺のファイルも要チェック。

[susa@linux38 files]$ pwd
/etc/selinux/targeted/contexts/files
[susa@linux38 files]$ ls -la
合計 112
drwxr-xr-x 2 root root    90 10月 10 23:53 .
drwxr-xr-x 3 root root  4096 10月 10 23:41 ..
  • rw-r--r-- 1 root root 96507 10月 10 23:53 file_contexts
  • rw-r--r-- 1 root root 896 10月 10 23:53 file_contexts.homedirs
  • rw-r--r-- 1 root root 436 10月 10 23:53 homedir_template
  • rw-r--r-- 1 root root 139 3月 10 2006 media
原因
/var/spool/gosa(/.*)?           system_u:object_r:httpd_sys_script_rw_t:s0
/var/www/cgi-bin(/.*)?          system_u:object_r:httpd_sys_script_exec_t:s0
/usr/lib/cgi-bin(/.*)?          system_u:object_r:httpd_sys_script_exec_t:s0
ino=1107482 
scontext=             user_u:system_r:httpd_t:s0 tcontext=system_u:object_r:lib_t:s0 
[root@linux38 www]# ls -la --context
drwxr-xr-x  apache   apache   system_u:object_r:httpd_sys_content_t .
drwxr-xr-x  root     root     system_u:object_r:var_t          ..
drwxr-xr-x  apache   apache   system_u:object_r:httpd_sys_script_exec_t cgi-bin
drwxr-xr-x  apache   apache   system_u:object_r:httpd_sys_content_t error

/var/www/cgi-binディレクトリと/var/www/htmlディレクトリでは、スクリプト実行権(httpd_sys_script_exec_t)の有無が違ってる。今までは、htmlディレクトリ以下でスクリプトを実行しようとしていたが、SeLinux的にそれはNGだった。ここで取る対処案は1つ。

  • cgi-binの方でNagioscgiを実行する。
  • html配下でcgiを実行できるようにSeLinux?としての定義をいじる。(apacheレベルでのcgi実行権限はhttpd.confとかでもうやってる。)

今現在、「cgi-binの方でNagioscgiを実行する。」の方を試し中。