Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Incorrect toner levels #4177

Closed
realnakrul opened this issue Aug 23, 2016 · 9 comments
Closed

Incorrect toner levels #4177

realnakrul opened this issue Aug 23, 2016 · 9 comments

Comments

@realnakrul
Copy link

Hi
We have Ricoh MP C2051 and the toner level is incorrect. Could somebody fix it, please?
./discovery.php -h HOSTNAME -d -m os
http://pastebin.com/6bABk8bj
./discovery.php -h HOSTNAME -d -m toner
http://pastebin.com/a7pbYjP9
./poller.php -h HOSTNAME -r -f -d -m toner
http://pastebin.com/7v7TesNG
snmpbulkwalk -On -v2c -c COMMUNITY HOSTNAME
http://pastebin.com/3hvtkwiU

Also is it possible to add printed pages count device page? Can I do it without coding? I am new to LibreNMS...
Thanks in advance.

@crcro
Copy link
Contributor

crcro commented Aug 23, 2016

@realnakrul
unfortunately the docs from ricoh states that -3 is returned for anything between 1-100% of toner level and -100 when toner is empty, so nothing real can get out for this ricoh model

@realnakrul
Copy link
Author

Dear Crcro
Thank you for your reply, but I can get correct toner levels from the following OIDs:
2453: enterprises.367.3.2.1.2.24.1.1.2.1 Black Toner
2454: enterprises.367.3.2.1.2.24.1.1.2.2 Cyan Toner
2455: enterprises.367.3.2.1.2.24.1.1.2.3 Magenta Toner
2456: enterprises.367.3.2.1.2.24.1.1.2.4 Yellow Toner
2457: enterprises.367.3.2.1.2.24.1.1.3.1 Black Toner
2458: enterprises.367.3.2.1.2.24.1.1.3.2 Cyan Toner
2459: enterprises.367.3.2.1.2.24.1.1.3.3 Magenta Toner
2460: enterprises.367.3.2.1.2.24.1.1.3.4 Yellow Toner
2465: enterprises.367.3.2.1.2.24.1.1.5.1 90
2466: enterprises.367.3.2.1.2.24.1.1.5.2 20
2467: enterprises.367.3.2.1.2.24.1.1.5.3 20
2468: enterprises.367.3.2.1.2.24.1.1.5.4 100
I compared them to levels from printer web GUI and they are OK
capture

@crcro
Copy link
Contributor

crcro commented Aug 24, 2016

hmm they are using different oids ... will code a fix and push it soon

@realnakrul PR merged, can you please test it and leave some feedback

@realnakrul
Copy link
Author

Dear Crcro
Sorry for late reply.
Fix doesn't work :(

date
Sun Aug 28 10:34:18 GST 2016
git status
On branch master
Your branch is up-to-date with 'origin/master'.
nothing to commit, working directory clean

./discovery.php -h HOSTNAME -d -m toner
http://pastebin.com/WtYFFRKQ - it still shows original OIDs... Probably os is not ricoh, but nrg. I tried to change it myself, but no luck. I am not skilled in PHP...

@crcro
Copy link
Contributor

crcro commented Aug 29, 2016

@realnakrul ... new code submitted, please rediscover your device and leave some feedback, thanks.

@realnakrul
Copy link
Author

Dear Crcro
Thank you for update. It's getting better, but not working properly yet. I can see correct toner names on the device LibreNMS page, but all levels are zero.
zero
./poller.php -h HOSTNAME -r -f -d -m toner
http://pastebin.com/qPYWWLHV

@realnakrul
Copy link
Author

Dear Crcro
I tried your fix from PR #4273. It doesn't work. I think the issue is in polled OIDs. For example:

Load poller module toner

SQL[SELECT * FROM toner WHERE device_id = '10'] Checking toner Black Toner... /usr/bin/snmpget -v2c -c COMMUNITY -OUqnv -M /opt/librenms/mibs udp:HOSTNAME:161 .1.3.6.1.4.1.367.3.2.1.2.24.1.1.5.190
INF %

But OID should be enterprises.367.3.2.1.2.24.1.1.5.1
Something wrong with $toner_oid = ".1.3.6.1.4.1.367.3.2.1.2.24.1.1.5.$index"; Probably... I am not skilled with PHP...

@crcro
Copy link
Contributor

crcro commented Aug 30, 2016

@realnakrul ... that $index is getting the value: 1:

SQL[SELECT * FROM toner WHERE device_id = '10'] Checking toner Black Toner... /usr/bin/snmpget -v2c -c COMMUNITY -OUqnv -M /opt/librenms/mibs udp:HOSTNAME:161 .1.3.6.1.4.1.367.3.2.1.2.24.1.1.5.1 = 90%
INF %

i've pushed another fix for polling

laf pushed a commit that referenced this issue Sep 4, 2016
fix: ricoh/nrg toner levels #4177
@laf
Copy link
Member

laf commented Sep 4, 2016

Fixed in #4273

@laf laf closed this as completed Sep 4, 2016
@lock lock bot locked as resolved and limited conversation to collaborators May 19, 2018
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants