[SOLVED] SNMPD configuration - CANT PING WAN

Hello,

I did opkg install snmpd.

This is my config:

config agent
option agentaddress UDP:161,UDP6:161

config agentx
	option agentxsocket /var/run/agentx.sock

config com2sec public
	option secname ro
	option source any
	option community public

config com2sec private
	option secname rw
	option source localhost
	option community private

config com2sec6 public6
	option secname ro
	option source any
	option community public

config com2sec6 private6
	option secname rw
	option source localhost
	option community private

config group public_v1
	option group public
	option version v1
	option secname ro

config group public_v2c
	option group public
	option version v2c
	option secname ro

config group public_usm
	option group public
	option version usm
	option secname ro

config group private_v1
	option group private
	option version v1
	option secname rw

config group private_v2c
	option group private
	option version v2c
	option secname rw

config group private_usm
	option group private
	option version usm
	option secname rw

config view all
	option viewname all
	option type included
	option oid .1

config access public_access
	option group public
	option context none
	option version any
	option level noauth
	option prefix exact
	option read all
	option write none
	option notify none

config access private_access
	option group private
	option context none
	option version any
	option level noauth
	option prefix exact
	option read all
	option write all
	option notify all

config system
	option sysLocation	'office'
	option sysContact	'bofh@example.com'
	option sysName		'HeartOfGold'
#	option sysServices	72
#	option sysDescr		'adult playground'
#	option sysObjectID	'1.2.3.4'

config exec
	option name	filedescriptors
	option prog	/bin/cat
	option args	/proc/sys/fs/file-nr
#	option miboid	1.2.3.4

config engineid
#	option engineid 'LEDE'
	option engineidtype '3'
	option engineidnic 'eth0'

#config trapcommunity 'trapcommunity'
#	option community 'public'

#config trapsink
#	option host 'nms.system.com'
#	option community 'public'
#	option port '162'

#config trap2sink
#	option host 'nms.system.com'
#	option community 'secret'
#	option port '162'

#config informsink
#	option host 'nms.sytem.com'
#	option community 'public'
#	option port '162'

#config authtrapenable 'authtrapenable'
#	option enable '1'

#config v1trapaddress 'v1trapaddress'
#	option host '1.2.3.4'

#config trapsess 'trapsess'
#	option trapsess	'-v 3 -e 0x80001f88808c18d3f7b0000 -u trapuser -a MD5 -A administrator -l authPriv -x DES -X rootpasswd udp:127.0.0.1:162'

config snmpd general
	option enabled 1
	option ipv6 0
	option community public
	option location '10.110.1.45'
	option contact '10.110.1.45'
	option disks '/tmp,/jffs'
	option interfaces 'wlan0,br-lan,eth0.1,eth0,usb0'
#	list network 'wan'

What is wrong? i want to use SNMPv2c with Community String: Public
and read write community: private
It is not working? should do something to the firewall?

My server who is responsible of sharing ip is 192.168.5.5

What isn't working? SNMP service not starting? Is the router not listening on port 161? Are you trying to poll the router from the LAN or WAN?

If you are attempting to polling from the WAN, be sure to change the read and write community strings.

I have another question:

The included modem device in my MR6400 is running it is own android os. The interface is 192.168.0.1.

I have a 3g sim and connected to my private APN. Each sim has a static IP 10.1.23.100 to 10.1.23.200
Server IP: 10.110.1.40

My sim ip to this modem is for example: 10.1.1.23.110
If i go to modem i can ping 10.110.1.40 from inside openwrt. But if i want to ping the wan ip 10.1.23.110 from the server (10.110.1.40) i receive request timed out. I enabled everything from the modem firewall as accept. That is why i cant reach 161. any help?

It appears this entire section is wrong. Why did you edit the default config file???

I'm not sure the syntax of this sentence is clear...but did you allow SNMP on your LEDE firewall???

@davidc502 asked very important questions, please answer him for better solutions.

You title says "CANT PING WAN"...and you show SNMPD configs...please clarify the actual problem you're having.

Here you are.

I restored the default config file of snmpd.

At first i though i can't reach 161 later i found that i can't ping the device.

What i did i went to wan in openwrt -> Network -> interface. I changed the WAN IP to 192.168.0.100
Gateway: 192.168.0.1 (Included modem in MR6400) DNS 192.168.0.1.

I could now ping. I enabled the rules for 161. SNMP worked and ping is working.

This topic was automatically closed 3 days after the last reply. New replies are no longer allowed.