Nagios Core Administration Cookbook

The ideal book for System Administrators who want to move their network monitoring to an advanced level. This book covers the powerful features and flexibility of Nagios Core, and its recipes can be applied to virtually any network.

Nagios Core Administration Cookbook

Cookbook
Tom Ryder

The ideal book for System Administrators who want to move their network monitoring to an advanced level. This book covers the powerful features and flexibility of Nagios Core, and its recipes can be applied to virtually any network.
$29.99
$49.99
RRP $29.99
RRP $49.99
eBook
Print + eBook
$12.99 p/month

Get Access

Get Unlimited Access to every Packt eBook and Video course

Enjoy full and instant access to over 3000 books and videos – you’ll find everything you need to stay ahead of the curve and make sure you can always get the job done.

Book Details

ISBN 139781849515566
Paperback360 pages

About This Book

  • Monitor almost anything in a network
  • Control notifications in your network by configuring Nagios Core
  • Get a handle on best practices and time-saving configuration methods for a leaner configuration
  • Use the web interface to control notification behaviour on the fly and for scheduled outages, without restarts
  • Pull Nagios Core's data into a database to write clever custom reports of your own devising

Who This Book Is For

This book is for System Administrators who are looking for recipes to help them deal with advanced network monitoring issues with Nagios Core.

Table of Contents

Chapter 1: Understanding Hosts, Services, and Contacts
Introduction
Creating a new network host
Creating a new HTTP service
Creating a new e-mail contact
Verifying configuration
Creating a new hostgroup
Creating a new servicegroup
Creating a new contactgroup
Creating a new time period
Running a service on all hosts in a group
Chapter 2: Working with Commands and Plugins
Introduction
Finding a plugin
Installing a plugin
Removing a plugin
Creating a new command
Customizing an existing command
Using an alternative check command for hosts
Writing a new plugin from scratch
Chapter 3: Working with Checks and States
Introduction
Specifying how frequently to check a host or service
Changing thresholds for PING RTT and packet loss
Changing thresholds for disk usage
Scheduling downtime for a host or service
Managing brief outages with flapping
Adjusting flapping percentage thresholds for a service
Chapter 4: Configuring Notifications
Introduction
Configuring notification periods
Configuring notification for groups
Specifying which states to be notified about
Tolerating a certain number of failed checks
Automating contact rotation
Defining an escalation for repeated notifications
Defining a custom notification method
Chapter 5: Monitoring Methods
Introduction
Monitoring PING for any host
Monitoring SSH for any host
Checking an alternative SSH port
Monitoring mail services
Monitoring web services
Checking that a website returns a given string
Monitoring database services
Monitoring the output of an SNMP query
Monitoring a RAID or other hardware device
Creating an SNMP OID to monitor
Chapter 6: Enabling Remote Execution
Introduction
Monitoring local services on a remote machine with NRPE
Setting the listening address for NRPE
Setting allowed client hosts for NRPE
Creating new NRPE command definitions securely
Giving limited sudo privileges to NRPE
Using check_by_ssh with key authentication instead of NRPE
Chapter 7: Using the Web Interface
Introduction
Using the Tactical Overview
Viewing and interpreting availability reports
Viewing and interpreting trends
Viewing and interpreting notification history
Adding comments on hosts or services in the web interface
Viewing configuration in the web interface
Scheduling checks from the web interface
Acknowledging a problem via the web interface
Chapter 8: Managing Network Layout
Introduction
Creating a network host hierarchy
Using the network map
Choosing icons for hosts
Establishing a host dependency
Establishing a service dependency
Monitoring individual nodes in a cluster
Using the network map as an overlay
Chapter 9: Managing Configuration
Introduction
Grouping configuration files in directories
Keeping configuration under version control
Configuring host roles using groups
Building groups using regular expressions
Using inheritance to simplify configuration
Defining macros in a resource file
Dynamically building host definitions
Chapter 10: Security and Performance
Introduction
Requiring authentication for the web interface
Using authenticated contacts
Writing debugging information to a Nagios log file
Monitoring Nagios performance with Nagiostats
Improving startup times with pre-cached object files
Setting up a redundant monitoring host
Chapter 11: Automating and Extending Nagios Core
Introduction
Allowing and submitting passive checks
Submitting passive checks from a remote host with NSCA
Submitting passive checks in response to SNMP traps
Setting up an event handler script
Tracking host and service states with Nagiosgraph
Reading status into a MySQL database with NDOUtils
Writing customized Nagios Core reports
Getting extra visualizations with NagVis

