Skip to main content

Windows printers

Windows printers

Plugin: windows.plugin Module: GetPrinters

Maintained by Netdata

Overview​

This collector monitors Windows print queues: queued jobs, printer status, and jobs by status. It covers local printers and printer connections configured on the host; it does not poll printer devices, which the SNMP collector covers.

It calls the print spooler API. EnumPrintersW lists printer names from the local registry and cache without contacting print servers. Each selected printer is then opened to read its status flags and queued job count (GetPrinterW) and, when jobs are queued, its jobs (EnumJobsW). Status values follow the Win32_Printer and Win32_PrintJob mappings used by Windows Exporter, except that a printer reporting several status flags at once gets its most severe state (problems first), a connection whose print server is offline reports other, a status the server reports as unknown reports unknown, a job with no status flags counts as queued (and leaves an otherwise flagless printer idle), and a blocked job or one waiting for user intervention counts as degraded. The job owner, submitting machine, and document title returned with each job are never logged, charted, or exported.

This collector is only supported on the following platforms:

  • windows

This collector supports collecting metrics from multiple instances of this integration.

Default Behavior​

Auto-Detection​

The collector is disabled by default. When enabled, it discovers printers automatically and charts up to 100 printers matching printers to monitor, chosen in case-insensitive alphabetical order. Printers that do not match or exceed the limit get no charts, and their queues are not opened.

Limits​

By default, at most 100 printers are charted, four charts each.

Performance Impact​

One name enumeration per collection, plus one printer open and status read per selected printer, and a job read for selected printers with queued jobs. Unselected printers are never opened. For a selected printer connection, opening it can contact the print server and block when it is unreachable. The module always runs on its own thread; a blocked call stops only this module, but Netdata shutdown waits for it to return.

Setup​

Prerequisites​

The Windows Spooler service must be running. While it is stopped, the charts show gaps and existing printers are kept until a successful enumeration shows they are gone.

Configuration​

Options​

OptionDescriptionDefaultRequired
update everyData collection frequency.10no
printers to monitorCase-insensitive simple patterns separated by commas or pipes, matched against the full printer name. Printer connection names such as \\server\printer can be pasted verbatim; escape a comma or pipe with a backslash to match it literally. Prefix a pattern with ! to exclude matching printers, and add a positive pattern, for example !*PDF*,*, to select every other printer.*no
max monitored printersMaximum number of matching printers to chart. 0 charts none; a negative value uses the default.100no

via File​

The configuration file name for this integration is netdata.conf. Configuration for this specific integration is located in the [plugin:windows:GetPrinters] section within that file.

The file format is a modified INI syntax. The general structure is:

[section1]
option1 = some value
option2 = some other value

[section2]
option3 = some third value

You can edit the configuration file using the edit-config script from the Netdata config directory.

cd /etc/netdata 2>/dev/null || cd /opt/netdata/etc/netdata
sudo ./edit-config netdata.conf
Examples​

There are no configuration examples.

Alerts​

There are no alerts configured by default for this integration.

Metrics​

Metrics grouped by scope.

The scope defines the instance that the metric belongs to. An instance is uniquely identified by a set of labels.

Per printer​

These metrics refer to one print queue.

Labels:

LabelDescription
printerThe full Windows printer name, including the server for printer connections.

Metrics:

MetricDescriptionDimensionsUnit
windows.printer_jobsPrinter queued jobsqueuedjobs
windows.printer_statusPrinter statusother, unknown, idle, printing, warmupstatus
windows.printer_problemsPrinter problemspaused, error, pending_deletion, paper_jam, paper_out, manual_feed, paper_problem, offline, output_bin_full, toner_low, no_toner, page_punt, user_intervention, out_of_memory, door_open, server_offline, driver_update_neededstatus
windows.printer_job_statusPrinter jobs by statuserror, degraded, ok, queued, unknownjobs

Do you have any feedback for this page? If so, you can open a new issue on our netdata/learn repository.