Skip site navigation (1)Skip section navigation (2)
Date:      Sat, 6 Oct 2018 14:03:46 +0300
From:      Yuri Pankov <yuripv@yuripv.net>
To:        Patrick Lamaiziere <patfbsd@davenulle.org>, freebsd-ports@freebsd.org
Cc:        freebsd-net@freebsd.org
Subject:   Re: [freebsd 11.2] net-snmpd incomplete mac addresses
Message-ID:  <e85ef8c4-888f-1ca4-f5c0-0e4cb33bb9b7@yuripv.net>
In-Reply-To: <930810ba-b659-d571-de84-995c1c97f1e5@yuripv.net>
References:  <20181005133302.5f518dc6@mr185033.univ-rennes1.fr> <930810ba-b659-d571-de84-995c1c97f1e5@yuripv.net>

next in thread | previous in thread | raw e-mail | index | archive | help
Yuri Pankov wrote:
> Patrick Lamaiziere wrote:
>> Hello,
>>
>> freebsd 11.2/amd64 release
>> net-snmp-5.7.3_18
>>
>> net-snmpd returns incomplete MAC addresses in IF-MIB::ifPhysAddress,
>> the first octet is always "0".
>>
>> $ snmpwalk -v 2c -c "xxx" localhost 1.3.6.1.2.1.2.2.1.6
>> IF-MIB::ifPhysAddress.1 = STRING: 0:36:9f:93:7d:f8
>> IF-MIB::ifPhysAddress.2 = STRING: 0:36:9f:93:7d:fa
>> IF-MIB::ifPhysAddress.3 = STRING: 0:f4:bb:ef:c8:e4
>> ...
>>
>> $ ifconfig | grep ether
>>     ether a0:36:9f:93:7d:f8
>>     ether a0:36:9f:93:7d:fa
>>     ether ec:f4:bb:ef:c8:e4
>>
>> tcpdump confirms that the problem is in net-snmpd (and not the client).
>>
>> Also when using the MIB IP-MIB::ipNetToMediaPhysAddress the MAC
>> addresses are correct.
>>
>> $ snmpwalk -v2c -c '***r***' localhost IP-MIB::ipNetToMediaPhysAddress 
>> | grep a0:36:9f:93:7d:f8
>> IP-MIB::ipNetToMediaPhysAddress.13.10.10.1.118 = STRING: 
>> a0:36:9f:93:7d:f8
>>
>> I've checked net-snmpd 5.7.3 under linux and the mac addresses are
>> correct. (So it's specific to FreeBSD.)
>>
>> Any clue ?
> 
> It looks like net-snmp being stupid, try the attached patch (put to 
> files/).

For the note:

https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=231996
https://sourceforge.net/p/net-snmp/code/merge-requests/20/



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?e85ef8c4-888f-1ca4-f5c0-0e4cb33bb9b7>