Discussion:
snmpwalk and ipv6 address
(too old to reply)
Pushpa Thimmaiah
2015-11-03 12:35:56 UTC
Permalink
Hi Folks,

I am using ubuntu and ifconfig eth0 says 'inet6 addr:*
fe80::3e97:eff:fe8b:f326/64'*
I have tried snmpwalk with ipv6 ipaddress (mentioned below) and it works
fine
snmpwalk -v 2c -c public1 'udp6:[::1]:161'

But snmpwalk fails when i used fe80::3e97:eff:fe8b:f326

$ snmpwalk -v 2c -c public1 "udp6:[fe80::3e97:eff:fe8b:f326]:161"
Timeout: No Response from udp6:[fe80::3e97:eff:fe8b:f326]:161

snmpget -v 2c -c public1 udp6:'[*fe80::3e97:eff:fe8b:f326*%eth0]':161
.1.3.6.1.2.1.1.1.0
Timeout: No Response from udp6:[fe80::3e97:eff:fe8b:f326%eth0]:161.


Details:
1. ping works
$ ping6 -c 5 -I eth0 fe80::3e97:eff:fe8b:f326
PING fe80::3e97:eff:fe8b:f326(fe80::3e97:eff:fe8b:f326) from
fe80::3e97:eff:fe8b:f326 eth0: 56 data bytes
64 bytes from fe80::3e97:eff:fe8b:f326: icmp_seq=1 ttl=64 time=0.034 ms
64 bytes from fe80::3e97:eff:fe8b:f326: icmp_seq=2 ttl=64 time=0.047 ms

2. snmpagent listening to ipv6 address and community name 'public1' is ipv6
rocommunity6 public1 default
agentAddress udp:161,udp6:[::1]:161,tcp:161,tcp6:[::1]:161

3. ipv6 enabled
~$ net-snmp-config --configure
'--build=x86_64-linux-gnu' '--includedir=/usr/include'
'--mandir=/usr/share/man' '--infodir=/usr/share/info'
'--localstatedir=/var' '--libexecdir=/usr/lib/net-snmp'
'--disable-maintainer-mode' '--disable-dependency-tracking' '--prefix=/usr'
'--sysconfdir=/etc' '--mandir=/usr/share/man'
'--with-persistent-directory=/var/lib/snmp'
'--enable-ucd-snmp-compatibility' '--enable-shared' '--with-cflags=-g -O2
-fstack-protector --param=ssp-buffer-size=4 -Wformat -Wformat-security
-DNETSNMP_USE_INLINE' '--with-perl-modules=INSTALLDIRS=vendor'
'--enable-as-needed' *'--enable-ipv6'* '--with-logfile=none'
'--without-rpm' '--with-libwrap' '--with-openssl' '--without-dmalloc'
'--without-efence' '--without-rsaref' '--with-sys-contact=root'
'--with-sys-location=Unknown' '--with-mib-modules=host smux ucd-snmp/dlmod
ucd-snmp/diskio ucd-snmp/lmSensors host' '--with-out-mib-modules='
'--enable-mfd-rewrites' '--with-mnttab=/etc/mtab'
'--with-mibdirs=/home/test/.snmp/mibs:/usr/share/mibs/site:/usr/share/snmp/mibs:/usr/share/mibs/iana:/usr/share/mibs/ietf:/usr/share/mibs/netsnmp'
'--with-defaults' 'build_alias=x86_64-linux-gnu' 'CFLAGS=-g -O2
-fstack-protector --param=ssp-buffer-size=4 -Wformat -Wformat-security'
'LDFLAGS=-Wl,-Bsymbolic-functions -Wl,-z,relro'
'CPPFLAGS=-D_FORTIFY_SOURCE=2'
***@CLPMYSFC067:~$

Please let me know for more details

