Newly discovered device shows old deleted devices Alias value.

Document ID : KB000008131
Last Modified Date : 14/02/2018
Show Technical Document Details
Issue:

Newly discovered device shows old deleted devices Alias value.

Environment:
Seen in r3.1. At time of issue discovery it is present in all CA Performance Manager releases.
Cause:

When a device is first discovered via any data source, we automatically set the intial value of Name Alias to the same value as the device Name. This is never updated/changed again without user interaction. It is stored in the t_device.AlternateName field value in the database.

If the DA is the only Data Source (DS) contributing that device, when it is deleted from the DA we remove its alias values.

If the DA is one of multiple DSs contributing that device, when it is deleted from the DA it is removed from the dst_device table.

But because other DSs also contribute this device, the t_device table entry remains that contains the initial value of AlternateName.

That is the case here due to the devices being contributed by the Spectrum and NFA DSs alongside the DA. Even though deleted from the DA the alternatename remains in t_device for these devices.

We intentionally don't update the alias value after first setting it post 1st time discovery in the event users are setting alias values manually. We don't want to overwrite those changes.

But that leaves customers such as this out in the cold due to this "loophole" (for lack of a better term...) in the code. This user never set the Alias and want's it to just match the real Name.

Resolution:

There are at this time two ways to fix this:

 

A: Delete the devices from the DA, Spectrum and NFA. When Global Sync shows updates after those actions, and the devices no longer appear in CAPM Global Search results, rediscover the devices in the DA, Spectrum and NFA. When it resyncs the new items to the PM inventory it will set the alternatename Alias to the Name and correct this.

NOTE: Option A means you will lose all historical polled data for the deleted device and any component elements related to it.

 

B: The preferred mechanism, is via REST. The REST method is detailed here with an example:

https://docops.ca.com/ca-performance-management/3-1/en/administrating/performance-center-rest-webservices/administration-web-services/devices-web-service/set-the-alias-name-for-a-device-example

Additional Information:

Sample output from database showing issue is as follows. Note the following details:

  • Real device names and IP addresses have been changed to sample values.
  • In this case we see where the customer replaced 3800 model devices with newer 3900 model devices.
  • The IP address for the newly updated device remained the same as the one used for the old device.
  • ItemName and DisplayName match which show the correct and expected new device name
  • AlternateName shows old ItemName from 'old' device element

 

mysql> select itemid,itemname,itemdesc,v6_ntoa(Address),displayname, alternatename from t_device where itemname like 'caTech%'\G; 

*************************** 1. row *************************** 

itemid: 4994 

itemname: caTech-rc392001.ca.com 

itemdesc: Cisco IOS Software, C3900 Software (C3900-UNIVERSALK9-M), Version 15.4(3)M5, RELEASE SOFTWARE (fc1) 

Technical Support: http://www.cisco.com/techsupport 

Copyright (c) 1986-2016 by Cisco Systems, Inc. 

Compiled Tue 09-Feb-16 06:02 by prod_rel_team 

v6_ntoa(Address): 1.1.1.1 

displayname: caTech-rc392001.ca.com 

alternatename: caTech-rc384001.ca.com 

*************************** 2. row *************************** 

itemid: 4995 

itemname: caTech-rc392002.ca.com 

itemdesc: Cisco IOS Software, C3900 Software (C3900-UNIVERSALK9-M), Version 15.4(3)M5, RELEASE SOFTWARE (fc1) 

Technical Support: http://www.cisco.com/techsupport 

Copyright (c) 1986-2016 by Cisco Systems, Inc. 

Compiled Tue 09-Feb-16 06:02 by prod_rel_team 

v6_ntoa(Address): 2.2.2.2

displayname: caTech-rc392002.ca.com 

alternatename: caTech-rc384002.ca.com 

2 rows in set (0.01 sec)