Syslog messages missing nodelabel, location, and interface

Description

Syslog event originated from a node in a remote location is missing fields nodelabel, location, and interface. Attached screenshot below.

 

It appears that this happens when OpenNMS fails to perform RDNS to resolve the hostname to IP address and thereby not associating the syslog event to a node although the node is provisioned in the requisition. Verified that OpenNMS can only resolve the FQDN of the node and minion can resolve both FQDN and hostname.

Check out the EventBuilder and SyslogMessage class for more info.

https://github.com/OpenNMS/opennms/blob/8940495002c118d981fd8b4b9f213d460259bc0c/features/events/syslog/src/main/java/org/opennms/netmgt/syslogd/ConvertToEvent.java#L151

https://github.com/OpenNMS/opennms/blob/8940495002c118d981fd8b4b9f213d460259bc0c/features/events/syslog/src/main/java/org/opennms/netmgt/syslogd/SyslogMessage.java#L273

 

Acceptance / Success Criteria

None

Attachments

5

Lucidchart Diagrams

Activity

Show:

Chandra Gorantla August 17, 2021 at 10:42 PM

Thanks  for verifying this issue.  Closing

JianYet August 17, 2021 at 10:15 PM
Edited

Verified the PR has fixed the issue. Testbed was set up leveraging Azure cloud. Had OpenNMS in one location/region while minion in another. Test machine was created at the same location, dns zone, and subnet as the minion. OpenNMS wasn't able to resolve hostname of the test machine but the minion can which is expected. Syslog message was sent from the test machine, forwarded by the minion, processed by OpenNMS, and nodelabel/interface/node location were populated correctly.

Chandra Gorantla August 16, 2021 at 1:39 PM

Chandra Gorantla August 10, 2021 at 8:51 PM

Chandra Gorantla August 9, 2021 at 9:23 PM

Looks like  If parsed hostname is not resolvable, we don't fallback to IP Address that we received from Minion.  I will try to reproduce the issue, let me know if you already have a setup to reproduce this.

Fixed

Details

Assignee

Reporter

FD#

Components

Sprint

Affects versions

Priority

PagerDuty

Created August 3, 2021 at 7:20 PM
Updated September 8, 2021 at 1:11 PM
Resolved August 17, 2021 at 9:20 PM