Thank you,
Pushpa.T
Pushpa Thimmaiah
2015-11-03 12:37:06 UTC
Permalink
I found similar issue discussed in
Post by Pushpa Thimmaiah
Hi Folks,
I am using ubuntu and ifconfig eth0 says 'inet6 addr:*
fe80::3e97:eff:fe8b:f326/64'*
I have tried snmpwalk with ipv6 ipaddress (mentioned below) and it works
fine
snmpwalk -v 2c -c public1 'udp6:[::1]:161'
But snmpwalk fails when i used fe80::3e97:eff:fe8b:f326
$ snmpwalk -v 2c -c public1 "udp6:[fe80::3e97:eff:fe8b:f326]:161"
Timeout: No Response from udp6:[fe80::3e97:eff:fe8b:f326]:161
snmpget -v 2c -c public1 udp6:'[*fe80::3e97:eff:fe8b:f326*%eth0]':161
.1.3.6.1.2.1.1.1.0
Timeout: No Response from udp6:[fe80::3e97:eff:fe8b:f326%eth0]:161.
1. ping works
$ ping6 -c 5 -I eth0 fe80::3e97:eff:fe8b:f326
PING fe80::3e97:eff:fe8b:f326(fe80::3e97:eff:fe8b:f326) from
fe80::3e97:eff:fe8b:f326 eth0: 56 data bytes
64 bytes from fe80::3e97:eff:fe8b:f326: icmp_seq=1 ttl=64 time=0.034 ms
64 bytes from fe80::3e97:eff:fe8b:f326: icmp_seq=2 ttl=64 time=0.047 ms
2. snmpagent listening to ipv6 address and community name 'public1' is ipv6
rocommunity6 public1 default
agentAddress udp:161,udp6:[::1]:161,tcp:161,tcp6:[::1]:161
3. ipv6 enabled
~$ net-snmp-config --configure
'--build=x86_64-linux-gnu' '--includedir=/usr/include'
'--mandir=/usr/share/man' '--infodir=/usr/share/info'
'--localstatedir=/var' '--libexecdir=/usr/lib/net-snmp'
'--disable-maintainer-mode' '--disable-dependency-tracking' '--prefix=/usr'
'--sysconfdir=/etc' '--mandir=/usr/share/man'
'--with-persistent-directory=/var/lib/snmp'
'--enable-ucd-snmp-compatibility' '--enable-shared' '--with-cflags=-g -O2
-fstack-protector --param=ssp-buffer-size=4 -Wformat -Wformat-security
-DNETSNMP_USE_INLINE' '--with-perl-modules=INSTALLDIRS=vendor'
'--enable-as-needed' *'--enable-ipv6'* '--with-logfile=none'
'--without-rpm' '--with-libwrap' '--with-openssl' '--without-dmalloc'
'--without-efence' '--without-rsaref' '--with-sys-contact=root'
'--with-sys-location=Unknown' '--with-mib-modules=host smux ucd-snmp/dlmod
ucd-snmp/diskio ucd-snmp/lmSensors host' '--with-out-mib-modules='
'--enable-mfd-rewrites' '--with-mnttab=/etc/mtab'
'--with-mibdirs=/home/test/.snmp/mibs:/usr/share/mibs/site:/usr/share/snmp/mibs:/usr/share/mibs/iana:/usr/share/mibs/ietf:/usr/share/mibs/netsnmp'
'--with-defaults' 'build_alias=x86_64-linux-gnu' 'CFLAGS=-g -O2
-fstack-protector --param=ssp-buffer-size=4 -Wformat -Wformat-security'
'LDFLAGS=-Wl,-Bsymbolic-functions -Wl,-z,relro'
'CPPFLAGS=-D_FORTIFY_SOURCE=2'
Please let me know for more details
Thank you,
Pushpa.T
Bill Fenner
2015-11-09 18:53:16 UTC
Permalink
You configured snmpd to listen on ::1, but you
asked fe80::3e97:eff:fe8b:f326. It's not listening
on fe80::3e97:eff:fe8b:f326, so it will not respond. As you say, when you
make your request to ::1, it works.

"udp6:[::1]:161" is the equivalent of "udp:127.0.0.1:161". If you want to
listen to the wildcard, you don't specify an address -- just use "udp6:161".

