Supervision des imprimantes avec Centreon

Hello, je vous propose dans cet article la supervision des imprimantes compatible RFC 3805 (Printer MIB v2). Nous allons utiliser Centreon et ses plugins, Centreon Plugin Packs.

Ce qu’il vous faut :

Configuration à réaliser sur les imprimantes :

  • Activer SNMP via l’interface web ou directement sur l’imprimante.

KONICA MINOLTA 364E

Je vous donne un exemple détaillé. Commençons avec la supervision de cette imprimante, la Konica Minolta 364E. N’oubliez pas d’activer SNMP sur l’imprimante. 

Nous allons utiliser le plugin suivant :

[root@pixelabs centreon]#./centreon_plugins.pl --list-plugin | grep printer | grep PLUGIN
PLUGIN: hardware::printers::standard::rfc3805::plugin
[root@pixelabs centreon]#

Les modes disponibles :

[root@pixelabs centreon]# ./centreon_plugins.pl --plugin=hardware::printers::standard::rfc3805::plugin --list-mode

Konica Minolta 364e

Plugin Description:
[...]

Global Options:
    --mode  Choose a mode.

    --dyn-mode
            Specify a mode with the path (separated by '::').

    --list-mode
            List available modes.

    --mode-version
            Check minimal version of mode. If not, unknown error.

    --version
            Display plugin version.

    --pass-manager
            Use a password manager.

Modes Available:
   cover-status
   hardware-device
   marker-impression
   markersupply-usage
   papertray-usage
   printer-error
[root@pixelabs centreon]#

Check Covers Status

[root@centreon plugins]# ./centreon_plugins.pl --plugin=hardware::printers::standard::rfc3805::plugin --snmp-community=public --snmp-version=2 --mode=cover-status --hostname=konica --verbose
OK: All covers/interlocks are ok. |
Cover 'Front Door' status is closed
Cover 'Right-Side Door' status is closed
Cover 'Cabinet Side Door' status is closed
Cover 'Catch Tray Door' status is closed
Cover 'Finisher Front Door' status is closed
[root@centreon plugins]#

Commande Centreon Web : Configuration > Commandes > Contrôles :

$USER2$/centreon_plugins.pl --plugin=$_SERVICEPLUGIN$ --mode=$_SERVICEMODE$ --hostname=$HOSTADDRESS$ --snmp-community=$_HOSTSNMPCOMMUNITY$ --snmp-version=$_HOSTSNMPVERSION$ $_SERVICEOPTION$

Konica Centreon CommandCréation d’hôte IMP-SHARP (ou KONICA c’est la même chose) :

Sharp Centreon Host

Création de service Sharp-Covers-Status :

Konica Minotla Service

Il ne reste plus qu’à relancer le collecteur Central.

Check Hardware-device Status

[root@centreon plugins]# ./centreon_plugins.pl --plugin=hardware::printers::standard::rfc3805::plugin --snmp-community=public --snmp-version=2 --mode=hardware-device --hostname=konica --verbose
WARNING: Device 'KONICA MINOLTA bizhub 364e' status is 'warning' | 'count_device'=4;;;;
Checking devices
device 'KONICA MINOLTA bizhub 364e' status is 'warning' [instance = printer.1]
device 'KONICA MINOLTA bizhub 364e' status is 'running' [instance = other.2]
device 'Ethernet 10/100/1000 Base-T' status is 'running' [instance = network.3]
device 'HDD' status is 'running' [instance = diskStorage.4]
[root@centreon plugins]#

Commande Centreon Web : Configuration > Commandes > Contrôles :

$USER2$/centreon_plugins.pl --plugin=$_SERVICEPLUGIN$ --mode=$_SERVICEMODE$ --hostname=$HOSTADDRESS$ --snmp-community=$_HOSTSNMPCOMMUNITY$ --snmp-version=$_HOSTSNMPVERSION$ $_SERVICEOPTION$

Check Marker impression/sheets :

[root@centreon plugins]# ./centreon_plugins.pl --plugin=hardware::printers::standard::rfc3805::plugin --snmp-community=public --snmp-version=2 --mode=marker-impression --hostname=konica --warning=20 --critical=50 --verbose
OK: Marker impressions/sheets are ok. | 'impressions'=0;0:20;0:50;0;
Marker impressions '1#1': 0
[root@centreon plugins]#

Commande Centreon Web : Configuration > Commandes > Contrôles :

$USER2$/centreon_plugins.pl --plugin=$_SERVICEPLUGIN$ --mode=$_SERVICEMODE$ --hostname=$HOSTADDRESS$ --snmp-community=$_HOSTSNMPCOMMUNITY$ --snmp-version=$_HOSTSNMPVERSION$ --warning=$_SERVICEWARNING$ --critical=$_SERVICECRITICAL$ $_SERVICEOPTION$

Check Maker Supply Usage (All Instance)

Utilisation des cartouches d’encre, toutes les cartouches.

[root@centreon plugins]# ./centreon_plugins.pl --plugin=hardware::printers::standard::rfc3805::plugin --snmp-community=public --snmp-version=2 --mode=markersupply-usage --hostname=konica --warning='10:' --critical='5:' --verbose 
OK: Marker supply usages are ok. | 'Toner (Black)#black'=81.00%;10:;5:;0;100 'Drum Cartridge (Black)#black'=35.00%;10:;5:;0;100 'Developer Cartridge (Black)#black'=30.00%;10:;5:;0;100 'Fusing Unit'=30.00%;10:;5:;0;100 'Image Transfer Belt Unit'=74.00%;10:;5:;0;100 'Transfer Roller Unit'=83.00%;10:;5:;0;100 'Ozone Filter'=83.00%;10:;5:;0;100
Marker supply 'Toner (Black)': 81.00 % [instance: '1.1']
Marker supply 'Drum Cartridge (Black)': 35.00 % [instance: '1.2']
Marker supply 'Developer Cartridge (Black)': 30.00 % [instance: '1.3']
Skipping marker supply 'Waste Toner Box': no unit or not managed.
Marker supply 'Fusing Unit': 30.00 % [instance: '1.5']
Marker supply 'Image Transfer Belt Unit': 74.00 % [instance: '1.6']
Marker supply 'Transfer Roller Unit': 83.00 % [instance: '1.7']
Marker supply 'Ozone Filter': 83.00 % [instance: '1.8']
Skipping marker supply 'Staple Cartridge': no unit or not managed.
[root@centreon plugins]#

Commande Centreon Web : Configuration > Commandes > Contrôles :

$USER2$/centreon_plugins.pl --plugin=$_SERVICEPLUGIN$ --mode=$_SERVICEMODE$ --hostname=$HOSTADDRESS$ --snmp-community=$_HOSTSNMPCOMMUNITY$ --snmp-version=$_HOSTSNMPVERSION$ --warning=$_SERVICEWARNING$ --critical=$_SERVICECRITICAL$ $_SERVICEOPTION$

Check Maker Supply Usages (One Instance)

Utilisation des cartouches d’encre, une seule cartouche, ici : Marker supply ‘Toner (Black)’: 81.00 % [instance: ‘1.1’]

[root@centreon plugins]# ./centreon_plugins.pl --plugin=hardware::printers::standard::rfc3805::plugin --snmp-community=public --snmp-version=2 --mode=markersupply-usage --hostname=konica --warning='10:' --critical='5:' --filter='1.1' --verbose 
OK: Marker supply usages are ok. | 'Toner (Black)#black'=81.00%;10:;5:;0;100
Marker supply 'Toner (Black)': 81.00 % [instance: '1.1']
Skipping marker supply 'Drum Cartridge (Black)' (instance: 1.2): filter.
Skipping marker supply 'Developer Cartridge (Black)' (instance: 1.3): filter.
Skipping marker supply 'Waste Toner Box': no unit or not managed.
Skipping marker supply 'Fusing Unit' (instance: 1.5): filter.
Skipping marker supply 'Image Transfer Belt Unit' (instance: 1.6): filter.
Skipping marker supply 'Transfer Roller Unit' (instance: 1.7): filter.
Skipping marker supply 'Ozone Filter' (instance: 1.8): filter.
Skipping marker supply 'Staple Cartridge': no unit or not managed.
[root@centreon plugins]#

