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

CiscoSB - Macsuck not working #526

Open
nvmike opened this issue Jun 10, 2024 · 20 comments
Open

CiscoSB - Macsuck not working #526

nvmike opened this issue Jun 10, 2024 · 20 comments

Comments

@nvmike
Copy link

nvmike commented Jun 10, 2024

Expected Behavior

Macksuck returning error

Current Behavior

[3871942] 2024-06-10 07:02:55 info App::Netdisco version 2.076005 loaded.
[3871942] 2024-06-10 07:02:55 info macsuck: [192.168.111.1] started at Mon Jun 10 10:02:55 2024
[3871942] 2024-06-10 07:02:56 debug macsuck: running with timeout 600s
[3871942] 2024-06-10 07:02:56 debug //// CHECK \\ phase
[3871942] 2024-06-10 07:02:56 debug � worker Internal::BackendFQDN p1000000
[3871942] 2024-06-10 07:02:56 debug � worker Internal::SNMPFastDiscover p1000000
[3871942] 2024-06-10 07:02:56 debug running with configured SNMP timeouts
[3871942] 2024-06-10 07:02:56 debug � worker Macsuck p0
[3871942] 2024-06-10 07:02:56 debug � (done) Macsuck is able to run.
[3871942] 2024-06-10 07:02:56 debug //// EARLY \\ phase
[3871942] 2024-06-10 07:02:56 debug � worker Macsuck::Nodes p0 "prepare common data"
[3871942] 2024-06-10 07:02:56 debug //// MAIN \\ phase
[3871942] 2024-06-10 07:02:56 debug � worker Macsuck::InterfacesStatus p100 "gather interfaces status from snmp"
[3871942] 2024-06-10 07:02:56 debug snmp reader cache warm: [192.168.111.1]
[3871942] 2024-06-10 07:02:56 debug [192.168.111.1:161] try_connect with v: 2, t: 0.2, r: 0, class: SNMP::Info::Layer2::CiscoSB, comm:
SNMP::Info::_global uptime : DISMAN-EVENT-MIB::sysUpTimeInstance : .1.3.6.1.2.1.1.3.0
SNMP::Info::_global layers : SNMPv2-MIB::sysServices.0 : .1.3.6.1.2.1.1.7.0
SNMP::Info::_global description : SNMPv2-MIB::sysDescr.0 : .1.3.6.1.2.1.1.1.0
SNMP::Info::_global id : SNMPv2-MIB::sysObjectID.0 : .1.3.6.1.2.1.1.2.0
SNMP::Info 3.970001
SNMP::Info::device_type() layers:01001111 id:9 sysDescr:"48-Port Gigabit PoE Smart Switch"
SNMP::Info 3.970001
SNMP::Info::device_type() layers:01001111 id:9 sysDescr:"48-Port Gigabit PoE Smart Switch"
SNMP::Info::_load_attr i_name : IF-MIB::ifName : .1.3.6.1.2.1.31.1.1.1.1
SNMP::Info::_load_attr i_up : IF-MIB::ifOperStatus : .1.3.6.1.2.1.2.2.1.8
SNMP::Info::_load_attr i_up_admin : IF-MIB::ifAdminStatus : .1.3.6.1.2.1.2.2.1.7
[3871942] 2024-06-10 07:02:57 debug [192.168.111.1] macsuck - updating port GigabitEthernet41 status : up/up
[3871942] 2024-06-10 07:02:57 debug [192.168.111.1] macsuck - updating port GigabitEthernet36 status : up/up
[3871942] 2024-06-10 07:02:57 debug [192.168.111.1] macsuck - updating port GigabitEthernet17 status : up/up
[3871942] 2024-06-10 07:02:57 debug [192.168.111.1] macsuck - updating port GigabitEthernet30 status : up/down
[3871942] 2024-06-10 07:02:57 debug [192.168.111.1] macsuck - updating port GigabitEthernet35 status : up/down
[3871942] 2024-06-10 07:02:57 debug [192.168.111.1] macsuck - updating port GigabitEthernet4 status : up/down
[3871942] 2024-06-10 07:02:57 debug [192.168.111.1] macsuck - updating port GigabitEthernet14 status : up/down
[3871942] 2024-06-10 07:02:57 debug [192.168.111.1] macsuck - updating port GigabitEthernet7 status : up/down
[3871942] 2024-06-10 07:02:57 debug [192.168.111.1] macsuck - updating port GigabitEthernet3 status : up/down
[3871942] 2024-06-10 07:02:57 debug [192.168.111.1] macsuck - updating port GigabitEthernet52 status : up/down
[3871942] 2024-06-10 07:02:57 debug [192.168.111.1] macsuck - updating port GigabitEthernet6 status : up/up
[3871942] 2024-06-10 07:02:57 debug [192.168.111.1] macsuck - updating port GigabitEthernet22 status : up/up
[3871942] 2024-06-10 07:02:57 debug [192.168.111.1] macsuck - updating port GigabitEthernet40 status : up/up
[3871942] 2024-06-10 07:02:57 debug [192.168.111.1] macsuck - updating port GigabitEthernet46 status : up/up
[3871942] 2024-06-10 07:02:57 debug [192.168.111.1] macsuck - updating port GigabitEthernet31 status : up/down
[3871942] 2024-06-10 07:02:57 debug [192.168.111.1] macsuck - updating port GigabitEthernet45 status : up/up
[3871942] 2024-06-10 07:02:57 debug [192.168.111.1] macsuck - updating port GigabitEthernet24 status : up/up
[3871942] 2024-06-10 07:02:57 debug [192.168.111.1] macsuck - updating port GigabitEthernet48 status : up/up
[3871942] 2024-06-10 07:02:57 debug [192.168.111.1] macsuck - updating port GigabitEthernet27 status : up/down
[3871942] 2024-06-10 07:02:57 debug [192.168.111.1] macsuck - updating port GigabitEthernet8 status : up/down
[3871942] 2024-06-10 07:02:57 debug [192.168.111.1] macsuck - updating port GigabitEthernet39 status : up/up
[3871942] 2024-06-10 07:02:57 debug [192.168.111.1] macsuck - updating port GigabitEthernet43 status : up/up
[3871942] 2024-06-10 07:02:57 debug [192.168.111.1] macsuck - updating port GigabitEthernet12 status : up/down
[3871942] 2024-06-10 07:02:57 debug [192.168.111.1] macsuck - updating port GigabitEthernet49 status : up/down
[3871942] 2024-06-10 07:02:57 debug [192.168.111.1] macsuck - updating port GigabitEthernet38 status : up/down
[3871942] 2024-06-10 07:02:57 debug [192.168.111.1] macsuck - updating port GigabitEthernet33 status : up/up
[3871942] 2024-06-10 07:02:57 debug [192.168.111.1] macsuck - updating port GigabitEthernet44 status : up/up
[3871942] 2024-06-10 07:02:57 debug [192.168.111.1] macsuck - updating port GigabitEthernet1 status : up/up
[3871942] 2024-06-10 07:02:57 debug [192.168.111.1] macsuck - updating port GigabitEthernet47 status : up/up
[3871942] 2024-06-10 07:02:57 debug [192.168.111.1] macsuck - updating port GigabitEthernet28 status : up/up
[3871942] 2024-06-10 07:02:57 debug [192.168.111.1] macsuck - updating port GigabitEthernet11 status : up/down
[3871942] 2024-06-10 07:02:57 debug [192.168.111.1] macsuck - updating port GigabitEthernet23 status : up/up
[3871942] 2024-06-10 07:02:57 debug [192.168.111.1] macsuck - updating port GigabitEthernet29 status : up/up
[3871942] 2024-06-10 07:02:57 debug [192.168.111.1] macsuck - updating port GigabitEthernet10 status : up/up
[3871942] 2024-06-10 07:02:57 debug [192.168.111.1] macsuck - updating port GigabitEthernet37 status : up/down
[3871942] 2024-06-10 07:02:57 debug [192.168.111.1] macsuck - updating port GigabitEthernet16 status : up/down
[3871942] 2024-06-10 07:02:57 debug [192.168.111.1] macsuck - updating port GigabitEthernet15 status : up/up
[3871942] 2024-06-10 07:02:57 debug [192.168.111.1] macsuck - updating port GigabitEthernet9 status : up/down
[3871942] 2024-06-10 07:02:57 debug [192.168.111.1] macsuck - updating port GigabitEthernet34 status : up/up
[3871942] 2024-06-10 07:02:57 debug [192.168.111.1] macsuck - updating port GigabitEthernet18 status : up/down
[3871942] 2024-06-10 07:02:57 debug [192.168.111.1] macsuck - updating port GigabitEthernet21 status : up/down
[3871942] 2024-06-10 07:02:57 debug [192.168.111.1] macsuck - updating port GigabitEthernet5 status : up/down
[3871942] 2024-06-10 07:02:57 debug [192.168.111.1] macsuck - updating port GigabitEthernet32 status : up/down
[3871942] 2024-06-10 07:02:57 debug [192.168.111.1] macsuck - updating port GigabitEthernet13 status : up/down
[3871942] 2024-06-10 07:02:57 debug [192.168.111.1] macsuck - updating port GigabitEthernet2 status : up/down
[3871942] 2024-06-10 07:02:57 debug [192.168.111.1] macsuck - updating port GigabitEthernet51 status : up/down
[3871942] 2024-06-10 07:02:57 debug [192.168.111.1] macsuck - updating port GigabitEthernet50 status : up/down
[3871942] 2024-06-10 07:02:57 debug [192.168.111.1] macsuck - updating port GigabitEthernet19 status : up/up
[3871942] 2024-06-10 07:02:57 debug [192.168.111.1] macsuck - updating port GigabitEthernet20 status : up/down
[3871942] 2024-06-10 07:02:57 debug [192.168.111.1] macsuck - updating port GigabitEthernet42 status : up/down
[3871942] 2024-06-10 07:02:57 debug [192.168.111.1] macsuck - updating port GigabitEthernet26 status : up/up
[3871942] 2024-06-10 07:02:57 debug [192.168.111.1] macsuck - updating port GigabitEthernet25 status : up/down
[3871942] 2024-06-10 07:02:57 debug � (info) interfaces status from snmp complete
[3871942] 2024-06-10 07:02:57 debug � worker Macsuck::Nodes p1000000 "gather macs from file"
[3871942] 2024-06-10 07:02:57 debug � (info) skip: fwtable data supplied by other source
[3871942] 2024-06-10 07:02:57 debug � worker Macsuck::Nodes p200 "gather macs from CLI"
[3871942] 2024-06-10 07:02:57 debug � (info) skip: driver or action not applicable
[3871942] 2024-06-10 07:02:57 debug � worker Macsuck::Nodes p100 "gather macs from snmp"
SNMP::Info::_load_attr qb_fw_port : Q-BRIDGE-MIB::dot1qTpFdbPort : .1.3.6.1.2.1.17.7.1.2.2.1.2
SNMP::Info::_load_attr dot1qVlanFdbId : Q-BRIDGE-MIB::dot1qVlanFdbId : .1.3.6.1.2.1.17.7.1.4.2.1.3
SNMP::Info::_load_attr bp_index : BRIDGE-MIB::dot1dBasePortIfIndex : .1.3.6.1.2.1.17.1.4.1.2
SNMP::Info::_validate_autoload_method(vtp_version) Unable to resolve method.
[3871942] 2024-06-10 07:03:00 debug [192.168.111.1] reindexing to vlan 0 (ver: 2, class: SNMP::Info::Layer2::CiscoSB)
SNMP::Info::clear_cache() - Cache Cleared.
[3871942] 2024-06-10 07:03:00 debug � (done) Gathered MAC addresses for 192.168.111.1
[3871942] 2024-06-10 07:03:00 debug � worker Macsuck::PortAccessEntity p100
[3871942] 2024-06-10 07:03:00 debug [192.168.111.1] pae - updating PortAccessEntity details
SNMP::Info::_global pae_control : IEEE8021-PAE-MIB::dot1xPaeSystemAuthControl.0 : .1.0.8802.1.1.1.1.1.1.0
SNMP::Info::_global(pae_control) NOSUCHOBJECT at /home/netdisco/perl5/lib/perl5/App/Netdisco/Util/PortAccessEntity.pm line 33.
[3871942] 2024-06-10 07:03:00 debug [192.168.111.1] pae - no PortAccessEntity support, leaving worker
[3871942] 2024-06-10 07:03:00 debug � (info) Skipped pae for 192.168.111.1
[3871942] 2024-06-10 07:03:00 debug � worker Macsuck::WirelessNodes p100
SNMP::Info::_validate_autoload_method(cd11_txrate) Unable to resolve method.
[3871942] 2024-06-10 07:03:00 debug //// STORE \\ phase
[3871942] 2024-06-10 07:03:00 debug � worker Macsuck::InterfacesStatus p0 "update interfaces status in database"
[3871942] 2024-06-10 07:03:00 debug [192.168.111.1] macsuck - updating port GigabitEthernet1 status up/up due to node presence
[3871942] 2024-06-10 07:03:00 debug [192.168.111.1] macsuck - updating port GigabitEthernet47 status up/up due to node presence
[3871942] 2024-06-10 07:03:00 debug [192.168.111.1] macsuck - updating port GigabitEthernet48 status up/up due to node presence
[3871942] 2024-06-10 07:03:00 debug [192.168.111.1] macsuck - updating port GigabitEthernet43 status up/up due to node presence
[3871942] 2024-06-10 07:03:00 debug [192.168.111.1] macsuck - updating port GigabitEthernet23 status up/up due to node presence
[3871942] 2024-06-10 07:03:00 debug [192.168.111.1] macsuck - updating port GigabitEthernet39 status up/up due to node presence
[3871942] 2024-06-10 07:03:00 debug [192.168.111.1] macsuck - updating port GigabitEthernet44 status up/up due to node presence
[3871942] 2024-06-10 07:03:00 debug [192.168.111.1] macsuck - updating port GigabitEthernet24 status up/up due to node presence
[3871942] 2024-06-10 07:03:00 debug [192.168.111.1] macsuck - updating port GigabitEthernet36 status up/up due to node presence
[3871942] 2024-06-10 07:03:00 debug [192.168.111.1] macsuck - updating port GigabitEthernet41 status up/up due to node presence
[3871942] 2024-06-10 07:03:00 debug [192.168.111.1] macsuck - updating port GigabitEthernet17 status up/up due to node presence
[3871942] 2024-06-10 07:03:00 debug [192.168.111.1] macsuck - updating port GigabitEthernet34 status up/up due to node presence
[3871942] 2024-06-10 07:03:00 debug [192.168.111.1] macsuck - updating port GigabitEthernet45 status up/up due to node presence
[3871942] 2024-06-10 07:03:00 debug [192.168.111.1] macsuck - updating port GigabitEthernet46 status up/up due to node presence
[3871942] 2024-06-10 07:03:00 debug [192.168.111.1] macsuck - updating port GigabitEthernet26 status up/up due to node presence
[3871942] 2024-06-10 07:03:00 debug [192.168.111.1] macsuck - updating port GigabitEthernet22 status up/up due to node presence
[3871942] 2024-06-10 07:03:00 debug [192.168.111.1] macsuck - updating port GigabitEthernet19 status up/up due to node presence
[3871942] 2024-06-10 07:03:00 debug [192.168.111.1] macsuck - updating port GigabitEthernet6 status up/up due to node presence
[3871942] 2024-06-10 07:03:00 debug [192.168.111.1] macsuck - updating port GigabitEthernet33 status up/up due to node presence
[3871942] 2024-06-10 07:03:00 debug [192.168.111.1] macsuck - updating port GigabitEthernet15 status up/up due to node presence
[3871942] 2024-06-10 07:03:00 debug [192.168.111.1] macsuck - updating port GigabitEthernet10 status up/up due to node presence
[3871942] 2024-06-10 07:03:00 debug � (info) 0 interfaces status updated in database
[3871942] 2024-06-10 07:03:00 debug � worker Macsuck::Nodes p0 "save macs to database"
[3871942] 2024-06-10 07:03:00 debug -> DBIx::Class::Storage::DBI::_dbh_execute(): DBI Exception: DBD::Pg::st execute failed: ERROR: invalid input syntax for type macaddr: "06:e0:ba:ad:8d:d1:35"
CONTEXT: unnamed portal parameter $1 = '...' [for Statement "SELECT me.mac, me.ip FROM ( SELECT ip, mac FROM device where mac = any (?::macaddr[])
UNION
SELECT ip, mac FROM device_port dp where mac = any (?::macaddr[])
) me GROUP BY mac, ip" with ParamValues: 1='{"06:e0:ba:ad:8d:d1:35","06:00:15:65:e0:70:48","06:00:15:65:29:d5:c4","06:00:21:b7:15:9c:4f","06:d8:5e:d3:45:6f:a7","06:00:21:b7:61:3a:77","06:e0:d5:5e:ed:4a:6d","06:9c:2d:cd:a7:d1:ef","06:80:5e:0c:cd:04:ab","06:40:8d:5c:7c:9f:0c","06:bc:f8:11:51:72:4c","06:90:e9:5e:9e:72:75","06:24:9a:d8:7b:61:cc","06:04:d5:90:30:2a:2c","06:04:d5:90:30:2a:2f","06:80:5e:c0:81:ab:3d","06:24:9a:d8:7b:62:9b","06:18:c0:4d:c3:ec:bc","06:74:11:b2:97:56:aa","06:e0:d5:5e:0e:48:4f","06:00:21:b7:6e:be:8d","06:d8:5e:d3:5b:56:27","06:f2:5d:90:23:fe:e1","06:80:5e:c0:e5:23:6b","06:00:12:e5:10:51:35","06:24:9a:d8:7b:62:d5","06:00:15:65:a6:93:ef","06:80:5e:c0:08:54:b5","06:bc:f8:11:51:74:86","06:18:c0:4d:c3:ec:e3","06:74:f8:db:55:da:0e","06:80:5e:c0:e5:23:a4","06:bc:f8:11:51:74:93","06:00:21:b7:bf:f5:7d","06:78:8c:77:64:12:aa","06:80:5e:c0:e5:22:90","06:80:5e:0c:cd:05:2c","06:bc:f8:11:51:74:c2","06:d8:5e:d3:55:8f:32","06:d0:67:26:2f:4f:80","06:00:17:c8:be:16:d1","06:54:80:28:b9:2c:00","06:00:04:13:26:dd:de","06:8...', 2='{"06:e0:ba:ad:8d:d1:35","06:00:15:65:e0:70:48","06:00:15:65:29:d5:c4","06:00:21:b7:15:9c:4f","06:d8:5e:d3:45:6f:a7","06:00:21:b7:61:3a:77","06:e0:d5:5e:ed:4a:6d","06:9c:2d:cd:a7:d1:ef","06:80:5e:0c:cd:04:ab","06:40:8d:5c:7c:9f:0c","06:bc:f8:11:51:72:4c","06:90:e9:5e:9e:72:75","06:24:9a:d8:7b:61:cc","06:04:d5:90:30:2a:2c","06:04:d5:90:30:2a:2f","06:80:5e:c0:81:ab:3d","06:24:9a:d8:7b:62:9b","06:18:c0:4d:c3:ec:bc","06:74:11:b2:97:56:aa","06:e0:d5:5e:0e:48:4f","06:00:21:b7:6e:be:8d","06:d8:5e:d3:5b:56:27","06:f2:5d:90:23:fe:e1","06:80:5e:c0:e5:23:6b","06:00:12:e5:10:51:35","06:24:9a:d8:7b:62:d5","06:00:15:65:a6:93:ef","06:80:5e:c0:08:54:b5","06:bc:f8:11:51:74:86","06:18:c0:4d:c3:ec:e3","06:74:f8:db:55:da:0e","06:80:5e:c0:e5:23:a4","06:bc:f8:11:51:74:93","06:00:21:b7:bf:f5:7d","06:78:8c:77:64:12:aa","06:80:5e:c0:e5:22:90","06:80:5e:0c:cd:05:2c","06:bc:f8:11:51:74:c2","06:d8:5e:d3:55:8f:32","06:d0:67:26:2f:4f:80","06:00:17:c8:be:16:d1","06:54:80:28:b9:2c:00","06:00:04:13:26:dd:de","06:8...'] at /home/netdisco/perl5/lib/perl5/App/Netdisco/Util/PortMAC.pm line 42

Possible Solution

Steps to Reproduce (for bugs)

Context

Discovery is not working properly

Your Device

iso.3.6.1.2.1.1.1.0 = STRING: "48-Port Gigabit PoE Smart Switch"
iso.3.6.1.2.1.1.2.0 = OID: iso.3.6.1.4.1.9.6.1.1009.52.5
iso.3.6.1.2.1.1.3.0 = Timeticks: (32284100) 3 days, 17:40:41.00
iso.3.6.1.2.1.1.4.0 = ""
iso.3.6.1.2.1.1.5.0 = STRING: "F5-1"
iso.3.6.1.2.1.1.6.0 = ""
iso.3.6.1.2.1.1.7.0 = INTEGER: 79
iso.3.6.1.2.1.1.8.0 = Timeticks: (6746400) 18:44:24.00
iso.3.6.1.2.1.1.9.1.2.1 = OID: iso.3.6.1.6.3.10.3.1.1
iso.3.6.1.2.1.1.9.1.2.2 = OID: iso.3.6.1.6.3.11.3.1.1
iso.3.6.1.2.1.1.9.1.2.3 = OID: iso.3.6.1.6.3.15.2.1.1
iso.3.6.1.2.1.1.9.1.2.4 = OID: iso.3.6.1.6.3.1
iso.3.6.1.2.1.1.9.1.2.5 = OID: iso.3.6.1.6.3.16.2.2.1
iso.3.6.1.2.1.1.9.1.2.6 = OID: iso.3.6.1.2.1.49
iso.3.6.1.2.1.1.9.1.2.7 = OID: iso.3.6.1.2.1.50
iso.3.6.1.2.1.1.9.1.2.8 = OID: iso.3.6.1.2.1.4
iso.3.6.1.2.1.1.9.1.2.9 = OID: iso.3.6.1.6.3.13.3.1.3
iso.3.6.1.2.1.1.9.1.2.10 = OID: iso.3.6.1.2.1.92
iso.3.6.1.2.1.1.9.1.3.1 = STRING: "The SNMP Management Architecture MIB."
iso.3.6.1.2.1.1.9.1.3.2 = STRING: "The MIB for Message Processing and Dispatching."
iso.3.6.1.2.1.1.9.1.3.3 = STRING: "The management information definitions for the SNMP User-based Security Model."
iso.3.6.1.2.1.1.9.1.3.4 = STRING: "The MIB module for SNMPv2 entities"
iso.3.6.1.2.1.1.9.1.3.5 = STRING: "View-based Access Control Model for SNMP."
iso.3.6.1.2.1.1.9.1.3.6 = STRING: "The MIB module for managing TCP implementations"
iso.3.6.1.2.1.1.9.1.3.7 = STRING: "The MIB module for managing UDP implementations"
iso.3.6.1.2.1.1.9.1.3.8 = STRING: "The MIB module for managing IP and ICMP implementations"
iso.3.6.1.2.1.1.9.1.3.9 = STRING: "The MIB modules for managing SNMP Notification, plus filtering."
iso.3.6.1.2.1.1.9.1.3.10 = STRING: "The MIB module for logging SNMP Notifications."
iso.3.6.1.2.1.1.9.1.4.1 = Timeticks: (6746400) 18:44:24.00
iso.3.6.1.2.1.1.9.1.4.2 = Timeticks: (6746400) 18:44:24.00
iso.3.6.1.2.1.1.9.1.4.3 = Timeticks: (6746400) 18:44:24.00
iso.3.6.1.2.1.1.9.1.4.4 = Timeticks: (6746400) 18:44:24.00
iso.3.6.1.2.1.1.9.1.4.5 = Timeticks: (6746400) 18:44:24.00
iso.3.6.1.2.1.1.9.1.4.6 = Timeticks: (6746400) 18:44:24.00
iso.3.6.1.2.1.1.9.1.4.7 = Timeticks: (6746400) 18:44:24.00
iso.3.6.1.2.1.1.9.1.4.8 = Timeticks: (6746400) 18:44:24.00
iso.3.6.1.2.1.1.9.1.4.9 = Timeticks: (6746400) 18:44:24.00
iso.3.6.1.2.1.1.9.1.4.10 = Timeticks: (6746400) 18:44:24.00

  • Vendor:
  • Device Model:
  • Operating System Version:
  • Snmpwalk output of .1.3.6.1.2.1.1:

Your Environment

Software Version
App::Netdisco 2.76.5
SNMP::Info 3.970.1
DB Schema 87
PostgreSQL 15.00.7
Perl 5.36.0

@ollyg
Copy link
Member

ollyg commented Jun 10, 2024

Hi @nvmike thanks for the bug report.
Indeed the error is quite correct! invalid input syntax for type macaddr: "06:e0:ba:ad:8d:d1:35"

That contains too many bits for a MAC address. Now, Nedisco ought to be doing sanity checking so this is arguably a bug. I will attempt to look into it.

I wonder first, whether this is an address of something not Ethernet, so needs removing, or if it's a bug in the poller (SNMP::Info CiscoSB class) which could strip the leading 06: from a legitimate MAC address. Ideas welcome.

@JeroenvIS
Copy link
Member

Without digging into the code yet: what stands out is that all MACs appear to be prefixed with "06", and Ethernet MAC addresses happen to be 6 bytes in length - that's likely not a coincidence.
Would be interesting to see snmpwalk output or device snapshot for one of these devices.

@nvmike
Copy link
Author

nvmike commented Jun 10, 2024

Hi all
Indeed I did suspect this - so I did an snmpwalk expecting to see one of htis value returned by the switch.
walk-result.txt

Did not find it

@nvmike
Copy link
Author

nvmike commented Jun 10, 2024

Hi @ollyg do you know what snmp OID is querried ?

@nvmike
Copy link
Author

nvmike commented Jun 10, 2024

OK I can confirm - all are addresses that belong to the mac address table - somehow 06: is prepended to it
( my bad I was comparing mac address with upper case charachter when netdisco is reporting with lower cased )

@fenner
Copy link
Contributor

fenner commented Jun 10, 2024

Since the type is MacAddress, and the SYNTAX of MacAddress is OCTET STRING (SIZE (6)), the length field is not appended to the OID - Section 7.7 of RFC2578 point 2 applies here:

 (2)  string-valued, fixed-length strings (...
      ...):  'n' sub-identifiers, where 'n' is the length
      of the string (each octet of the string is encoded in a separate
      sub-identifier);

MacAddress is string-valued and fixed-length, so is just represented by the 6 octets of the address and the 6 is not involved.

So this is a bug in the SNMP implementation that you're querying; it's treating it as a variable-length string.

This agent bug could be worked around in SNMP::Info; e.g., in _qb_fdbtable_index it could check if values[0] == 6 and len( values ) == 7, and if so, pop the first entry.

@nvmike
Copy link
Author

nvmike commented Jun 10, 2024

@fenner - THank you for the clear explanation.
So the 06 at each head of MAC is just here to indicate the the next 6 octets are the MAC itself - it is not intended to be there.
Somehow I do not see it in the snmpwalk - only in the macsuck debug.

I wonder if I can do the workaround myself - here I need to admit that my skills in Perl and programming in general are far to permit me it.
Mike

@fenner
Copy link
Contributor

fenner commented Jun 10, 2024

Somehow I do not see it in the snmpwalk - only in the macsuck debug.

Add -Ob to your snmpwalk command and you will see it.

I wrote this code originally about 20 years ago; my perl abilities have flagged since then unfortunately, but my pointers should be enough to help a perl coder help you.

@inphobia
Copy link
Member

inphobia commented Jun 10, 2024

s::i::layer2::ciscosb has provisions for this using the ciscosb mibs.

that's the good news. the bad news is that for whatever reason the ciscosb 220 series mibs seems to be different as all the other sb models.

the ciscosb module is mostly tested with devices that identify under enterprises.9.6.1.101 (aka ciscosb.switch001à)
the 220 series falls under enterprises.9.6.1.109 (aka ciscosb.switch009)

to make it more fun the mib filenames for both series are the same, but with different content, so that will either make for a totally fun merge job to inmport them (or they can be added in a seperate dir).

update:

actually the 3 220's we have:
CBS220-24T-4X - fw 2.0.2.8
CBS220-8FP-E-2G - fw 2.0.2.12
seems to not even return anything for the switch009 tree which is defined in their mibs, nor anything under the switch001 tree (expected but tried anyway)

all 250 other ciscosb devices we have (300, 302, 350) return 20mb of snmp data easily.

it's a sb220 thing, my collegue likes to use a fluke optieview and it also fails format the snmp data for them.

extra:

ugh, totally misread. ciscosb fixes up other stuff, not the part you're having issues with. i can reproduce it on our 220's, other devices in the same class work fine.

@nvmike
Copy link
Author

nvmike commented Jun 10, 2024

So are we stuck? Is there any solution that we can think about ?

@nvmike
Copy link
Author

nvmike commented Jun 11, 2024

Somehow I do not see it in the snmpwalk - only in the macsuck debug.

Add -Ob to your snmpwalk command and you will see it. --> Did try this - same output

I wrote this code originally about 20 years ago; my perl abilities have flagged since then unfortunately, but my pointers should be enough to help a perl coder help you.

walk-result.txt

@fenner
Copy link
Contributor

fenner commented Jun 12, 2024 via email

@ollyg
Copy link
Member

ollyg commented Jun 12, 2024

side quest: I'd be interested to know what the output of the following is:
bin/netdisco-do show -d x.x.x.x -e Q-BRIDGE-MIB::dot1qTpFdbAddress (you can add -D and -I or -II for debug)
bin/netdisco-do show -d x.x.x.x -e fw_mac

We also have a small note on running snmpwalk/snmpbulkwalk here (recommending -ObentU flags), and it's possible to share that with a dev or load it into Netdisco for inspection: https://github.com/netdisco/netdisco/wiki/Snapshot#share-a-snapshot

@inphobia
Copy link
Member

10.98.1.201 is a ciscosb sg300
10.40.254.105 is a ciscosb CBS220-24T-4X

netdisco:~> netdisco-do show -d 10.40.254.105 -e Q-BRIDGE-MIB::dot1qTpFdbAddress
[32395] 2024-06-12 21:33:27  info App::Netdisco version 2.076005 loaded.
[32395] 2024-06-12 21:33:27  info show: [10.40.254.105]/Q-BRIDGE-MIB::dot1qTpFdbAddress started at Wed Jun 12 23:33:27 2024
undef
[32395] 2024-06-12 21:33:27  info show: finished at Wed Jun 12 23:33:27 2024
[32395] 2024-06-12 21:33:27  info show: status done: Showed Q-BRIDGE-MIB::dot1qTpFdbAddress response from 10.40.254.105
netdisco@:~> netdisco-do show -d 10.98.1.201 -e Q-BRIDGE-MIB::dot1qTpFdbAddress
[32400] 2024-06-12 21:34:20  info App::Netdisco version 2.076005 loaded.
[32400] 2024-06-12 21:34:20  info show: [10.98.1.201]/Q-BRIDGE-MIB::dot1qTpFdbAddress started at Wed Jun 12 23:34:20 2024
undef
[32400] 2024-06-12 21:34:20  info show: finished at Wed Jun 12 23:34:20 2024
[32400] 2024-06-12 21:34:20  info show: status done: Showed Q-BRIDGE-MIB::dot1qTpFdbAddress response from 10.98.1.201
netdisco@:~> netdisco-do show -d 10.40.254.105 -e fw_mac
[32646] 2024-06-12 21:35:02  info App::Netdisco version 2.076005 loaded.
[32646] 2024-06-12 21:35:02  info show: [10.40.254.105]/fw_mac started at Wed Jun 12 23:35:02 2024
{
    1.6.0.0.12.159.240.254        "06:00:00:0c:9f:f0:fe" (dualvar: 6),
    1.6.0.37.181.8.16.15          "06:00:25:b5:08:10:0f" (dualvar: 6),
    1.6.0.37.181.8.17.143         "06:00:25:b5:08:11:8f" (dualvar: 6),
    1.6.0.37.181.16.17.14         "06:00:25:b5:10:11:0e" (dualvar: 6),
    1.6.0.37.181.16.17.47         "06:00:25:b5:10:11:2f" (dualvar: 6),
    1.6.0.37.181.16.17.142        "06:00:25:b5:10:11:8e" (dualvar: 6),
    1.6.0.37.181.16.17.143        "06:00:25:b5:10:11:8f" (dualvar: 6),
    1.6.0.58.156.202.10.53        "06:00:3a:9c:ca:0a:35" (dualvar: 6),
    1.6.0.58.156.202.18.69        "06:00:3a:9c:ca:12:45" (dualvar: 6),
    1.6.0.58.156.202.18.241       "06:00:3a:9c:ca:12:f1" (dualvar: 6),
    1.6.0.58.156.202.35.17        "06:00:3a:9c:ca:23:11" (dualvar: 6),
    1.6.0.64.157.149.78.131       "06:00:40:9d:95:4e:83" (dualvar: 6),
    1.6.0.80.86.131.65.90         "06:00:50:56:83:41:5a" (dualvar: 6),
    1.6.0.80.86.131.207.201       "06:00:50:56:83:cf:c9" (dualvar: 6),
    1.6.0.80.86.159.67.153        "06:00:50:56:9f:43:99" (dualvar: 6),
    1.6.0.80.86.159.122.38        "06:00:50:56:9f:7a:26" (dualvar: 6),
    1.6.0.80.86.159.253.7         "06:00:50:56:9f:fd:07" (dualvar: 6),
    1.6.0.80.86.159.253.224       "06:00:50:56:9f:fd:e0" (dualvar: 6),
    1.6.0.160.152.190.160.133     "06:00:a0:98:be:a0:85" (dualvar: 6),
    1.6.0.160.152.190.160.135     "06:00:a0:98:be:a0:87" (dualvar: 6),
    1.6.0.160.152.190.192.216     "06:00:a0:98:be:c0:d8" (dualvar: 6),
    1.6.0.160.152.190.192.218     "06:00:a0:98:be:c0:da" (dualvar: 6),
    1.6.0.224.216.30.166.43       "06:00:e0:d8:1e:a6:2b" (dualvar: 6),
    1.6.0.224.216.30.166.92       "06:00:e0:d8:1e:a6:5c" (dualvar: 6),
    1.6.0.224.216.30.177.173      "06:00:e0:d8:1e:b1:ad" (dualvar: 6),
    1.6.0.224.216.30.177.192      "06:00:e0:d8:1e:b1:c0" (dualvar: 6),
    1.6.2.160.152.190.160.133     "06:02:a0:98:be:a0:85" (dualvar: 6),
    1.6.2.160.152.190.192.216     "06:02:a0:98:be:c0:d8" (dualvar: 6),
    1.6.2.224.237.126.247.215     "06:02:e0:ed:7e:f7:d7" (dualvar: 6),
    1.6.12.196.122.180.72.136     "06:0c:c4:7a:b4:48:88" (dualvar: 6),
    1.6.12.196.122.225.176.142    "06:0c:c4:7a:e1:b0:8e" (dualvar: 6),
    1.6.20.171.236.138.213.128    "06:14:ab:ec:8a:d5:80" (dualvar: 6),
    1.6.20.171.236.138.229.128    "06:14:ab:ec:8a:e5:80" (dualvar: 6),
    1.6.20.171.236.194.123.0      "06:14:ab:ec:c2:7b:00" (dualvar: 6),
    1.6.20.171.236.201.27.192     "06:14:ab:ec:c9:1b:c0" (dualvar: 6),
    1.6.20.171.236.201.180.192    "06:14:ab:ec:c9:b4:c0" (dualvar: 6),
    1.6.20.171.236.201.194.128    "06:14:ab:ec:c9:c2:80" (dualvar: 6),
    1.6.20.171.236.204.121.0      "06:14:ab:ec:cc:79:00" (dualvar: 6),
    1.6.20.171.236.204.232.128    "06:14:ab:ec:cc:e8:80" (dualvar: 6),
    1.6.20.171.236.205.36.0       "06:14:ab:ec:cd:24:00" (dualvar: 6),
    1.6.44.26.5.247.87.197        "06:2c:1a:05:f7:57:c5" (dualvar: 6),
    1.6.44.26.5.247.88.231        "06:2c:1a:05:f7:58:e7" (dualvar: 6),
    1.6.56.234.167.166.108.92     "06:38:ea:a7:a6:6c:5c" (dualvar: 6),
    1.6.80.235.26.26.45.36        "06:50:eb:1a:1a:2d:24" (dualvar: 6),
    1.6.108.178.174.145.25.16     "06:6c:b2:ae:91:19:10" (dualvar: 6),
    1.6.108.178.174.145.25.23     "06:6c:b2:ae:91:19:17" (dualvar: 6),
    1.6.108.178.174.145.25.110    "06:6c:b2:ae:91:19:6e" (dualvar: 6),
    1.6.108.178.174.145.28.74     "06:6c:b2:ae:91:1c:4a" (dualvar: 6),
    1.6.108.178.174.145.28.81     "06:6c:b2:ae:91:1c:51" (dualvar: 6),
    1.6.108.178.174.145.37.19     "06:6c:b2:ae:91:25:13" (dualvar: 6),
    1.6.112.76.165.202.142.134    "06:70:4c:a5:ca:8e:86" (dualvar: 6),
    1.6.152.190.148.125.221.124   "06:98:be:94:7d:dd:7c" (dualvar: 6),
    1.6.152.190.148.125.222.248   "06:98:be:94:7d:de:f8" (dualvar: 6),
    1.6.164.14.117.179.158.0      "06:a4:0e:75:b3:9e:00" (dualvar: 6),
    1.6.164.14.117.179.236.64     "06:a4:0e:75:b3:ec:40" (dualvar: 6),
    1.6.172.31.107.68.10.249      "06:ac:1f:6b:44:0a:f9" (dualvar: 6),
    1.6.192.199.10.59.74.134      "06:c0:c7:0a:3b:4a:86" (dualvar: 6),
    1.6.208.57.234.155.145.32     "06:d0:39:ea:9b:91:20" (dualvar: 6),
    1.6.208.57.234.155.145.34     "06:d0:39:ea:9b:91:22" (dualvar: 6),
    1.6.208.57.234.155.148.10     "06:d0:39:ea:9b:94:0a" (dualvar: 6),
    1.6.208.57.234.155.148.12     "06:d0:39:ea:9b:94:0c" (dualvar: 6),
    1.6.208.224.66.247.117.7      "06:d0:e0:42:f7:75:07" (dualvar: 6),
    1.6.210.57.234.155.145.33     "06:d2:39:ea:9b:91:21" (dualvar: 6),
    1.6.210.57.234.155.148.11     "06:d2:39:ea:9b:94:0b" (dualvar: 6),
    1.6.216.31.204.244.167.192    "06:d8:1f:cc:f4:a7:c0" (dualvar: 6),
    1.6.216.31.204.245.246.160    "06:d8:1f:cc:f5:f6:a0" (dualvar: 6)
}
[32646] 2024-06-12 21:35:03  info show: finished at Wed Jun 12 23:35:03 2024
[32646] 2024-06-12 21:35:03  info show: status done: Showed fw_mac response from 10.40.254.105
netdisco@:~> netdisco-do show -d 10.98.1.201 -e fw_mac
[32403] 2024-06-12 21:34:49  info App::Netdisco version 2.076005 loaded.
[32403] 2024-06-12 21:34:49  info show: [10.98.1.201]/fw_mac started at Wed Jun 12 23:34:49 2024
{
    1.0.2.99.5.130.186          "00:02:63:05:82:ba",
    1.0.5.27.208.3.105          "00:05:1b:d0:03:69",
    1.0.8.48.48.254.91          "00:08:30:30:fe:5b",
    1.0.8.48.49.108.149         "00:08:30:31:6c:95",
    1.0.8.48.49.110.97          "00:08:30:31:6e:61",
    1.0.8.48.138.62.83          "00:08:30:8a:3e:53",
    1.0.8.48.138.62.101         "00:08:30:8a:3e:65",
    1.0.8.48.138.62.105         "00:08:30:8a:3e:69",
    1.0.8.48.138.62.212         "00:08:30:8a:3e:d4",
    1.0.8.48.138.62.213         "00:08:30:8a:3e:d5",
    1.0.18.95.23.117.119        "00:12:5f:17:75:77",
    1.0.25.74.0.19.33           "00:19:4a:00:13:21",
    1.0.25.74.0.254.209         "00:19:4a:00:fe:d1",
    1.0.25.74.1.14.159          "00:19:4a:01:0e:9f",
    1.0.25.74.1.220.172         "00:19:4a:01:dc:ac",
    1.0.25.74.2.107.171         "00:19:4a:02:6b:ab",
    1.0.26.75.240.228.114       "00:1a:4b:f0:e4:72",
    1.0.27.130.51.101.243       "00:1b:82:33:65:f3",
    1.0.29.112.96.186.222       "00:1d:70:60:ba:de",
    1.0.32.107.64.159.188       "00:20:6b:40:9f:bc",
    1.0.142.115.181.207.116     "00:8e:73:b5:cf:74",
    1.0.142.115.181.212.125     "00:8e:73:b5:d4:7d",
    1.0.142.115.181.212.175     "00:8e:73:b5:d4:af",
    1.4.108.157.159.90.0        "04:6c:9d:9f:5a:00" (dualvar: 4),
    1.4.108.157.159.90.9        "04:6c:9d:9f:5a:09" (dualvar: 4),
    1.8.208.159.158.96.241      "08:d0:9f:9e:60:f1" (dualvar: 8),
    1.8.208.159.158.199.183     "08:d0:9f:9e:c7:b7" (dualvar: 8),
    1.8.208.159.158.200.132     "08:d0:9f:9e:c8:84" (dualvar: 8),
    1.8.208.159.158.200.183     "08:d0:9f:9e:c8:b7" (dualvar: 8),
    1.8.208.159.158.200.252     "08:d0:9f:9e:c8:fc" (dualvar: 8),
    1.16.189.24.221.27.168      "10:bd:18:dd:1b:a8" (dualvar: 10),
    1.80.62.170.130.5.137       "50:3e:aa:82:05:89" (dualvar: 50),
    1.80.62.170.130.12.73       "50:3e:aa:82:0c:49" (dualvar: 50),
    1.100.160.231.21.220.65     "64:a0:e7:15:dc:41" (dualvar: 64),
    1.100.160.231.21.220.170    "64:a0:e7:15:dc:aa" (dualvar: 64),
    1.108.75.144.192.253.233    "6c:4b:90:c0:fd:e9" (dualvar: 6),
    1.108.75.144.192.253.242    "6c:4b:90:c0:fd:f2" (dualvar: 6),
    1.144.184.50.102.127.64     "90:b8:32:66:7f:40" (dualvar: 90),
    1.148.198.145.129.117.115   "94:c6:91:81:75:73" (dualvar: 94),
    1.148.198.145.129.132.20    "94:c6:91:81:84:14" (dualvar: 94),
    1.148.198.145.129.137.25    "94:c6:91:81:89:19" (dualvar: 94),
    1.148.198.145.129.137.66    "94:c6:91:81:89:42" (dualvar: 94),
    1.148.198.145.129.137.92    "94:c6:91:81:89:5c" (dualvar: 94),
    1.148.198.145.129.137.104   "94:c6:91:81:89:68" (dualvar: 94),
    1.148.198.145.129.137.105   "94:c6:91:81:89:69" (dualvar: 94),
    1.148.198.145.129.137.111   "94:c6:91:81:89:6f" (dualvar: 94),
    1.148.198.145.129.137.223   "94:c6:91:81:89:df" (dualvar: 94),
    1.148.198.145.129.137.232   "94:c6:91:81:89:e8" (dualvar: 94),
    1.148.198.145.129.137.239   "94:c6:91:81:89:ef" (dualvar: 94),
    1.148.198.145.129.137.240   "94:c6:91:81:89:f0" (dualvar: 94),
    1.156.147.78.74.210.65      "9c:93:4e:4a:d2:41" (dualvar: 9),
    1.164.23.145.40.211.85      "a4:17:91:28:d3:55",
    1.180.233.176.107.155.126   "b4:e9:b0:6b:9b:7e",
    1.196.19.226.68.148.64      "c4:13:e2:44:94:40",
    1.196.19.226.68.160.192     "c4:13:e2:44:a0:c0",
    1.196.19.226.69.165.128     "c4:13:e2:45:a5:80",
    1.196.19.226.243.103.64     "c4:13:e2:f3:67:40",
    1.208.80.153.204.61.151     "d0:50:99:cc:3d:97",
    1.208.80.153.204.61.153     "d0:50:99:cc:3d:99",
    1.232.186.112.251.50.103    "e8:ba:70:fb:32:67",
    1.236.1.213.60.126.139      "ec:01:d5:3c:7e:8b",
    1.236.1.213.60.126.244      "ec:01:d5:3c:7e:f4",
    1.244.57.9.240.219.206      "f4:39:09:f0:db:ce",
    1.244.57.9.241.224.23       "f4:39:09:f1:e0:17",
    1.252.21.180.51.37.218      "fc:15:b4:33:25:da"
}
[32403] 2024-06-12 21:34:50  info show: finished at Wed Jun 12 23:34:50 2024
[32403] 2024-06-12 21:34:50  info show: status done: Showed fw_mac response from 10.98.1.201

@ollyg
Copy link
Member

ollyg commented Jun 12, 2024

Thanks @inphobia ! 💟
I guess some devices might respond to BRIDGE-MIB::dot1dTpFdbAddress instead of Q-BRIDGE-MIB::dot1qTpFdbAddress

@inphobia
Copy link
Member

i'll try & have a look, but at first glance none of my devices return this & all return with:

Read Q-BRIDGE-MIB
trace: netsnmp_ds_set_int(): default_store.c, 268:
netsnmp_ds_set_int: Setting LIB:4 = 3
trace: read_module_internal(): parse.c, 3891:
parse-mibs: Module Q-BRIDGE-MIB already loaded
trace: netsnmp_ds_set_int(): default_store.c, 268:
netsnmp_ds_set_int: Setting LIB:4 = 1
SNMP::Info::_validate_autoload_method(Q_BRIDGE_MIB__dot1qTpFdbAddress : .1.3.6.1.2.1.17.7.1.2.2.1.1) Not accessible for requested operation.
undef
[768] 2024-06-12 21:55:00 debug ⬅ (done) Showed Q-BRIDGE-MIB::dot1qTpFdbAddress response from 10.98.50.1
[768] 2024-06-12 21:55:00  info show: finished at Wed Jun 12 23:55:00 2024
[768] 2024-06-12 21:55:00  info show: status done: Showed Q-BRIDGE-MIB::dot1qTpFdbAddress response from 10.98.50.1

tried on

  • ciscosb 220
  • ciscosb 300
  • cisco 1921
  • nexus 9332pq
  • allies at-8000s
  • aruba 6300m

the strange thing is the cisco sb 220 should show dot1qTpFdbAddress, since this is from an snmpwalk yesterday:

Q-BRIDGE-MIB::dot1qTpFdbAddress.1.6.0.0.12.159.240.254 = STRING: 0:0:c:9f:f0:fe
Q-BRIDGE-MIB::dot1qTpFdbAddress.1.6.0.37.181.8.17.79 = STRING: 0:25:b5:8:11:4f
Q-BRIDGE-MIB::dot1qTpFdbAddress.1.6.0.37.181.16.16.79 = STRING: 0:25:b5:10:10:4f
Q-BRIDGE-MIB::dot1qTpFdbAddress.1.6.0.37.181.16.16.110 = STRING: 0:25:b5:10:10:6e
Q-BRIDGE-MIB::dot1qTpFdbAddress.1.6.0.37.181.16.16.143 = STRING: 0:25:b5:10:10:8f
Q-BRIDGE-MIB::dot1qTpFdbAddress.1.6.0.37.181.16.16.238 = STRING: 0:25:b5:10:10:ee
Q-BRIDGE-MIB::dot1qTpFdbAddress.1.6.0.37.181.16.16.239 = STRING: 0:25:b5:10:10:ef

@nvmike
Copy link
Author

nvmike commented Jun 13, 2024

side quest: I'd be interested to know what the output of the following is: bin/netdisco-do show -d x.x.x.x -e Q-BRIDGE-MIB::dot1qTpFdbAddress (you can add -D and -I or -II for debug) bin/netdisco-do show -d x.x.x.x -e fw_mac

We also have a small note on running snmpwalk/snmpbulkwalk here (recommending -ObentU flags), and it's possible to share that with a dev or load it into Netdisco for inspection: https://github.com/netdisco/netdisco/wiki/Snapshot#share-a-snapshot

netdisco-do show -d 192.168.111.1 -e Q-BRIDGE-MIB::dot1qTpFdbAddress -DI
[1901656] 2024-06-13 04:22:34 info App::Netdisco version 2.076005 loaded.
[1901656] 2024-06-13 04:22:34 info show: [192.168.111.1]/Q-BRIDGE-MIB::dot1qTpFdbAddress started at Thu Jun 13 07:22:34 2024
[1901656] 2024-06-13 04:22:35 debug show: running with timeout 600s
[1901656] 2024-06-13 04:22:35 debug //// CHECK \\ phase
[1901656] 2024-06-13 04:22:35 debug � worker Internal::BackendFQDN p1000000
[1901656] 2024-06-13 04:22:35 debug � worker Internal::SNMPFastDiscover p1000000
[1901656] 2024-06-13 04:22:35 debug running with configured SNMP timeouts
[1901656] 2024-06-13 04:22:35 debug � worker Show p0
[1901656] 2024-06-13 04:22:35 debug � (done) Show is able to run
[1901656] 2024-06-13 04:22:35 debug //// MAIN \\ phase
[1901656] 2024-06-13 04:22:35 debug � worker Show p100
[1901656] 2024-06-13 04:22:35 debug snmp reader cache warm: [192.168.111.1]
[1901656] 2024-06-13 04:22:35 debug [192.168.111.1:161] try_connect with v: 2, t: 0.2, r: 0, class: SNMP::Info::Layer2::CiscoSB, comm:
SNMP::Info::_global uptime : DISMAN-EVENT-MIB::sysUpTimeInstance : .1.3.6.1.2.1.1.3.0
SNMP::Info::_global layers : SNMPv2-MIB::sysServices.0 : .1.3.6.1.2.1.1.7.0
SNMP::Info::_global description : SNMPv2-MIB::sysDescr.0 : .1.3.6.1.2.1.1.1.0
SNMP::Info::_global id : SNMPv2-MIB::sysObjectID.0 : .1.3.6.1.2.1.1.2.0
SNMP::Info 3.970001
SNMP::Info::device_type() layers:01001111 id:9 sysDescr:"48-Port Gigabit PoE Smart Switch"
SNMP::Info 3.970001
SNMP::Info::device_type() layers:01001111 id:9 sysDescr:"48-Port Gigabit PoE Smart Switch"
SNMP::Info::_validate_autoload_method(Q_BRIDGE_MIB__dot1qTpFdbAddress : .1.3.6.1.2.1.17.7.1.2.2.1.1) Not accessible for requested operation.
undef
[1901656] 2024-06-13 04:22:36 debug � (done) Showed Q-BRIDGE-MIB::dot1qTpFdbAddress response from 192.168.111.1
[1901656] 2024-06-13 04:22:36 info show: finished at Thu Jun 13 07:22:36 2024
[1901656] 2024-06-13 04:22:36 info show: status done: Showed Q-BRIDGE-MIB::dot1qTpFdbAddress response from 192.168.111.1

netdisco-do show -d 192.168.111.1 -e fw_mac
[1902171] 2024-06-13 04:23:37 info App::Netdisco version 2.076005 loaded.
[1902171] 2024-06-13 04:23:37 info show: [192.168.111.1]/fw_mac started at Thu Jun 13 07:23:37 2024
{
1.6.0.3.234.19.178.195 "06:00:03:ea:13:b2:c3" (dualvar: 6),
1.6.0.4.19.38.221.222 "06:00:04:13:26:dd:de" (dualvar: 6),
1.6.0.4.19.53.64.83 "06:00:04:13:35:40:53" (dualvar: 6),
1.6.0.18.229.6.114.129 "06:00:12:e5:06:72:81" (dualvar: 6),
1.6.0.18.229.6.115.102 "06:00:12:e5:06:73:66" (dualvar: 6),
1.6.0.18.229.16.81.53 "06:00:12:e5:10:51:35" (dualvar: 6),
1.6.0.20.238.8.211.129 "06:00:14:ee:08:d3:81" (dualvar: 6),
1.6.0.20.238.11.158.200 "06:00:14:ee:0b:9e:c8" (dualvar: 6),
1.6.0.21.101.41.211.168 "06:00:15:65:29:d3:a8" (dualvar: 6),
1.6.0.21.101.41.212.6 "06:00:15:65:29:d4:06" (dualvar: 6),
1.6.0.21.101.41.213.196 "06:00:15:65:29:d5:c4" (dualvar: 6),
1.6.0.21.101.41.215.16 "06:00:15:65:29:d7:10" (dualvar: 6),
1.6.0.21.101.41.215.22 "06:00:15:65:29:d7:16" (dualvar: 6),
1.6.0.21.101.41.217.90 "06:00:15:65:29:d9:5a" (dualvar: 6),
1.6.0.21.101.52.211.116 "06:00:15:65:34:d3:74" (dualvar: 6),
1.6.0.21.101.52.212.218 "06:00:15:65:34:d4:da" (dualvar: 6),
1.6.0.21.101.52.214.20 "06:00:15:65:34:d6:14" (dualvar: 6),
1.6.0.21.101.52.214.110 "06:00:15:65:34:d6:6e" (dualvar: 6),
1.6.0.21.101.52.215.42 "06:00:15:65:34:d7:2a" (dualvar: 6),
1.6.0.21.101.52.218.90 "06:00:15:65:34:da:5a" (dualvar: 6),
1.6.0.21.101.166.147.239 "06:00:15:65:a6:93:ef" (dualvar: 6),
1.6.0.21.101.166.149.66 "06:00:15:65:a6:95:42" (dualvar: 6),
1.6.0.21.101.224.111.242 "06:00:15:65:e0:6f:f2" (dualvar: 6),
1.6.0.21.101.224.112.66 "06:00:15:65:e0:70:42" (dualvar: 6),
1.6.0.21.101.224.112.72 "06:00:15:65:e0:70:48" (dualvar: 6),
1.6.0.21.101.224.113.14 "06:00:15:65:e0:71:0e" (dualvar: 6),
1.6.0.21.101.224.113.15 "06:00:15:65:e0:71:0f" (dualvar: 6),
1.6.0.21.101.224.113.18 "06:00:15:65:e0:71:12" (dualvar: 6),
1.6.0.23.111.75.236.111 "06:00:17:6f:4b:ec:6f" (dualvar: 6),
1.6.0.23.200.185.217.3 "06:00:17:c8:b9:d9:03" (dualvar: 6),
1.6.0.23.200.188.221.28 "06:00:17:c8:bc:dd:1c" (dualvar: 6),
1.6.0.23.200.190.22.209 "06:00:17:c8:be:16:d1" (dualvar: 6),
1.6.0.23.200.190.63.227 "06:00:17:c8:be:3f:e3" (dualvar: 6),
1.6.0.23.200.221.29.154 "06:00:17:c8:dd:1d:9a" (dualvar: 6),
1.6.0.23.200.222.171.170 "06:00:17:c8:de:ab:aa" (dualvar: 6),
1.6.0.23.200.222.172.133 "06:00:17:c8:de:ac:85" (dualvar: 6),
1.6.0.23.200.224.56.105 "06:00:17:c8:e0:38:69" (dualvar: 6),
1.6.0.23.200.240.40.152 "06:00:17:c8:f0:28:98" (dualvar: 6),
1.6.0.33.183.21.156.79 "06:00:21:b7:15:9c:4f" (dualvar: 6),
1.6.0.33.183.39.62.168 "06:00:21:b7:27:3e:a8" (dualvar: 6),
1.6.0.33.183.47.235.225 "06:00:21:b7:2f:eb:e1" (dualvar: 6),
1.6.0.33.183.51.163.100 "06:00:21:b7:33:a3:64" (dualvar: 6),
1.6.0.33.183.93.113.15 "06:00:21:b7:5d:71:0f" (dualvar: 6),
1.6.0.33.183.97.58.119 "06:00:21:b7:61:3a:77" (dualvar: 6),
1.6.0.33.183.110.190.141 "06:00:21:b7:6e:be:8d" (dualvar: 6),
1.6.0.33.183.123.161.105 "06:00:21:b7:7b:a1:69" (dualvar: 6),
1.6.0.33.183.131.93.158 "06:00:21:b7:83:5d:9e" (dualvar: 6),
1.6.0.33.183.141.176.32 "06:00:21:b7:8d:b0:20" (dualvar: 6),
1.6.0.33.183.147.58.185 "06:00:21:b7:93:3a:b9" (dualvar: 6),
1.6.0.33.183.153.186.196 "06:00:21:b7:99:ba:c4" (dualvar: 6),
1.6.0.33.183.191.245.125 "06:00:21:b7:bf:f5:7d" (dualvar: 6),
1.6.0.33.183.245.40.29 "06:00:21:b7:f5:28:1d" (dualvar: 6),
1.6.4.213.144.48.42.44 "06:04:d5:90:30:2a:2c" (dualvar: 6),
1.6.4.213.144.48.42.47 "06:04:d5:90:30:2a:2f" (dualvar: 6),
1.6.8.46.95.183.94.0 "06:08:2e:5f:b7:5e:00" (dualvar: 6),
1.6.16.18.251.161.139.113 "06:10:12:fb:a1:8b:71" (dualvar: 6),
1.6.24.192.77.24.37.106 "06:18:c0:4d:18:25:6a" (dualvar: 6),
1.6.24.192.77.55.178.209 "06:18:c0:4d:37:b2:d1" (dualvar: 6),
1.6.24.192.77.65.238.213 "06:18:c0:4d:41:ee:d5" (dualvar: 6),
1.6.24.192.77.65.238.248 "06:18:c0:4d:41:ee:f8" (dualvar: 6),
1.6.24.192.77.78.9.172 "06:18:c0:4d:4e:09:ac" (dualvar: 6),
1.6.24.192.77.117.182.251 "06:18:c0:4d:75:b6:fb" (dualvar: 6),
1.6.24.192.77.122.114.198 "06:18:c0:4d:7a:72:c6" (dualvar: 6),
1.6.24.192.77.134.168.207 "06:18:c0:4d:86:a8:cf" (dualvar: 6),
1.6.24.192.77.134.169.1 "06:18:c0:4d:86:a9:01" (dualvar: 6),
1.6.24.192.77.190.22.70 "06:18:c0:4d:be:16:46" (dualvar: 6),
1.6.24.192.77.195.236.188 "06:18:c0:4d:c3:ec:bc" (dualvar: 6),
1.6.24.192.77.195.236.227 "06:18:c0:4d:c3:ec:e3" (dualvar: 6),
1.6.24.192.77.195.238.150 "06:18:c0:4d:c3:ee:96" (dualvar: 6),
1.6.24.192.77.195.238.187 "06:18:c0:4d:c3:ee:bb" (dualvar: 6),
1.6.24.192.77.229.79.230 "06:18:c0:4d:e5:4f:e6" (dualvar: 6),
1.6.24.192.77.229.83.140 "06:18:c0:4d:e5:53:8c" (dualvar: 6),
1.6.24.192.77.236.20.95 "06:18:c0:4d:ec:14:5f" (dualvar: 6),
1.6.24.192.77.236.212.234 "06:18:c0:4d:ec:d4:ea" (dualvar: 6),
1.6.28.27.13.235.185.74 "06:1c:1b:0d:eb:b9:4a" (dualvar: 6),
1.6.28.105.122.171.153.48 "06:1c:69:7a:ab:99:30" (dualvar: 6),
1.6.36.154.216.123.96.121 "06:24:9a:d8:7b:60:79" (dualvar: 6),
1.6.36.154.216.123.96.133 "06:24:9a:d8:7b:60:85" (dualvar: 6),
1.6.36.154.216.123.97.79 "06:24:9a:d8:7b:61:4f" (dualvar: 6),
1.6.36.154.216.123.97.197 "06:24:9a:d8:7b:61:c5" (dualvar: 6),
1.6.36.154.216.123.97.204 "06:24:9a:d8:7b:61:cc" (dualvar: 6),
1.6.36.154.216.123.98.155 "06:24:9a:d8:7b:62:9b" (dualvar: 6),
1.6.36.154.216.123.98.195 "06:24:9a:d8:7b:62:c3" (dualvar: 6),
1.6.36.154.216.123.98.213 "06:24:9a:d8:7b:62:d5" (dualvar: 6),
1.6.36.154.216.123.99.20 "06:24:9a:d8:7b:63:14" (dualvar: 6),
1.6.36.154.216.123.99.63 "06:24:9a:d8:7b:63:3f" (dualvar: 6),
1.6.64.141.92.124.158.171 "06:40:8d:5c:7c:9e:ab" (dualvar: 6),
1.6.64.141.92.124.159.12 "06:40:8d:5c:7c:9f:0c" (dualvar: 6),
1.6.68.219.210.38.23.185 "06:44:db:d2:26:17:b9" (dualvar: 6),
1.6.68.219.210.38.25.65 "06:44:db:d2:26:19:41" (dualvar: 6),
1.6.68.219.210.38.26.157 "06:44:db:d2:26:1a:9d" (dualvar: 6),
1.6.72.33.11.96.126.87 "06:48:21:0b:60:7e:57" (dualvar: 6),
1.6.80.175.115.63.164.129 "06:50:af:73:3f:a4:81" (dualvar: 6),
1.6.84.128.40.185.44.0 "06:54:80:28:b9:2c:00" (dualvar: 6),
1.6.84.128.40.185.44.26 "06:54:80:28:b9:2c:1a" (dualvar: 6),
1.6.116.17.178.151.86.170 "06:74:11:b2:97:56:aa" (dualvar: 6),
1.6.116.17.178.151.86.217 "06:74:11:b2:97:56:d9" (dualvar: 6),
1.6.116.86.60.95.68.123 "06:74:56:3c:5f:44:7b" (dualvar: 6),
1.6.116.86.60.95.74.192 "06:74:56:3c:5f:4a:c0" (dualvar: 6),
1.6.116.86.60.157.1.204 "06:74:56:3c:9d:01:cc" (dualvar: 6),
(...skipping 130 keys...)
}
[1902171] 2024-06-13 04:23:40 info show: finished at Thu Jun 13 07:23:40 2024

@nvmike
Copy link
Author

nvmike commented Jun 13, 2024

side quest: I'd be interested to know what the output of the following is: bin/netdisco-do show -d x.x.x.x -e Q-BRIDGE-MIB::dot1qTpFdbAddress (you can add -D and -I or -II for debug) bin/netdisco-do show -d x.x.x.x -e fw_mac

We also have a small note on running snmpwalk/snmpbulkwalk here (recommending -ObentU flags), and it's possible to share that with a dev or load it into Netdisco for inspection: https://github.com/netdisco/netdisco/wiki/Snapshot#share-a-snapshot

Here the snapshot file

192.168.111.1-snapshot.txt

@nvmike
Copy link
Author

nvmike commented Jun 18, 2024

is there something we can do ?

@nvmike
Copy link
Author

nvmike commented Jun 23, 2024

OK
I did play wiht the file /Netdisco/Util/PortMAC.pm

sub get_port_macs {
my ($fw_mac_list) = $[0];
my $port_macs = {};
return {} unless ref [] eq ref $fw_mac_list and @{$fw_mac_list} >= 1;
### My changes -->
my @formatted_macs = map {
my $mac = $
;
$mac =~ s/://g; # Remove colons
$mac = sprintf("%012s", $mac); # Ensure it's 12 characters long, pad with zeros if needed
$mac;
} @{$fw_mac_list};
###
my $bindarray = [ { sqlt_datatype => "array" }, $fw_mac_list ];

my $macs
    = schema(vars->{'tenant'})->resultset('Virtual::PortMacs')->search({},
    { bind => [$bindarray, $bindarray], select => [ 'mac', 'ip' ], group_by => [ 'mac', 'ip' ] } );
my $cursor = $macs->cursor;
while ( my @vals = $cursor->next ) {
        ### And Here as well
        my $mac = $vals[0];
    $mac = join(':', unpack("(A2)*", $mac));
    ###

        $port_macs->{ $vals[0] } = $vals[1];
}

return $port_macs;

Now I am able to run macsuck and it work.
Just small inconvenient - the UI show all the mac in vlan 6:
Uploading Screenshot 2024-06-23 at 18.18.31.png…

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
Status: No status
Development

No branches or pull requests

5 participants