From owner-freebsd-ports@freebsd.org Sat Oct 6 11:04:16 2018 Return-Path: Delivered-To: freebsd-ports@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 687F110B6554; Sat, 6 Oct 2018 11:04:16 +0000 (UTC) (envelope-from yuripv@yuripv.net) Received: from wout2-smtp.messagingengine.com (wout2-smtp.messagingengine.com [64.147.123.25]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 060C170AEF; Sat, 6 Oct 2018 11:04:15 +0000 (UTC) (envelope-from yuripv@yuripv.net) Received: from compute5.internal (compute5.nyi.internal [10.202.2.45]) by mailout.west.internal (Postfix) with ESMTP id 690343C5; Sat, 6 Oct 2018 07:04:08 -0400 (EDT) Received: from mailfrontend2 ([10.202.2.163]) by compute5.internal (MEProxy); Sat, 06 Oct 2018 07:04:08 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=yuripv.net; h= subject:from:to:cc:references:message-id:date:mime-version :in-reply-to:content-type:content-transfer-encoding; s=fm3; bh=g jUVsowN+oYrjTcQcel7IqPxM5RnZwOF0Px4KbrJdKI=; b=j9976gwHZvEmfQCTB IgXJL1mkGW5eZgT6eNuKPF+LoNd74YHGRNCVx0D5cZeVtfCwYm9d4M9LThiFh8L9 fnbas2RBNEwL5Ah/+o6/WEVgNUXwydl/QYdy/aAvN51Tn5FYKy1mQUJzNTAM2dim cP2fgGRvUiC7akMmAj82kZHRnLc+geR26zvKD5fda2SZCijemxJNIPqEqhx5i20q 8UcHlNEObzNK9s/UX4a4ELEgztaD9Tsvy52AksMIOLjQzsHoQFIK9kOTDFJtmEbu GFNdCNke1Ow3gTpJHqSGMbdk6dbG+wfQy9D+bifol675lRijgzmaSIsBWavYAWCw Nn5Iw== DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= messagingengine.com; h=cc:content-transfer-encoding:content-type :date:from:in-reply-to:message-id:mime-version:references :subject:to:x-me-proxy:x-me-proxy:x-me-sender:x-me-sender :x-sasl-enc; s=fm3; bh=gjUVsowN+oYrjTcQcel7IqPxM5RnZwOF0Px4KbrJd KI=; b=aJG1PZOymisqj7/o+u8+qZU79vIqzErLskG76SdPRPI1oFGn5fFNLmth+ 5jHssRbPeFhOVcdbxLq3hlLcB735dZSJ6DXGx6bXeAxuhUTZHiGXJHqtntIY0gpp EJOVSIleheHmJf2+SHDD3rq88vQrIUtFxzZRENx/tOv6iqmZvdGmVJs936FKxk5W NG1PhGbGZQjz3VpP+I6gKrlw4kFmUHkPgXc57nlSp8a9McQtMnDmSt/nEhEuLTKf Cj7BctjHoBgNslcM3VysCYjRt7dk49k8P4UdBQgfvRIcKnslyl5GspdIyrepIzS7 mAOGjBV4thk9j+vdfQbyHeTm22BVg== X-ME-Sender: X-ME-Proxy: Received: from [192.168.1.2] (unknown [62.183.124.173]) by mail.messagingengine.com (Postfix) with ESMTPA id D2D7A102D3; Sat, 6 Oct 2018 07:04:05 -0400 (EDT) Subject: Re: [freebsd 11.2] net-snmpd incomplete mac addresses From: Yuri Pankov To: Patrick Lamaiziere , freebsd-ports@freebsd.org Cc: freebsd-net@freebsd.org References: <20181005133302.5f518dc6@mr185033.univ-rennes1.fr> <930810ba-b659-d571-de84-995c1c97f1e5@yuripv.net> Message-ID: Date: Sat, 6 Oct 2018 14:03:46 +0300 User-Agent: Mozilla/5.0 (Windows NT 10.0; WOW64; rv:60.0) Gecko/20100101 Thunderbird/60.2.1 MIME-Version: 1.0 In-Reply-To: <930810ba-b659-d571-de84-995c1c97f1e5@yuripv.net> Content-Type: text/plain; charset=utf-8; format=flowed Content-Language: en-US Content-Transfer-Encoding: 8bit X-BeenThere: freebsd-ports@freebsd.org X-Mailman-Version: 2.1.27 Precedence: list List-Id: Porting software to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 06 Oct 2018 11:04:16 -0000 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/