Bill
Post by Pushpa Thimmaiah
Hi Folks,
I am using ubuntu and ifconfig eth0 says 'inet6 addr:*
fe80::3e97:eff:fe8b:f326/64'*
I have tried snmpwalk with ipv6 ipaddress (mentioned below) and it works
fine
snmpwalk -v 2c -c public1 'udp6:[::1]:161'
But snmpwalk fails when i used fe80::3e97:eff:fe8b:f326
$ snmpwalk -v 2c -c public1 "udp6:[fe80::3e97:eff:fe8b:f326]:161"
Timeout: No Response from udp6:[fe80::3e97:eff:fe8b:f326]:161
snmpget -v 2c -c public1 udp6:'[*fe80::3e97:eff:fe8b:f326*%eth0]':161
.1.3.6.1.2.1.1.1.0
Timeout: No Response from udp6:[fe80::3e97:eff:fe8b:f326%eth0]:161.
1. ping works
$ ping6 -c 5 -I eth0 fe80::3e97:eff:fe8b:f326
PING fe80::3e97:eff:fe8b:f326(fe80::3e97:eff:fe8b:f326) from
fe80::3e97:eff:fe8b:f326 eth0: 56 data bytes
64 bytes from fe80::3e97:eff:fe8b:f326: icmp_seq=1 ttl=64 time=0.034 ms
64 bytes from fe80::3e97:eff:fe8b:f326: icmp_seq=2 ttl=64 time=0.047 ms
2. snmpagent listening to ipv6 address and community name 'public1' is ipv6
rocommunity6 public1 default
agentAddress udp:161,udp6:[::1]:161,tcp:161,tcp6:[::1]:161
3. ipv6 enabled
~$ net-snmp-config --configure
'--build=x86_64-linux-gnu' '--includedir=/usr/include'
'--mandir=/usr/share/man' '--infodir=/usr/share/info'
'--localstatedir=/var' '--libexecdir=/usr/lib/net-snmp'
'--disable-maintainer-mode' '--disable-dependency-tracking' '--prefix=/usr'
'--sysconfdir=/etc' '--mandir=/usr/share/man'
'--with-persistent-directory=/var/lib/snmp'
'--enable-ucd-snmp-compatibility' '--enable-shared' '--with-cflags=-g -O2
-fstack-protector --param=ssp-buffer-size=4 -Wformat -Wformat-security
-DNETSNMP_USE_INLINE' '--with-perl-modules=INSTALLDIRS=vendor'
'--enable-as-needed' *'--enable-ipv6'* '--with-logfile=none'
'--without-rpm' '--with-libwrap' '--with-openssl' '--without-dmalloc'
'--without-efence' '--without-rsaref' '--with-sys-contact=root'
'--with-sys-location=Unknown' '--with-mib-modules=host smux ucd-snmp/dlmod
ucd-snmp/diskio ucd-snmp/lmSensors host' '--with-out-mib-modules='
'--enable-mfd-rewrites' '--with-mnttab=/etc/mtab'
'--with-mibdirs=/home/test/.snmp/mibs:/usr/share/mibs/site:/usr/share/snmp/mibs:/usr/share/mibs/iana:/usr/share/mibs/ietf:/usr/share/mibs/netsnmp'
'--with-defaults' 'build_alias=x86_64-linux-gnu' 'CFLAGS=-g -O2
-fstack-protector --param=ssp-buffer-size=4 -Wformat -Wformat-security'
'LDFLAGS=-Wl,-Bsymbolic-functions -Wl,-z,relro'
'CPPFLAGS=-D_FORTIFY_SOURCE=2'
Please let me know for more details
Thank you,
Pushpa.T
------------------------------------------------------------------------------
_______________________________________________
Net-snmp-users mailing list
https://lists.sourceforge.net/lists/listinfo/net-snmp-users
Pushpa Thimmaiah
2015-11-10 07:12:16 UTC
Permalink
Thank you Bill Fenner. I will try the same.
Post by Bill Fenner
You configured snmpd to listen on ::1, but you
asked fe80::3e97:eff:fe8b:f326. It's not listening
on fe80::3e97:eff:fe8b:f326, so it will not respond. As you say, when you
make your request to ::1, it works.
"udp6:[::1]:161" is the equivalent of "udp:127.0.0.1:161". If you want
to listen to the wildcard, you don't specify an address -- just use
"udp6:161".
Bill
On Tue, Nov 3, 2015 at 7:35 AM, Pushpa Thimmaiah <
Post by Pushpa Thimmaiah
Hi Folks,
I am using ubuntu and ifconfig eth0 says 'inet6 addr:*
fe80::3e97:eff:fe8b:f326/64'*
I have tried snmpwalk with ipv6 ipaddress (mentioned below) and it works
fine
snmpwalk -v 2c -c public1 'udp6:[::1]:161'
But snmpwalk fails when i used fe80::3e97:eff:fe8b:f326
$ snmpwalk -v 2c -c public1 "udp6:[fe80::3e97:eff:fe8b:f326]:161"
Timeout: No Response from udp6:[fe80::3e97:eff:fe8b:f326]:161
snmpget -v 2c -c public1 udp6:'[*fe80::3e97:eff:fe8b:f326*%eth0]':161
.1.3.6.1.2.1.1.1.0
Timeout: No Response from udp6:[fe80::3e97:eff:fe8b:f326%eth0]:161.
1. ping works
$ ping6 -c 5 -I eth0 fe80::3e97:eff:fe8b:f326
PING fe80::3e97:eff:fe8b:f326(fe80::3e97:eff:fe8b:f326) from
fe80::3e97:eff:fe8b:f326 eth0: 56 data bytes
64 bytes from fe80::3e97:eff:fe8b:f326: icmp_seq=1 ttl=64 time=0.034 ms
64 bytes from fe80::3e97:eff:fe8b:f326: icmp_seq=2 ttl=64 time=0.047 ms
2. snmpagent listening to ipv6 address and community name 'public1' is
ipv6
rocommunity6 public1 default
agentAddress udp:161,udp6:[::1]:161,tcp:161,tcp6:[::1]:161
3. ipv6 enabled
~$ net-snmp-config --configure
'--build=x86_64-linux-gnu' '--includedir=/usr/include'
'--mandir=/usr/share/man' '--infodir=/usr/share/info'
'--localstatedir=/var' '--libexecdir=/usr/lib/net-snmp'
'--disable-maintainer-mode' '--disable-dependency-tracking' '--prefix=/usr'
'--sysconfdir=/etc' '--mandir=/usr/share/man'
'--with-persistent-directory=/var/lib/snmp'
'--enable-ucd-snmp-compatibility' '--enable-shared' '--with-cflags=-g -O2
-fstack-protector --param=ssp-buffer-size=4 -Wformat -Wformat-security
-DNETSNMP_USE_INLINE' '--with-perl-modules=INSTALLDIRS=vendor'
'--enable-as-needed' *'--enable-ipv6'* '--with-logfile=none'
'--without-rpm' '--with-libwrap' '--with-openssl' '--without-dmalloc'
'--without-efence' '--without-rsaref' '--with-sys-contact=root'
'--with-sys-location=Unknown' '--with-mib-modules=host smux ucd-snmp/dlmod
ucd-snmp/diskio ucd-snmp/lmSensors host' '--with-out-mib-modules='
'--enable-mfd-rewrites' '--with-mnttab=/etc/mtab'
'--with-mibdirs=/home/test/.snmp/mibs:/usr/share/mibs/site:/usr/share/snmp/mibs:/usr/share/mibs/iana:/usr/share/mibs/ietf:/usr/share/mibs/netsnmp'
'--with-defaults' 'build_alias=x86_64-linux-gnu' 'CFLAGS=-g -O2
-fstack-protector --param=ssp-buffer-size=4 -Wformat -Wformat-security'
'LDFLAGS=-Wl,-Bsymbolic-functions -Wl,-z,relro'
'CPPFLAGS=-D_FORTIFY_SOURCE=2'
Please let me know for more details
Thank you,
Pushpa.T
------------------------------------------------------------------------------
_______________________________________________
Net-snmp-users mailing list
https://lists.sourceforge.net/lists/listinfo/net-snmp-users
Loading...