Commande Centreon Web : Configuration > Commandes > Contrôles :

$USER2$/centreon_plugins.pl --plugin=$_SERVICEPLUGIN$ --mode=$_SERVICEMODE$ --hostname=$HOSTADDRESS$ --snmp-community=$_HOSTSNMPCOMMUNITY$ --snmp-version=$_HOSTSNMPVERSION$ --warning=$_SERVICEWARNING$ --critical=$_SERVICECRITICAL$ --filter=$_SERVICEFILTER$ $_SERVICEOPTION$

Check Paper Trays Usages (All Trays)

Utilisation du papier sur tous les bacs

[root@centreon plugins]# ./centreon_plugins.pl --plugin=hardware::printers::standard::rfc3805::plugin --snmp-community=public --snmp-version=2 --mode=papertray-usage --hostname=konica --warning='10:' --critical='5:' --filter-tray='^Tray' --verbose
OK: Paper tray usages are ok. | 'tray_Tray 1'=100.00%;10:;5:;0;100 'tray_Tray 2'=100.00%;10:;5:;0;100 'tray_Tray 3'=33.32%;10:;5:;0;100
Paper tray 'Tray 1': 100.00 %
Paper tray 'Tray 2': 100.00 %
Paper tray 'Tray 3': 33.32 %
Skipping tray 'Bypass Tray': not matching filter.
[root@centreon plugins]#

Commande Centreon Web : Configuration > Commandes > Contrôles :

$USER2$/centreon_plugins.pl --plugin=$_SERVICEPLUGIN$ --mode=$_SERVICEMODE$ --hostname=$HOSTADDRESS$ --snmp-community=$_HOSTSNMPCOMMUNITY$ --snmp-version=$_HOSTSNMPVERSION$ --warning=$_SERVICEWARNING$ --critical=$_SERVICECRITICAL$ --filter-tray=$_SERVICEFILTER$ $_SERVICEOPTION$

Check Paper Trays Usages (One Tray)

Utilisation du papier sur un seul bac, ici Bac 2

[root@centreon plugins]# ./centreon_plugins.pl --plugin=hardware::printers::standard::rfc3805::plugin --snmp-community=public --snmp-version=2 --mode=papertray-usage --hostname=konica --warning='10:' --critical='5:' --filter-tray='^Tray 2$' --verbose 
OK: Paper tray usages are ok. | 'tray_Tray 2'=100.00%;10:;5:;0;100
Skipping tray 'Tray 1': not matching filter.
Paper tray 'Tray 2': 100.00 %
Skipping tray 'Tray 3': not matching filter.
Skipping tray 'Bypass Tray': not matching filter.
[root@centreon plugins]#

Commande Centreon Web : Configuration > Commandes > Contrôles :

$USER2$/centreon_plugins.pl --plugin=$_SERVICEPLUGIN$ --mode=$_SERVICEMODE$ --hostname=$HOSTADDRESS$ --snmp-community=$_HOSTSNMPCOMMUNITY$ --snmp-version=$_HOSTSNMPVERSION$ --warning=$_SERVICEWARNING$ --critical=$_SERVICECRITICAL$ --filter-tray=$_SERVICEFILTER$ $_SERVICEOPTION$

Check Printer Error Status

Vérifier les erreurs :

[root@centreon plugins]# ./centreon_plugins.pl --plugin=hardware::printers::standard::rfc3805::plugin --snmp-community=public --snmp-version=2 --mode=printer-error --hostname=konica --verbose
WARNING: Printer '1' status is 'low paper' |
checking printer '1'
    status is 'low paper'
[root@centreon plugins]#

Commande Centreon Web : Configuration > Commandes > Contrôles :

$USER2$/centreon_plugins.pl --plugin=$_SERVICEPLUGIN$ --mode=$_SERVICEMODE$ --hostname=$HOSTADDRESS$ --snmp-community=$_HOSTSNMPCOMMUNITY$ --snmp-version=$_HOSTSNMPVERSION$ $_SERVICEOPTION$

C’est terminé, nous avons utilisé tous les modes disponibles. Un autre exemple ci-dessous.

SHARP MX-M354N

J’adore cette marque <3  c’est parti avec la supervision de SHARPiiiii…MX-M354N. Les commandes sont les mêmes.

Check Covers Status

Sharp MX-M354N

[root@centreon plugins]# ./centreon_plugins.pl --plugin=hardware::printers::standard::rfc3805::plugin --snmp-community=public --snmp-version=2 --hostname=sharpi --mode=cover-status --verbose
OK: All covers/interlocks are ok. |
Cover 'Front Cover' status is closed
Cover 'Right Side Cover' status is closed
Cover 'Finisher Front Cover' status is closed
Cover 'Lower Right Side Cover' status is closed
Cover 'Desk Unit Cover' status is closed
Cover 'Desk Unit Cover' status is closed
[root@centreon plugins]#

Commande Centreon Web : Configuration > Commandes > Contrôles :

$USER2$/centreon_plugins.pl --plugin=$_SERVICEPLUGIN$ --mode=$_SERVICEMODE$ --hostname=$HOSTADDRESS$ --snmp-community=$_HOSTSNMPCOMMUNITY$ --snmp-version=$_HOSTSNMPVERSION$ $_SERVICEOPTION$

Check Hardware-device Status

[root@centreon plugins]# ./centreon_plugins.pl --plugin=hardware::printers::standard::rfc3805::plugin --snmp-community=public --snmp-version=2 --hostname=sharpi --mode=hardware-device --verbose
OK: All 12 components are ok [12/12 devices]. | 'count_device'=12;;;;
Checking devices
device 'SHARP MX-M354N' status is 'running' [instance = printer.1]
device 'USB Port' status is 'running' [instance = other.2]
device 'Ethernet Port' status is 'running' [instance = network.3]
device 'Copier' status is 'running' [instance = unknown.4]
device 'Multi-Functional Device' status is 'running' [instance = other.5]
device 'Hard Disk Drive' status is 'running' [instance = diskStorage.6]
device 'Scanner Unit' status is 'running' [instance = unknown.7]
device '2x500 Sheet Paper Drawer' status is 'running' [instance = unknown.8]
device 'Inner Finisher' status is 'running' [instance = unknown.9]
device 'PS3 Expansion Kit' status is 'running' [instance = other.10]
device 'Network Scanner' status is 'running' [instance = unknown.11]
device 'Color Expansion Kit' status is 'running' [instance = other.12]
[root@centreon plugins]#

Check Marker impression/sheets

Pas d’impression en cours…

[root@centreon plugins]# ./centreon_plugins.pl --plugin=hardware::printers::standard::rfc3805::plugin --snmp-community=public --snmp-version=2 --hostname=sharpi --mode=marker-impression --warning=10 --critical=20 --verbose
OK: Marker impressions/sheets are ok. | 'impressions'=0;0:10;0:20;0;
Marker impressions '1#1': 0
[root@centreon plugins]#

Si quelqu’un imprime plus de 20 copies d’un seul coup, l’alerte CRITICAL se déclenche, il faut le virer… au nom de la planète terre… #SaveThePlanet

Check Maker Supply Usage (All Instance)

[root@centreon plugins]# ./centreon_plugins.pl --plugin=hardware::printers::standard::rfc3805::plugin --snmp-community=public --snmp-version=2 --hostname=sharpi --mode=markersupply-usage --warning='10:' --critical='5:' --verbose
CRITICAL: Marker supply 'Waste Toner': 0.00 % - Marker supply 'Black Photoconductive Drum': 0.00 % - Marker supply 'Black Developer': 0.00 % | 'Black Toner#black'=75.00%;10:;5:;0;100 'Waste Toner'=0.00%;10:;5:;0;100 'Black Photoconductive Drum#black'=0.00%;10:;5:;0;100 'Black Developer#black'=0.00%;10:;5:;0;100
Marker supply 'Black Toner': 75.00 % [instance: '1.1']
Marker supply 'Waste Toner': 0.00 % [instance: '1.2']
Marker supply 'Black Photoconductive Drum': 0.00 % [instance: '1.3']
Marker supply 'Black Developer': 0.00 % [instance: '1.4']
Skipping marker supply 'Fusing Unit': level unknown.
[root@centreon plugins]#

