./www/pnp4nagios [Nagios/Icinga addon which graphs performance data]
[+] Add this package to your ports tracker

[ CVSweb ] [ Homepage ] [ RSS feed ]

Version: 0.6.26, Package name: pnp4nagios-0.6.26
Maintained by: Kirill Bychkov
Master sites:
Description-cgi
PNP4Nagios web interface.

Description-main
PNP is an addon to Nagios and Icinga which analyzes performance data
provided by plugins and stores them automatically into RRD-databases
(Round Robin Databases).

README-main
$OpenBSD: README-main,v 1.4 2017/11/11 11:01:21 kirby Exp $

+-----------------------------------------------------------------------
| Running pnp4nagios on OpenBSD
+-----------------------------------------------------------------------

General
=======

Pnp4nagios has no default runtime dependencies to a monitoring tool,
as well as to a monitoring webinterface or web server. Example
instructions below are given for icinga, icinga-web and Apache2, as
well as icinga2, icinga-web2 and nginx.

Log file in ${VARBASE}/log/pnp4nagios will need to be rotated. Here is
a sample line for newsyslog.conf:

${VARBASE}/log/pnp4nagios/pnp4nagios.log _icinga:_icinga 644 7 250 * Z

Icinga, Icinga-web, Apache
==========================

Apache2 configuration
---------------------
Apache2 configuration for PNP4Nagios is stored under:
${VARBASE}/www/conf/modules.sample/pnp4nagios.conf

It needs to be enabled by running the following command:
# ln -s ../modules.sample/pnp4nagios.conf ${VARBASE}/www/conf/modules
# rcctl restart apache2

Icinga-web configuration
------------------------
To integrate PNP4Nagios into the Icinga Web frontend you will need to
install templates extensions which comes with icinga-web package:
% cd ${VARBASE}/www/icinga-web/app/modules/Cronks/data/xml/extensions
# ln -s pnp-host-extension.xml.dist pnp-host-extension.xml
# ln -s pnp-service-extension.xml.dist pnp-service-extension.xml

Icinga2, Icinga-web2, Nginx
===========================
Pnp4nagios runs with php_fpm behind nginx in a chrooted environment.

Prepare the chroot environment
------------------------------
- follow the instructions in the rrdtool package README
to chroot rrdtool
- copy /bin/sh to ${VARBASE}/www/bin
- copy ${SYSCONFDIR} ${VARBASE}/www${SYSCONFDIR}
- copy ${LOCALBASE}/lib/kohana/system ${VARBASE}/www${LOCALBASE}/lib/kohana/system
- edit ${VARBASE}/www${SYSCONFDIR}/config.php
- ensure: $conf['rrdbase'] = "/pnp4nagios/rrd/";
- ensure: $conf['nagios_base'] = "/icingaweb2";

Icinga2 configuration
---------------------
With Icinga2 enable the perfdata feature:

# icinga2 feature enable perfdata

Pnp4nagios will use the npcd daemon, and work in the 'bulk' mode.
In ${SYSCONFDIR}/npcd.cfg update the 'perfdata_spool_dir'
to point to '${VARBASE}/spool/icinga2/perfdata'. Additionally ensure
the 'perfdata_file_run_cmd_args' has a '--bulk' argument specified.

In ${SYSCONFDIR}/process_perfdata.cfg ensure the
RRDPATH setting points to '${VARBASE}/www/pnp4nagios/rrd'.

Finally enable npcd:

# rcctl enable npcd

Nginx configuration
-------------------
Below a minimal snippet for the nginx configuration:

server {

...

location /pnp4nagios {

alias ${VARBASE}/www/pnp4nagios;
}

location ~ ^(/pnp4nagios.*\.php)(.*)$ {


root /pnp4nagios;
include ${SYSCONFDIR}/nginx/fastcgi_params;

fastcgi_pass unix:run/php-fpm-pnp4nagios.sock;
fastcgi_split_path_info ^(.+\.php)(.*)$;
fastcgi_param PATH_INFO $fastcgi_path_info;
fastcgi_param SCRIPT_FILENAME $document_root/index.php;
}
}

