Notifications

142 views

Description

When scanning OS Servers using Probes versus using Patterns, we can see some inconsistent results in the Network Adapters table between these two methods.

The issues found so far are the following.

1) If discovering a Network Adapter that is valid and does not have an IPv4 address, but does have an IPv6 address, we do not create a cmdb_ci_network_adapter record for this using the Identity probe, however we do create this when using Patterns.

2) If discovering multiple Network Adapters against a Linux Server (not sure if this applies to other UNIX-based servers yet), the MAC Address value on these different adapters will all have the same value if using probes.
If using Patterns, this will correctly populate the MAC address values as expected.

Steps to Reproduce

1) Setup a Linux Server with the following critieria.
a) Make sure this has multiple Network Adapters with different MAC Address values
b) Make sure to setup one Network Adapter without an IPv4 address, but does have a valid IPv6 address

2) Setup your Linux Classification record to use probes (i.e. Linux - Identity) and disable using Patterns (i.e. the Linux Server pattern).
3) Run a Discovery scan against this Linux Server
-- You should be able to demonstrate both issues where you don't see the Network Adapter records for the one that only has the IPv6 address and you should see that all the Adapters you do find have the same MAC Address

4) Modify the Linux Classification record to now use Pattern instead of Probes (i.e. deactivate triggering the Linux - Identity probe and activate using the Linux Server pattern).
5) Run another Discovery scan against this Linux Server
-- You should now see a new group of Network Adapters get created, including a record for the IPv6 adapter and correct MAC address values on these adapters

Workaround

In both script include IDSensorUtil and MID Server script include IDSensorUtil, make changes in function getAdapters as follows:

replace:

 	if (!adapter) {
		adapter = this.createAdapter(adapterName,
		macAddressFunc(joinedOutput, adapterName, networkInfo[1]));
 		adapters[adapterName] = adapter;
 	}

with:

	if (!adapter) {
		if (adapterOpts.contains("ether") || adapterOpts.contains("HWaddr"))
			adapter = this.createAdapter(adapterName, macAddressFunc(parts[0], adapterName, networkInfo[1]));
		else
			adapter = this.createAdapter(adapterName, macAddressFunc(joinedOutput, adapterName, networkInfo[1]));
 		adapters[adapterName] = adapter;
	}

replace:

	if (!adapter) {
		this.createAdapter(adapterName, macAddressFunc(joinedOutput, adapterName, ipv6Info[1]));
		adapters[adapterName] = adapter;
	}

with:

 	if (!adapter) {
		if (adapterOpts.contains("ether") || adapterOpts.contains("HWaddr"))
			adapter = this.createAdapter(adapterName, macAddressFunc(parts[0], adapterName, ipv6Info[1]));
		else
			adapter = this.createAdapter(adapterName, macAddressFunc(joinedOutput, adapterName, ipv6Info[1]));
 		adapters[adapterName] = adapter;
 	}

 

 


Related Problem: PRB1265517

Seen In

There is no data to report.

Fixed In

London

Associated Community Threads

There is no data to report.

Article Information

Last Updated:2019-05-21 11:41:59
Published:2019-03-21