"DNS Name for CI" related list is not getting populated for Linux servers


Description

Running a discovery on a linux server may result in not populating the "DNS Name for CI" related list even though we see the DNS information in the discovery logs and data getting populated in the DNS tables.

Release or Environment

Any

Cause

In Sys_relationship table we have a record called: DNS Names for CIs and this script is responsible for populating the DNS Name for CI related list

https://<<instance-name>>.service-now.com/sys_relationship.do?sys_id=8203b8b30ab301520035533a59ed530f&sysparm_record_target=sys_relationship&sysparm_record_row=1&sysparm_record_rows=1&sysparm_record_list=sys_idSTARTSWITH8203b8b30ab301520035533a59ed530f%5EORDERBYname

As part of this script we are doing a query in the IP address table with Ipaddress.nic.ci but while doing this we are checking in the cmdb_ci_ip_address table for this IP and if we find multiple IP's here it is causing a confusion and the related list is not getting populated.

Resolution

1. Delete all the empty records from "cmdb_ci_ip_address" table with NIC=empty and CI=empty.

2. Re-run the discovery and we should see "DNS Name for CI" related list getting populated.