Php_fpm configuration
---------------------
Configure php_fpm pool, the most important configuration
entries:

[pnp4nagios]
listen = ${VARBASE}/www/run/php-fpm-pnp4nagios.sock
listen.owner = www
listen.group = www
listen.mode = 0660
user = _icinga
group = _icinga
chroot = ${VARBASE}/www

Icinga-web2 configuration
-------------------------
Pnp4nagios integration with Icinga-web2 is done via PNP
module, that can be found here:
- https://github.com/Icinga/icingaweb2-module-pnp
For installation and configuration follow the modules
instructions.

RRD tweaks.
=====================
Optionally you may want to use rrdcached to reduce disk I/O.
Here is a sample /etc/rc.conf.local part:
rrdcached_flags=-b ${VARBASE}/www/pnp4nagios/rrd -m 0660 -s _icinga -l unix:${VARBASE}/www/pnp4nagios/rrd/rrdcached.sock -j ${VARBASE}/www/pnp4nagios/rrd//journal -p ${VARBASE}/www/pnp4nagios/rrd/rrdcached.pid -w 1800 -z 1800 -F -P FLUSH,PENDING
rrdcached_user=_icinga


Filesize: 2968.032 KB
Version History (View Complete History)
  • (2017-08-23) Updated to version: pnp4nagios-0.6.26
  • (2016-04-26) Package added to openports.se, version pnp4nagios-0.6.25 (created)
[show/hide] View available PLISTS (Can be a lot of data)

CVS Commit History:

   2017-08-23 08:28:31 by Kirill Bychkov | Files touched by this commit (9)
Log message:
update to pnp4nagios-0.6.26
remove patches commited upstream
   2017-08-23 08:28:31 by Kirill Bychkov | Files touched by this commit (9)
Log message:
update to pnp4nagios-0.6.26
remove patches commited upstream
   2017-08-23 08:28:31 by Kirill Bychkov | Files touched by this commit (9)
Log message:
update to pnp4nagios-0.6.26
remove patches commited upstream
   2017-08-23 08:28:31 by Kirill Bychkov | Files touched by this commit (9)
Log message:
update to pnp4nagios-0.6.26
remove patches commited upstream
   2017-08-23 08:28:31 by Kirill Bychkov | Files touched by this commit (9)
Log message:
update to pnp4nagios-0.6.26
remove patches commited upstream
   2017-08-23 08:28:31 by Kirill Bychkov | Files touched by this commit (9)
Log message:
update to pnp4nagios-0.6.26
remove patches commited upstream
   2017-08-23 08:28:31 by Kirill Bychkov | Files touched by this commit (9)
Log message:
update to pnp4nagios-0.6.26
remove patches commited upstream
   2017-08-23 08:28:31 by Kirill Bychkov | Files touched by this commit (9)
Log message:
update to pnp4nagios-0.6.26
remove patches commited upstream
   2017-08-23 08:28:31 by Kirill Bychkov | Files touched by this commit (9)
Log message:
update to pnp4nagios-0.6.26
remove patches commited upstream
   2016-07-11 03:17:45 by Kirill Bychkov | Files touched by this commit (3)
Log message:
fix paths to config files. from Caspar Schutijser, thanks!
   2016-07-11 03:17:45 by Kirill Bychkov | Files touched by this commit (3)
Log message:
fix paths to config files. from Caspar Schutijser, thanks!
   2016-07-11 03:17:45 by Kirill Bychkov | Files touched by this commit (3)
Log message:
fix paths to config files. from Caspar Schutijser, thanks!
   2016-05-23 14:24:11 by Sebastian Reitenbach | Files touched by this commit (4)
