Closed Giudy closed 1 year ago
Hi @Giudy
firstly, SNMPv2-MIB::sysName.0
seems empty in your walk. Maybe this is the reason. You should check if you can edit the printer configuration to set its "sysName".
Hi, after setting the printer name it now gets some XML, but not the MAC address nor the serial number. The serial number is not shown on the snmpwalk, but the MAC is, what should we do for it to show up?
[debug] Logger backend Stderr initialized
[debug] GLPI Agent (1.5-git75728309)
[info] Can't load Net::NBName, netbios can't be used
[debug] initializing job 1
[debug] initializing block 192.168.99.70-192.168.99.70
[debug] Current run expiration timeout: soon
[debug] creating 1 worker threads
[debug] [thread 1] creation
[debug] [thread 1] glpi-project/sysobject.ids#1, scanning 192.168.99.70
[debug] [thread 1] glpi-project/sysobject.ids#1, full match for sysobjectID .1.3.6.1.4.1.1602.4.3 in database
[debug] [thread 1] glpi-project/sysobject.ids#1, - scanning 192.168.99.70 with SNMP, credentials 1: success
[debug] [thread 1] glpi-project/sysobject.ids#1, - scanning 192.168.99.70 with echo ping: no result
[debug] [thread 1] glpi-project/sysobject.ids#1, - scanning 192.168.99.70 in arp table: no result
<?xml version="1.0" encoding="UTF-8"?>
<REQUEST>
<CONTENT>
<DEVICE>
<AUTHSNMP>1</AUTHSNMP>
<DESCRIPTION>Canon TM-300 /P</DESCRIPTION>
<IP>192.168.99.70</IP>
<IPS>
<IP>192.168.99.70</IP>
</IPS>
<MANUFACTURER>Canon</MANUFACTURER>
<MODEL>Canon TM-300</MODEL>
<SNMPHOSTNAME>Plotter Engineering</SNMPHOSTNAME>
<TYPE>PRINTER</TYPE>
<UPTIME>13 minutes, 31.00</UPTIME>
</DEVICE>
<MODULEVERSION>5.1</MODULEVERSION>
<PROCESSNUMBER>1</PROCESSNUMBER>
</CONTENT>
<DEVICEID>foo</DEVICEID>
<QUERY>NETDISCOVERY</QUERY>
</REQUEST>
[debug] [thread 1] termination
[debug] All netdiscovery threads terminated
Hi @sghebuz
I moved your issue to the proper repository.
Nice to see you just had to set a proper name on the device to still have a better detection.
Setting the SNMPv2-MIB::sysName.0
to what you seem to have set I can use glpi-netinventory
script to produce:
<?xml version="1.0" encoding="UTF-8"?>
<REQUEST>
<CONTENT>
<DEVICE>
<CARTRIDGES>
<CARTRIDGEBLACK>100</CARTRIDGEBLACK>
<CARTRIDGECYAN>100</CARTRIDGECYAN>
<CARTRIDGEMAGENTA>100</CARTRIDGEMAGENTA>
<CARTRIDGEMATTE>100</CARTRIDGEMATTE>
<CARTRIDGEYELLOW>100</CARTRIDGEYELLOW>
<WASTETONER>80</WASTETONER>
</CARTRIDGES>
<INFO>
<COMMENTS>Canon TM-300 /P</COMMENTS>
<ID>0</ID>
<MANUFACTURER>Canon</MANUFACTURER>
<MODEL>Canon TM-300</MODEL>
<NAME>Plotter Engineering</NAME>
<TYPE>PRINTER</TYPE>
</INFO>
<PAGECOUNTERS>
<TOTAL>760</TOTAL>
</PAGECOUNTERS>
<PORTS>
<PORT>
<IFDESCR>Canon NB-20GB 1.0</IFDESCR>
<IFNAME>Canon NB-20GB 1.0</IFNAME>
<IFNUMBER>1</IFNUMBER>
<IFSPEED>1000000000</IFSPEED>
<IFTYPE>6</IFTYPE>
<MAC>74:38:b7:c9:51:70</MAC>
</PORT>
<PORT>
<IFDESCR>Canon NB-20GB 1.0</IFDESCR>
<IFNAME>Canon NB-20GB 1.0</IFNAME>
<IFNUMBER>2</IFNUMBER>
<IFSPEED>0</IFSPEED>
<IFTYPE>6</IFTYPE>
<MAC>f8:a2:6d:41:c5:e1</MAC>
</PORT>
</PORTS>
</DEVICE>
<MODULEVERSION>5.1</MODULEVERSION>
<PROCESSNUMBER>1</PROCESSNUMBER>
</CONTENT>
<DEVICEID>foo</DEVICEID>
<QUERY>SNMPQUERY</QUERY>
</REQUEST>
So yes, mac address is missing. Without serial the device can't be imported so.
With the walk we can see there's 2 ports. But it seems the agent can't decide which mac address to use. Can you still confirm which one is the right one ? I guess this is 74:38:b7:c9:51:70
as we detect a port speed.
Anyway, there's not enough information in the walk. Can you still try to use the command proposed there to produce a walk in the right format and maybe with more information: snmpwalk output for bug reporting
Hi, yes 74:38:b7:c9:51:70
is the correct MAC address, I saw that the printer have also a wireless card, maybe the other MAC is of the wireless card.
Please see attached the snmpwak in debug mode, I run it in v1 and v3
The serial number of this machine is BALB28472
but I can't find it anywere on the snmpwalk. Probably it's only in the proprietary mibs... https://developers.canon-europe.com/s/mib
walk-tm300.txt
walk-tm300-snmpv3.txt
Nice, I see the S/N in private OIDs. We will be able to add its support. I see we should be able also to support firmware version. For the mac, I'm not sure this can be solved safely but with the S/N this becomes not important as S/N is sufficient to import the device. I guess too the second port is the wireless card.
that is great, let me know if there is anything else we can do from our side. thanks!
For now, I need to wait at least 24h before having access to MIBs. I need so to verify what I can really use safely. So I'll investigate to enhance Canon support on monday.
Hi @sghebuz next nightly build should give you a plain support for your printer.
work perfectly thanks a lot!
Hello we have an issue with the printer Canon TM-300 It does find, partially, the manufacturer but it is not imported as no xml is fetched.
here the usual commands report
davide
Here the snmpwalk result: