Available versions




impressoras SIMPRESS

Overview

Script e Template criados para monitorar niveis de toner em impressoras samsung.

Script em php

Template via Zabbix

#!/usr/bin/php

php</p if($argc!=3){

echo “Número de parametros invalido!\n”;

echo “Use: “.$argv[0].” \n”;

exit(0);

}

$host=$argv[1];

$cor=$argv[2];

$cmd=”snmpwalk -c public -v1 “.$host.” .1.3.6.1.2.1.43.11.1.1.6.1 grep ‘”.$cor.” Toner Cartridge’”;

$resp=exec($cmd);

if($resp!=’’){

$aux=explode(“ “,$resp);

$aux2=explode(“.”,$aux[0]);

$id_cor=end($aux2);

$cmd_maxi_toner=”snmpwalk -c public -v1 “.$host.” .1.3.6.1.2.1.43.11.1.1.8.1.”.$id_cor;

$cmd_disp_toner=”snmpwalk -c public -v1 “.$host.” .1.3.6.1.2.1.43.11.1.1.9.1.”.$id_cor;

$resp=exec($cmd_maxi_toner);

$aux3=explode(“ “,$resp);

$resp_maxi=$aux3[3];

$resp=exec($cmd_disp_toner);

$aux4=explode(“ “,$resp);

$resp_disp=$aux4[3];

$total_disp_perc=($resp_disp/$resp_maxi)*100;

echo $total_disp_perc.”\n”;

}else echo “Cor nao definida!\n”;

?>

Criação : Paulo Ricardo Carneiro Abrahão e Ana Flávia Sousa Qbar

Macros used

There are no macros links in this template.

There are no template links in this template.

Discovery rules

There are no discovery rules in this template.

Items collected

Name Description Type Key and additional info
Nivel Toner Rosa <p>-</p> External check NivelToner.php[“{HOST.NAME}”,”Magenta”]<p>Update: 14400</p>
Nivel Toner Azul <p>-</p> External check NivelToner.php[“{HOST.NAME}”,”Cyan”]<p>Update: 14400</p>
Nivel Toner Preto <p>-</p> External check NivelToner.php[“{HOST.NAME}”,”Black”]<p>Update: 14400</p>
Nivel Toner Amarelo <p>-</p> External check NivelToner.php[“{HOST.NAME}”,”Yellow”]<p>Update: 14400</p>

Triggers

There are no triggers in this template.

impressoras SIMPRESS

Overview

Script e Template criados para monitorar niveis de toner em impressoras samsung.

Script em php

Template via Zabbix

#!/usr/bin/php

php</p if($argc!=3){

echo “Número de parametros invalido!\n”;

echo “Use: “.$argv[0].” \n”;

exit(0);

}

$host=$argv[1];

$cor=$argv[2];

$cmd=”snmpwalk -c public -v1 “.$host.” .1.3.6.1.2.1.43.11.1.1.6.1 grep ‘”.$cor.” Toner Cartridge’”;

$resp=exec($cmd);

if($resp!=’’){

$aux=explode(“ “,$resp);

$aux2=explode(“.”,$aux[0]);

$id_cor=end($aux2);

$cmd_maxi_toner=”snmpwalk -c public -v1 “.$host.” .1.3.6.1.2.1.43.11.1.1.8.1.”.$id_cor;

$cmd_disp_toner=”snmpwalk -c public -v1 “.$host.” .1.3.6.1.2.1.43.11.1.1.9.1.”.$id_cor;

$resp=exec($cmd_maxi_toner);

$aux3=explode(“ “,$resp);

$resp_maxi=$aux3[3];

$resp=exec($cmd_disp_toner);

$aux4=explode(“ “,$resp);

$resp_disp=$aux4[3];

$total_disp_perc=($resp_disp/$resp_maxi)*100;

echo $total_disp_perc.”\n”;

}else echo “Cor nao definida!\n”;

?>

Criação : Paulo Ricardo Carneiro Abrahão e Ana Flávia Sousa Qbar

Macros used

There are no macros links in this template.

There are no template links in this template.

Discovery rules

There are no discovery rules in this template.

Items collected

Name Description Type Key and additional info
Nivel Toner Rosa <p>-</p> External check NivelToner.php[“{HOST.NAME}”,”Magenta”]<p>Update: 14400</p>
Nivel Toner Azul <p>-</p> External check NivelToner.php[“{HOST.NAME}”,”Cyan”]<p>Update: 14400</p>
Nivel Toner Preto <p>-</p> External check NivelToner.php[“{HOST.NAME}”,”Black”]<p>Update: 14400</p>
Nivel Toner Amarelo <p>-</p> External check NivelToner.php[“{HOST.NAME}”,”Yellow”]<p>Update: 14400</p>

Triggers

There are no triggers in this template.

impressoras SIMPRESS

Overview

Script e Template criados para monitorar niveis de toner em impressoras samsung.

Script em php

Template via Zabbix

#!/usr/bin/php

php</p if($argc!=3){

echo “Número de parametros invalido!\n”;

echo “Use: “.$argv[0].” \n”;

exit(0);

}

$host=$argv[1];

$cor=$argv[2];

$cmd=”snmpwalk -c public -v1 “.$host.” .1.3.6.1.2.1.43.11.1.1.6.1 grep ‘”.$cor.” Toner Cartridge’”;

$resp=exec($cmd);

if($resp!=’’){

$aux=explode(“ “,$resp);

$aux2=explode(“.”,$aux[0]);

$id_cor=end($aux2);

$cmd_maxi_toner=”snmpwalk -c public -v1 “.$host.” .1.3.6.1.2.1.43.11.1.1.8.1.”.$id_cor;

$cmd_disp_toner=”snmpwalk -c public -v1 “.$host.” .1.3.6.1.2.1.43.11.1.1.9.1.”.$id_cor;

$resp=exec($cmd_maxi_toner);

$aux3=explode(“ “,$resp);

$resp_maxi=$aux3[3];

$resp=exec($cmd_disp_toner);

$aux4=explode(“ “,$resp);

$resp_disp=$aux4[3];

$total_disp_perc=($resp_disp/$resp_maxi)*100;

echo $total_disp_perc.”\n”;

}else echo “Cor nao definida!\n”;

?>

Criação : Paulo Ricardo Carneiro Abrahão e Ana Flávia Sousa Qbar

Macros used

There are no macros links in this template.

There are no template links in this template.

Discovery rules

There are no discovery rules in this template.

Items collected

Name Description Type Key and additional info
Nivel Toner Rosa <p>-</p> External check NivelToner.php[“{HOST.NAME}”,”Magenta”]<p>Update: 14400</p>
Nivel Toner Azul <p>-</p> External check NivelToner.php[“{HOST.NAME}”,”Cyan”]<p>Update: 14400</p>
Nivel Toner Preto <p>-</p> External check NivelToner.php[“{HOST.NAME}”,”Black”]<p>Update: 14400</p>
Nivel Toner Amarelo <p>-</p> External check NivelToner.php[“{HOST.NAME}”,”Yellow”]<p>Update: 14400</p>

Triggers

There are no triggers in this template.