Log message:
In favor of creating FLAVORS, remove RDEP to specific icinga
(-web) versions. It works well with icinga, and icinga2.
lots of feedback sthen@
Diff looks good to me kirby@ (MAINTAINER)
   2016-05-23 14:24:11 by Sebastian Reitenbach | Files touched by this commit (4)
Log message:
In favor of creating FLAVORS, remove RDEP to specific icinga
(-web) versions. It works well with icinga, and icinga2.
lots of feedback sthen@
Diff looks good to me kirby@ (MAINTAINER)
   2016-05-23 14:24:11 by Sebastian Reitenbach | Files touched by this commit (4)
Log message:
In favor of creating FLAVORS, remove RDEP to specific icinga
(-web) versions. It works well with icinga, and icinga2.
lots of feedback sthen@
Diff looks good to me kirby@ (MAINTAINER)
   2016-05-23 14:24:11 by Sebastian Reitenbach | Files touched by this commit (4)
Log message:
In favor of creating FLAVORS, remove RDEP to specific icinga
(-web) versions. It works well with icinga, and icinga2.
lots of feedback sthen@
Diff looks good to me kirby@ (MAINTAINER)
   2016-05-18 11:34:01 by Antoine Jacoutot | Files touched by this commit (2)
Log message:
Don't hardcode paths.
   2016-05-18 11:34:01 by Antoine Jacoutot | Files touched by this commit (2)
Log message:
Don't hardcode paths.
   2016-05-18 03:24:00 by Sebastian Reitenbach | Files touched by this commit (3)
Log message:
Add rc script for npcd
feedback and OK zhuk@, kirby@ (MAINTAINER)
   2016-05-18 03:24:00 by Sebastian Reitenbach | Files touched by this commit (3)
Log message:
Add rc script for npcd
feedback and OK zhuk@, kirby@ (MAINTAINER)
   2016-05-18 03:24:00 by Sebastian Reitenbach | Files touched by this commit (3)
Log message:
Add rc script for npcd
feedback and OK zhuk@, kirby@ (MAINTAINER)
   2016-05-17 01:13:42 by Kirill Bychkov | Files touched by this commit (9)
Log message:
- fix config syntax for apache-2.4.x
- fix compatibility with rrdtool-1.6.x
- @sample templates
   2016-05-17 01:13:42 by Kirill Bychkov | Files touched by this commit (9)
Log message:
- fix config syntax for apache-2.4.x
- fix compatibility with rrdtool-1.6.x
- @sample templates
   2016-05-17 01:13:42 by Kirill Bychkov | Files touched by this commit (9)
Log message:
- fix config syntax for apache-2.4.x
- fix compatibility with rrdtool-1.6.x
- @sample templates
   2016-05-17 01:13:42 by Kirill Bychkov | Files touched by this commit (9)
Log message:
- fix config syntax for apache-2.4.x
- fix compatibility with rrdtool-1.6.x
- @sample templates
   2016-05-17 01:13:42 by Kirill Bychkov | Files touched by this commit (9)
Log message:
- fix config syntax for apache-2.4.x
- fix compatibility with rrdtool-1.6.x
- @sample templates
   2016-05-17 01:13:42 by Kirill Bychkov | Files touched by this commit (9)
Log message:
- fix config syntax for apache-2.4.x
- fix compatibility with rrdtool-1.6.x
- @sample templates
   2016-05-17 01:13:42 by Kirill Bychkov | Files touched by this commit (9)
Log message:
- fix config syntax for apache-2.4.x
- fix compatibility with rrdtool-1.6.x
- @sample templates
   2016-05-17 01:13:42 by Kirill Bychkov | Files touched by this commit (9)
Log message:
- fix config syntax for apache-2.4.x
- fix compatibility with rrdtool-1.6.x
- @sample templates
   2016-05-17 01:13:42 by Kirill Bychkov | Files touched by this commit (9)
Log message:
- fix config syntax for apache-2.4.x
- fix compatibility with rrdtool-1.6.x
- @sample templates