SNMP traps are not processed by midServer

rambhatia2017
Giga Contributor

Traps are received by midServer but they are not seen in Event form.

Have installed mid server in a Linux server

Have configured config.xml as follows

<parameter name="url" value="https://xxxx.service-now.com/"/>
<parameter name="mid.instance.username" value="xxxxx"/>
<parameter encrypt="true" name="mid.instance.password" value="encrypted:xxxx"/>
<parameter name="name" value="xxxxx"/>
<parameter name="mid.proxy.use_proxy" value="false"/>


One of my server is sending SNMP traps to mid Server. I can see that the traps are received by mid server using tcpdump

But for some reason, these traps are not seen in event form

Am able to ping xxxx.service-now.com from mid server

Have ensured that provided username & password are correct

In ServiceNow,

Mid Sever->servers, value of my midServer status is up & value of Validated = yes
Mid Server->Extensions->MID SNMP Trap Listener, for my trap extension value of status = started


No errors are seen in agent/logs/agent0.log.0

Can someone hep me - what else to check for ?

Thank you,
Ram

1 ACCEPTED SOLUTION

IP tables in the mid-server were not forwarding the udp traffic by default.


Hence traps were not sent to the mid-server application.


Once IP tables are updated to forward UDP traffic, the issue got resolved.



Thank you


Ram


View solution in original post

17 REPLIES 17

Hi Raj,

 

Wondering if mentioned IP table means IP table in mid-server application or is it Windows OS firewall thing?

 

Please help to share how to enable it, as I am also stuck in similar situation, where Server getting snmp trap packets (confirm via wireshark ) while can't see anywhere in mid

 

so, if you also please share steps, that will be really helpful.

Hi Ram, 

I have this exact issue. When you say update IP tables to forward UDP, is that on the network side, or in ServiceNow config?

Thanks

Mike

rambhatia2017
Giga Contributor

Jerrold



In your mid-server, in the file /etc/sysconfig/iptables



there might be some entries like



-A INPUT xxxxxx



After these entries and before REJECT entries, an entry to be added as:



-A INPUT -m state --state NEW -m udp -p udp --dport <port number> -j ACCEPT


For example:


-A INPUT -m state --state NEW -m udp -p udp --dport 1162 -j ACCEPT



After appending this line, iptables service needs to be restarted.



Having said this, it is not recommended to edit this file manually and new entry could be added using the command


iptables -I INPUT <line number> xxxxx



Value of <line number> depends on other entries in current configuration.



I would recommend you to contact your system administrator for updating iptables



If you need more information, please feel free to let me know.



Thank you


Ram