What You Will Learn

  • Finding, installing, and writing your own plugins, and learning to reference them as Nagios Core commands for use as host and service checks, including workarounds for making checks through difficult network layouts such as those using Network Address Translation.
  • Managing notifications to send the right kind of notifications to the right people at the right time, and defining contact methods besides simple email messages, including an example of automatic contact rotation.
  • In-depth examples of using the standard set of Nagios Plugins for common network monitoring needs, with discussion of generic methods for monitoring the results of SNMP queries.
  • Remote monitoring methods to handle the situations where Nagios Core cannot directly check a service's status over the network, to check things such as database servers that only listen locally, or hardware devices with no SNMP OIDs exported.
  • Defining network structure and dependencies in Nagios Core to enable it to perform its notification behavior more intelligently, and allow you to very quickly find the "root" of particular problems; also how to reflect this structure in the network map once defined, and even decorate it.
  • Best practices for managing Nagios Core configuration to make it leaner, more robust, and better suited to programatically generating configuration as specified by other systems.
  • Automating other interactions with Nagios Core, including using passive checks to track tasks being performed both locally and in other parts of the network, or running scripts automatically in response to checks; also includes discussion of developing your own reports or vizualisations using automatically exported data from the system.

In Detail

Network monitoring requires significantly more than just pinging hosts. This cookbook will help you to comprehensively test your networks’ major functions on a regular basis.

"Nagios Core Administration Cookbook" will show you how to use Nagios Core as a monitoring framework that understands the layers and subtleties of the network for intelligent monitoring and notification behaviour.

Nagios Core Administration Guide introduces the reader to methods of extending Nagios Core into a network monitoring solution. The book begins by covering the basic structure of hosts, services, and contacts and then goes on to discuss advanced usage of checks and notifications, and configuring intelligent behaviour with network paths and dependencies. The cookbook emphasizes using Nagios Core as an extensible monitoring framework. By the end of the book, you will learn that Nagios Core is capable of doing much more than pinging a host or to check if websites respond.

Authors

Table of Contents

Chapter 1: Understanding Hosts, Services, and Contacts
Introduction
Creating a new network host
Creating a new HTTP service
Creating a new e-mail contact
Verifying configuration
Creating a new hostgroup
Creating a new servicegroup
Creating a new contactgroup
Creating a new time period
Running a service on all hosts in a group
Chapter 2: Working with Commands and Plugins
Introduction
Finding a plugin
Installing a plugin
Removing a plugin
Creating a new command
Customizing an existing command
Using an alternative check command for hosts
Writing a new plugin from scratch
Chapter 3: Working with Checks and States
Introduction
Specifying how frequently to check a host or service
Changing thresholds for PING RTT and packet loss
Changing thresholds for disk usage
Scheduling downtime for a host or service
Managing brief outages with flapping
Adjusting flapping percentage thresholds for a service
Chapter 4: Configuring Notifications
Introduction
Configuring notification periods
Configuring notification for groups
Specifying which states to be notified about
Tolerating a certain number of failed checks
Automating contact rotation
Defining an escalation for repeated notifications
Defining a custom notification method
Chapter 5: Monitoring Methods
Introduction
Monitoring PING for any host
Monitoring SSH for any host
Checking an alternative SSH port
Monitoring mail services
Monitoring web services
Checking that a website returns a given string
Monitoring database services
Monitoring the output of an SNMP query
Monitoring a RAID or other hardware device
Creating an SNMP OID to monitor
Chapter 6: Enabling Remote Execution
Introduction
Monitoring local services on a remote machine with NRPE
Setting the listening address for NRPE
Setting allowed client hosts for NRPE
Creating new NRPE command definitions securely
Giving limited sudo privileges to NRPE
Using check_by_ssh with key authentication instead of NRPE
Chapter 7: Using the Web Interface
Introduction
Using the Tactical Overview
Viewing and interpreting availability reports
Viewing and interpreting trends
Viewing and interpreting notification history
Adding comments on hosts or services in the web interface
Viewing configuration in the web interface
Scheduling checks from the web interface
Acknowledging a problem via the web interface
Chapter 8: Managing Network Layout
Introduction
Creating a network host hierarchy
Using the network map
Choosing icons for hosts
Establishing a host dependency
Establishing a service dependency
Monitoring individual nodes in a cluster
Using the network map as an overlay
Chapter 9: Managing Configuration
Introduction
Grouping configuration files in directories
Keeping configuration under version control
Configuring host roles using groups
Building groups using regular expressions
Using inheritance to simplify configuration
Defining macros in a resource file
Dynamically building host definitions
Chapter 10: Security and Performance
Introduction
Requiring authentication for the web interface
Using authenticated contacts
Writing debugging information to a Nagios log file
Monitoring Nagios performance with Nagiostats
Improving startup times with pre-cached object files
Setting up a redundant monitoring host
Chapter 11: Automating and Extending Nagios Core
Introduction
Allowing and submitting passive checks
Submitting passive checks from a remote host with NSCA
Submitting passive checks in response to SNMP traps
Setting up an event handler script
Tracking host and service states with Nagiosgraph
Reading status into a MySQL database with NDOUtils
Writing customized Nagios Core reports
Getting extra visualizations with NagVis

Book Details

ISBN 139781849515566
Paperback360 pages
Read More