NetOps Portal models not mapped in Spectrum Oneclick
search cancel

NetOps Portal models not mapped in Spectrum Oneclick

book

Article ID: 30796

calendar_today

Updated On:

Products

CA Spectrum CA Performance Management - Usage and Administration DX NetOps

Issue/Introduction

Customers may see an issue with launching into NetOps Portal from Spectrum.  When they right click a device or interface in OneClick there is no option to launch into NetOps Portal

An error seen in NetOps Portal is that the Context ID is not a valid number or it loads a device that is incorrect.

When looking at CAPC_Item_Id  attribute on the model in OneClick, it will be 0 or the wrong number.

Environment

NetOps Portal 21.2.x, 22.2.x

Cause

Spectrum was removed and re-added as a datasource at some point.

Devices were removed from spectrum and replaced but with same name and IP.

Spectrum stores NetOps Portal<->OC model mapping in netqos_integ item_model_mapping table and in an "in-memory cache" on OneClick server.  

When Spectrum is deleted as a Data Source, neither this cache nor the table are cleared out.  

So when Spectrum is re-added as a datasource, the cache believes we have already synced the model and it will not write a new value to CAPC_Item_Id on the model in Spectrum.

Resolution

On the OneClick server, stop the tomcat service.

Use mysql and connect to netqos_integ database.

  1. In MS Windows Windows+R, and run bash -login. On Linux, open a terminal.

  2. cd $SPECROOT/mysql/bin

  3. Run;

    ./mysql --defaults-file=../my-spectrum.cnf -uroot -p<password for MySql> netqos_integ


  4. At the MySQL command prompt, run the following sql command:

    truncate item_model_mapping;

     

    quit

  5. Start the tomcat service.

When Spectrum connects to NetOps Portal, it will basically do a full sync and repopulate the item_model_mapping table and in-memory cache, which will cascade to CAPC_Item_Id attribute on models synced.

Additional Information

This can also cause events to not be sent to the correct model.  

If the item_model_mapping table is incorrect or not updated correctly, the events would be mapped to the wrong Spectrum device or no device at all.