Check Maker Supply Usages (One Instance)

Marker supply ‘Black Toner’: 75.00 % [instance: ‘1.1’]

[root@centreon plugins]# ./centreon_plugins.pl --plugin=hardware::printers::standard::rfc3805::plugin --snmp-community=public --snmp-version=2 --hostname=sharpi --mode=markersupply-usage --warning='10:' --critical='5:' --filter='1.1' --verbose
OK: Marker supply usages are ok. | 'Black Toner#black'=75.00%;10:;5:;0;100
Marker supply 'Black Toner': 75.00 % [instance: '1.1']
Skipping marker supply 'Waste Toner' (instance: 1.2): filter.
Skipping marker supply 'Black Photoconductive Drum' (instance: 1.3): filter.
Skipping marker supply 'Black Developer' (instance: 1.4): filter.
Skipping marker supply 'Fusing Unit': level unknown.
[root@centreon plugins]#

Commande Centreon Web : Configuration > Commandes > Contrôles :

$USER2$/centreon_plugins.pl --plugin=$_SERVICEPLUGIN$ --mode=$_SERVICEMODE$ --hostname=$HOSTADDRESS$ --snmp-community=$_HOSTSNMPCOMMUNITY$ --snmp-version=$_HOSTSNMPVERSION$ --warning=$_SERVICEWARNING$ --critical=$_SERVICECRITICAL$ --filter=$_SERVICEFILTER$ $_SERVICEOPTION$

Une fois la commande et l’hôte créées, on peut mettre en place le service :

Sharp Toner Service

Check Paper Trays Usages (All Trays)

Utilisation du papier sur tous les bacs :

[root@centreon plugins]# ./centreon_plugins.pl --plugin=hardware::printers::standard::rfc3805::plugin --snmp-community=public --snmp-version=2 --hostname=sharpi --mode=papertray-usage --warning='10:' --critical='5:' --filter-tray='^Tray' --verbose
CRITICAL: Paper tray 'Tray 3': 0.00 % | 'tray_Tray 3'=0.00%;10:;5:;0;100
Skipping tray 'Bypass Tray': not matching filter.
Tray 'Tray 1': no level but some space remaining.
Tray 'Tray 2': no level but some space remaining.
Paper tray 'Tray 3': 0.00 %
Tray 'Tray 4': no level but some space remaining.
Skipping tray 'Auto Select': not matching filter.
[root@centreon plugins]#

Check Paper Trays Usages (One Tray)

Utilisation du papier sur une seul bac :  Bac 3

[root@centreon plugins]# ./centreon_plugins.pl --plugin=hardware::printers::standard::rfc3805::plugin --snmp-community=public --snmp-version=2 --hostname=sharpi --mode=papertray-usage --warning='10:' --critical='5:' --filter-tray='^Tray 3$' --verbose
CRITICAL: Paper tray 'Tray 3': 0.00 % | 'tray_Tray 3'=0.00%;10:;5:;0;100
Skipping tray 'Bypass Tray': not matching filter.
Skipping tray 'Tray 1': not matching filter.
Skipping tray 'Tray 2': not matching filter.
Paper tray 'Tray 3': 0.00 %
Skipping tray 'Tray 4': not matching filter.
Skipping tray 'Auto Select': not matching filter.
[root@centreon plugins]#

Check Printer Error Status

[root@centreon plugins]# ./centreon_plugins.pl --plugin=hardware::printers::standard::rfc3805::plugin --snmp-community=public --snmp-version=2 --hostname=sharpi --mode=printer-error --verbose
OK: Printer '1' status is 'ok' |
checking printer '1'
    status is 'ok'
[root@centreon plugins]#

Lexmark CS510

Supervision Toner usage :

