Reputation: 21
Does the Linux SNMP agent support IPv6? I'm working with net-snmp 5.5. It's working fine with IPv4 address set and get operations, but with an IPv6 address it leads to unknown host.
What's the problem, and how do I resolve it?
Upvotes: 2
Views: 11198
Reputation: 11057
In addition to listening for udp6 packets, it also seems you must specify an additional, separate community for ipv6 requests. Without both changes to snmpd.conf snmp queries via ipv6 are ignored.
agentAddress udp:161,udp6:161
rocommunity6 public default
Upvotes: 4
Reputation: 560
Happened to come across this question while searching for something else and figured I could add my 2 cents.
The IPv6 address in a net-snmp command is a little different from an IPv4 address. You need to use the udp6: prefix and specify the port number.
"udp6:[<ipv6 address here>]:161"
The full command should look something like this:
snmpset -v 1 -c private "udp6:[<ipv6 address here>]:161" 1.3.6.1.4.1.318.1.1.26.4.4.1.4.1 i 7
edit: this works for a Windows environment, but may be the same for Linux
Upvotes: 4