Cool Solutions

Monitoring iPrint printer queues with Icinga2


August 18, 2015 8:54 am





I have created a new plugin to use with Icinga2, it should work with Nagios.

Find it on Icinga Exchange ->

I am currently monitoring 325 iPrinter queues on seven different servers in a single “pane of glass” with this plugin. Readme File

Author: dbenjamin
Created: Aug 4, 2015
Release: 0.0.1
Tested against Novell iPrint Server, running on SLES 11,
SP3 with OES 11, SP2.

Usage: -I <host address> -Q <queue name> [-P <port> default=631] [-v enable verbose] [--version]

-I Host IP address.
-Q Queue name. This can be found by browsing to your iPrint server at
http://<server ip address>:<port, default=631>/ipp/
each printer queue name should be listed.

-P Port to use for testing, the default is 631.
-v Enable verbose output for testing, do not use this in your monitoring
--version Output some version information, do not use this in your
monitoring software.

You can integrate with Icinga2 following these instructions.
1) Download the script.

2) Find the CustomPluginDir path in /etc/icinga2/constants.conf or where
your distro may have placed the config file.

3) Place the script in the CustomPluginDir directory and make
the file executable.

4) Define the service. I created a file in /etc/icinga2.conf/
contents of iprinters.conf file:
object CheckCommand "iprinters" {
import "plugin-check-command"

command = [ CustomPluginDir + "/" ]

arguments = {
"-I" = "$address$"
"-Q" = "$iprint_queue$"

apply Service for (iPrint => config in host.vars.iprinters) {
import "generic-service"

check_command = "iprinters"

vars += config
} /* EOF iprinters.conf */

5) Define iPrint queue attributes in your host definitions.
Mine looks like this, yes the queue name is "7UP":
/* Define iPrint queue attributes for service apply rules. */
vars.iprinters["iprint 7UP"] = {
iprint_queue = "7UP"

0 votes, average: 0.00 out of 50 votes, average: 0.00 out of 50 votes, average: 0.00 out of 50 votes, average: 0.00 out of 50 votes, average: 0.00 out of 5 (0 votes, average: 0.00 out of 5)
You need to be a registered member to rate this post.

Tags: , , ,
Categories: Cool Tools, iPrint, Technical

Disclaimer: This content is not supported by Micro Focus. It was contributed by a community member and is published "as is." It seems to have worked for at least one person, and might work for you. But please be sure to test it thoroughly before using it in a production environment.