All Projects → ethnchao → Docker Nagios

ethnchao / Docker Nagios

Docker-Nagios provide Nagios service running on the docker container and a series of solution for Nagios

Projects that are alternatives of or similar to Docker Nagios

docker-graphite
Run Graphite with Docker
Stars: ✭ 15 (-63.41%)
Mutual labels:  grafana, graphite
yanic
Yet another node info collector - for respondd to be used with meshviewer to Grafana (with influxdb or graphite)
Stars: ✭ 22 (-46.34%)
Mutual labels:  grafana, graphite
grafana-pnp-datasource
PNP4Nagios/RRD Datasource for Grafana
Stars: ✭ 27 (-34.15%)
Mutual labels:  grafana, nagios
Grafana
The open and composable observability and data visualization platform. Visualize metrics, logs, and traces from multiple sources like Prometheus, Loki, Elasticsearch, InfluxDB, Postgres and many more.
Stars: ✭ 45,930 (+111924.39%)
Mutual labels:  mysql, grafana
Victoriametrics
VictoriaMetrics: fast, cost-effective monitoring solution and time series database
Stars: ✭ 5,558 (+13456.1%)
Mutual labels:  graphite, grafana
grafana-stack
Tiny docker images for graphite, grafana and statsdly
Stars: ✭ 28 (-31.71%)
Mutual labels:  grafana, graphite
atop-graphite-grafana-monitoring
Tools to extract raw system counters from atop, aggregate them to generate high level performance metrics, whose are then injected into a Graphite database and visualize through Grafana dashboards.
Stars: ✭ 15 (-63.41%)
Mutual labels:  grafana, graphite
Ohmgraphite
Export Open Hardware sensor data to Graphite / InfluxDB / Prometheus / Postgres / Timescaledb
Stars: ✭ 155 (+278.05%)
Mutual labels:  grafana, graphite
Shell
Infrastructure Management Shell - Linux
Stars: ✭ 381 (+829.27%)
Mutual labels:  mysql, nagios
Awesome Monitoring
INFRASTRUCTURE、OPERATION SYSTEM and APPLICATION monitoring tools for Operations.
Stars: ✭ 356 (+768.29%)
Mutual labels:  grafana, nagios
Netdata
Real-time performance monitoring, done right! https://www.netdata.cloud
Stars: ✭ 57,056 (+139060.98%)
Mutual labels:  grafana, graphite
Wizzy
Manage & automate Grafana with easy wizzy
Stars: ✭ 461 (+1024.39%)
Mutual labels:  grafana, graphite
Icinga Vagrant
Vagrant boxes for Icinga 2, Icinga Web 2, modules, themes and integrations (Graphite, InfluxDB, Elastic, Graylog, etc.)
Stars: ✭ 248 (+504.88%)
Mutual labels:  grafana, graphite
dokku-graphite
a graphite, grafana, statsd, carbon plugin for dokku
Stars: ✭ 47 (+14.63%)
Mutual labels:  grafana, graphite
Icingaweb2 Module Grafana
Grafana module for Icinga Web 2 (supports InfluxDB & Graphite)
Stars: ✭ 190 (+363.41%)
Mutual labels:  grafana, graphite
histou
Adds templates to Grafana in combination with nagflux
Stars: ✭ 33 (-19.51%)
Mutual labels:  grafana, nagios
Influxgraph
Graphite InfluxDB backend. InfluxDB storage finder / plugin for Graphite API.
Stars: ✭ 87 (+112.2%)
Mutual labels:  grafana, graphite
Appmetrics
App Metrics is an open-source and cross-platform .NET library used to record and report metrics within an application.
Stars: ✭ 1,986 (+4743.9%)
Mutual labels:  grafana, graphite
Hastic Server
Hastic data management server for analyzing patterns and anomalies from Grafana
Stars: ✭ 292 (+612.2%)
Mutual labels:  grafana, graphite
Ansible Playbooks
Ansible playbook collection that have been written for Ubuntu. Some of the playbooks are Elasticsearch, Mesos, AWS, MySql, Sensu, Nginx etc..
Stars: ✭ 429 (+946.34%)
Mutual labels:  mysql, grafana

Build Status

docker-nagios

Docker-Nagios provide Nagios service running on the docker container and a series of solution for Nagios: Adagios for Web Based Nagios Configuration, Grafana for monitor metric & dashboards, Ndoutils for transfer monitor data to MySQL Database, NCPA&NRDP for nagios passive checks.

As the docker-image contains a large number of software, the following describes the various components of the version and the basic information:

  • phusion/baseimage:latest Docker baseimage
  • Nagios Core 4.4.6 Nagios core - the community version
  • Nagios Plugins 2.2.1 Nagios plugins
  • Graphios 2.0.3 Send Nagios spool data to graphite
  • Graphite 1.1.3 Grafana's datasource
  • Grafana 5.1.3 The tool for beautiful monitoring and metric analytics & dashboards for Graphite, InfluxDB & Prometheus & More
  • NDOUtils 2.1.3 Allow you save all the data to MySQL database
  • PyNag 0.9.1-1 A command line tool for managing nagios configuration and provides a framework to write plugins
  • Okconfig 1.3.2-1 Provides a templated Nagios configuration, Adagios can use okconfig to quickly and easily configure Nagios
  • MK-livestatus 1.2.8p20 MK-livestatus can get Nagios status information, loaded as broker module into Nagios configuration, and Adagios uses mk-livestatus to get status information
  • Adagios 1.6.3-2 A web based Nagios configuration interface built to be simple and intuitive in design, exposing less of the clutter under the hood of nagios. Adagios is more lighter UI than Check_MK, based on mod_wsgi(so it cannot be used with Check_MK, Check_MK based on mod_python, already deprecated and conflict with mod_wsgi)
  • NRDP 1.5.2 A flexible data transport mechanism and processor for Nagios. It uses standard ports protocols (HTTP(S) and XML for api response) and can be implemented as a replacement for NSCA. Used with NCPA, omg, those bloody names(nrpe,ncpa,nrds,nrdp,nsti...).
  • NCPA 2.1.3 The Nagios Cross-Platform Agent; a single monitoring agent that installs on all major operating systems. NCPA with a built-in web GUI, we will use ncpa for passive checks.