[root@centreon plugins]# ./centreon_plugins.pl --plugin=hardware::printers::standard::rfc3805::plugin --snmp-community=public --snmp-version=2 --hostname=lexmark --mode=markersupply-usage --warning='10:' --critical='5:' --verbose
OK: Marker supply usages are ok. | [...]
Marker supply 'Cartouche cyan': no level but some space remaining.
Marker supply 'Cartouche magenta': no level but some space remaining.
Marker supply 'Cartouche jaune': 90.00 % [instance: '1.3']
Marker supply 'Cartouche noire': 30.00 % [instance: '1.4']
Marker supply 'Bouteille récup. toner': 100.00 % [instance: '1.5']
Marker supply 'Unité de fusion': 100.00 % [instance: '1.6']
Marker supply 'ITU': 100.00 % [instance: '1.7']
Marker supply 'Kit trait. image': 50.00 % [instance: '1.8']
Marker supply 'Kit maintenance': 80.00 % [instance: '1.9']
[root@centreon plugins]#

HP LaserJet MFP M527

Supervision HP LaserJet MFP M527 Toner usage :

[root@centreon plugins]# ./centreon_plugins.pl --plugin=hardware::printers::standard::rfc3805::plugin --snmp-community=public --snmp-version=2 --hostname=hp-laserjet --mode=markersupply-usage --warning='10:' --critical='5:' --verbose
OK: Marker supply usages are ok. | [...]
Marker supply 'Cartouche de noir 87A HP CF287A': 35.00 % [instance: '1.1']
Marker supply 'Kit alimentation document HP B5L52A': 100.00 % [instance: '1.2']
Marker supply 'Nettoyer les rouleaux HP None': 99.00 % [instance: '1.3']
[root@centreon plugins]#

Epson WF-8090

Supervision Epson WF-8090 Toner usage :

[root@centreon plugins]# ./centreon_plugins.pl --plugin=hardware::printers::standard::rfc3805::plugin --snmp-community=public --snmp-version=2 --hostname=epson --mode=markersupply-usage --warning='10:' --critical='5:' --verbose
OK: Marker supply usages are ok. | [...]
Marker supply 'Black Ink Cartridge T7561/T7551/T7541': 26.00 % [instance: '1.1']
Marker supply 'Cyan Ink Cartridge T7562/T7552/T7542': 67.00 % [instance: '1.2']
Marker supply 'Magenta Ink Cartridge T7563/T7553/T7543': 40.00 % [instance: '1.3']
Marker supply 'Yellow Ink Cartridge T7564/T7554/T7544': 52.00 % [instance: '1.4']
[root@centreon plugins]#

TOSHIBA e-STUDIO3508A

Supervision TOSHIBA e-STUDIO3508A Toner usage :

[root@centreon plugins]# ./centreon_plugins.pl --plugin=hardware::printers::standard::rfc3805::plugin --snmp-community=public --snmp-version=2 --hostname=toshiba --mode=markersupply-usage --warning='10:' --critical='5:' --verbose
OK: Marker supply usages are ok. | [...]
Marker supply 'Black Toner': 55.00 % [instance: '1.1']
Marker supply 'Waste Toner': no level but some space remaining.
[root@centreon plugins]#

Supervision TOSHIBA e-STUDIO3508A Papertray usage :

[root@centreon plugins]# ./centreon_plugins.pl --plugin=hardware::printers::standard::rfc3805::plugin --snmp-community=public --snmp-version=2 --hostname=toshiba --mode=papertray-usage --warning='10:' --critical='5:' --verbose
CRITICAL: Paper tray 'Bypass Tray': 0.00 % WARNING: Paper tray 'Drawer 1': 9.09 % | [...]
Paper tray 'Drawer 1': 9.09 %
Paper tray 'Drawer 2': 13.64 %
Paper tray 'Large Capacity Feeder': 10.00 %
Paper tray 'Bypass Tray': 0.00 %
Paper tray 'Large Capacity Feeder': 10.00 %
[root@centreon plugins]#

C’est terminé les amis. C’est la même chose pour les autres imprimantes compatible RFC 3805. À vous de jouer !

Bonne journée et à très bientôt.

 
Besoin d’aide ? des questions ?

Venez sur le forum
logo Forum Pixelabs
***********
La rédaction de cette documentation demande beaucoup de temps, de motivation, mais surtout beaucoup de café 🙂

Vous aimez pixelabs ?

Offrez moi un petit café en cliquant sur la tasse ci-dessous.
pixelans_donation
Merci !

1 réponse

  1. pixelabs dit :

    Mise à jour de l’article.