Debian Codegraph @

contrib/README

raw
1 #####################
2 Nagios Contrib README
3 #####################
4
5 This directory contains various programs, scripts, etc. that
6 have been contributed by various people. Read the source code
7 if you want to find who did what.
8
9 Here is a description of what you'll find...
10
11
12 Conversion Programs:
13 --------------------
14
15 - convertcfg.c is a program to quickly convert old "host" config
16 files to the new template-based object config files. It can also
17 convert extended host information definitions. Type 'make convertcfg'
18 to compile the utility.
19
20
21 Additional CGIs:
22 ----------------
23
24 - traceroute.cgi is (surprise) a CGI that allows you to do a traceroute
25 to a specific IP address. Simply do a 'chmod +x' to make it executable
26 and place it in the CGI directory (i.e. /usr/local/nagios/sbin).
27 Requires Perl.
28
29 - daemonchk.c is a CGI contributed by Karl DeBisschop that can test to
30 see whether or not the Nagios process is running.
31
32
33 Miscellaneous Goodies:
34 ----------------------
35
36 - htaccess.sample is a *sample* .htaccess file that can be used with
37 Apache to require password authentication for access to the web
38 interface.
39
40 - Notes about "make rpm" addition, tested on RockyLinux 8
41 1. Using 4.4.6 as example, download epel-nagios.spec and epel-patches/* files.
42 wget https://download-ib01.fedoraproject.org/pub/epel/8/Everything/SRPMS/Packages/n/nagios-4.4.6-4.el8.src.rpm
43 rpm -ivh nagios-4.4.6-4.el8.src.rpm # Install patches into ~/RPMBUILD/SOURCES and nagios into ~/RPMBUILD/SPECS
44 cp ~/RPMBUILD/SOURCES/* epel-patches
45 cp ~/RPMBUILD/SPECS/nagios ./epel-nagios.spec
46
47 2. Prepare your rpmbuild environment to buuild EPEL8+ RPMs.
48
49 sudo yum install -y rpmdevtools gcc libtool rpmbuild \
50 policycoreutils-devel selinux-policy-devel \
51 perl-generators gdbm-devel pyparsing systemtap perl-ExtUtils-Manifest \
52 libdb perl-ExtUtils-MakeMaker perl-ExtUtils-Install perl-devel \
53 perl-ExtUtils-ParseXS perl-local-lib perl-CPAN perl-ExtUtils-AutoInstall \
54 perl-Test-Simple perl-ExtUtils-Embed perl-HTML-Lint
55
56 3. Generate contrib/Makefile from contrib/Makefile.in.
57
58 ../configure # To generate contrib/Makefile from Makefile.in
59 make rpm # Do the rpm build under ./rpmbuild directory
60 make localsrc-rpm # tar up existing src code to create rpm
61
62 4. Testing upgrade Nagioscore 4.4.6 on this build host using RPMs created here.
63
64 sudo rpm -Uvh nagios-common-4.4.6-1el8.x86_64.rpm nagios-contrib-4.4.6-1el8.x86_64.rpm \
65 nagios-devel-4.4.6-1el8.x86_64.rpm nagios-4.4.6-1el8.x86_64.rpm
66 sudo systemctl daemon-reload
67 sudo systemctl restart nagios
68