Quick start

Ad-hoc run nagios in docker.

$ docker run --name nagios -p 80:80 -p 3000:3000 -d ethnchao/nagios

Accessing nagios and Adagios:

If you need to use a custom login user name and password, you can run the container with the environment variables: NAGIOSADMIN_USER andNAGIOSADMIN_PASS.

$ docker run --name nagios -p 9001:80 -p 3000:3000 \
  -e NAGIOSADMIN_USER=john \
  -e NAGIOSADMIN_PASS=secret_code \
  -d ethnchao/nagios

Run with docker-compose

We recommend that you use docker-compose to run Nagios with MySQL containers, check this docker-compose.yml

Setting advertise address

In some features, such as using the Adagios - Okconfig - Install Agent, you need to configure the NRDP server address in the remote client. The IP + port of the address is also the address of the Nagios server, but when you use the Docker to run the container, Nagios Do not know what their own server address, so when we run the container, passing the server address to it.

$ docker run --name nagios -p 9001:80 -p 3000:3000 -d ethnchao/nagios --server-url http://172.17.242.190:9001

Store data files in local

You can choose to mount additional configuration files, plugin, okconfig-example to the container, such as the additional configuration file on /data/conf, plugin on /data/plugin, okconfig-example on /data/example.

$ docker run --name nagios -p 80:80 -p 3000:3000 \
  -v /data/conf:/usr/local/nagios/etc/mount \
  -v /data/plugin:/data/plugin \
  -v /data/example:/data/example \
  -d ethnchao/nagios

Store monitoring data in MySQL

If you need to store the monitoring information in MySQL database, you need to enable Ndoutils, which there are two cases:

  1. If you already executed the Ndoutils database initialization script in the MySQL database, then run this container with option: --enable-ndo.
$ docker run --name nagios -p 80:80 -p 3000:3000 \
  -e MYSQL_USER=nagios -e MYSQL_PASSWORD=nagios \
  -e MYSQL_ADDRESS=172.17.242.178 -e MYSQL_DATABASE=nagios \
  -d ethnchao/nagios --enable-ndo
  1. If you did not execute the Ndoutils initalization script in the MySQL database, you can run this container with option: --enable-ndo --create-db
$ docker run --name nagios -p 80:80 -p 3000:3000 \
  -e MYSQL_USER=nagios -e MYSQL_PASSWORD=nagios \
  -e MYSQL_ADDRESS=172.17.242.178 -e MYSQL_DATABASE=nagios \
  -d ethnchao/nagios --enable-ndo --create-db

Setting E-Mail

By setting heirloom-mailx, you'll be able to send email with s-nail command in nagios/adagios interface.

  1. Set /etc/s-nail.rc, adding these line:
set from=[email protected]
set smtp=smtps://demo.com:465
set smtp-auth-user=[email protected]
set smtp-auth-password=your-email-password
set smtp-auth=login

Build from source

Build the Nagios image from github source.

$ docker build -t nagios .

Configuration file location

Software Config file location
Nagios /usr/local/nagios/etc
Adagios /etc/adagios
Okconfig /etc/okconfig.conf
NRDP /usr/local/nrdp
Graphios /etc/graphios/graphios.cfg
Graphite /opt/graphite/conf/

Packages Dependency

To reduce the size of the docker-image, we use the apt and pip to install a lot of packages in the same RUN instruction, each software(like adagios/nagios-plugins) only depends on some of the packages, the following records the software depends on which packages, dependencies all come from official documents of the software, some from the actual operation of the adjustment.

Nagioscore needs the following dependencies: (The software list is less than the official documents, some of the official website of the software has been dependent on each other, no need to write)

apache2 \
apache2-utils \
autoconf \
bc \
build-essential \
dc \
gawk \
gettext \
gperf \
libapache2-mod-php \
libgd2-xpm-dev \
libmcrypt-dev \
libssl-dev \
unzip

Nagios command: notify-by-mail

bsd-mailx

The following dependencies are required for the Nagios-Plugin compilation installation:

m4 \
gettext \
automake \
autoconf

The dependencies that may be used when the Nagios plugin is running:

iputils-ping \
fping \
postfix \
libnet-snmp-perl \
smbclient \
snmp \
snmpd \
snmp-mibs-downloader \
netcat

Software installation related:

python-pipgitpython-dev

System services:

runitsudoparallel

The following dependencies are required for the Graphite installation:

apache2 \
apache2-utils \
build-essential \
libcairo2-dev \
libffi-dev \
libapache2-mod-wsgi

The following dependencies are required for the Graphios installation:

sudo

The following dependencies are required for the Ndoutils installation:

mysql-client \
libmysql++-dev \
libmysqlclient-dev

The following dependencies are required for the Nrpe installation:

build-essential

The following dependencies are required when the NRDP is running:

php7.0-xml
Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].