How to validate Reconciliation Engine configuration

RahulY00040
Tera Contributor

Hello everyone,

We have multiple data sources populating Hardware CIs and their child CIs in the CMDB. For each source, we have configured Reconciliation Definitions, some with unique priorities and others sharing the same priority level.

We would now like to validate each Reconciliation Definition against its corresponding data source and the CIs currently present in the CMDB.

Could you please advise on:

  • How to perform this validation effectively?
  • Which tables should be referenced when validating IRE behavior using the createOrUpdateCIEnhanced() API?
  • What is the significance of the cmdb_datasource_last_update table in this context?

Thanks in advance,
Rahul

1 ACCEPTED SOLUTION

Hi @RahulY00040,

With the following script, you can insert the generated payload as outlined in the previous post to the CMDB and trigger both Identification and Reconciliation Rules. You only need to set the discovery source according to your environment. The records will be visible in the multi source table as well, once you enabled the feature.

 

Please make sure to do this in sub-prod systems only.

 

I also updated the initial post based on your feedback. Thank you for bringing this topic up. This is option 1 from the examples of how to reuse the mock data. 

 

var payload = {
   "items": [],
   "relations": []
}

var jsonUtil = new JSON();
var input = jsonUtil.encode(payload);
var output = SNC.IdentificationEngineScriptableApi.createOrUpdateCI('SOURCE', input);
gs.print(output);

 

Hope this helps!

View solution in original post

5 REPLIES 5

CasperJT
Tera Guru

Hi Rahul,

 

It sounds like you have a perfect use case for CMDB 360 (previously Multisource CMDB). CMDB 360/Multisource CMDB

 

The CMDB 360 lets you prioritize which attributes are updated by which data sources and you can see the history of each source.

 

This post discusses testing the IRE. Identification Simulation: Testing IRE Rules and C... 

Generally I would recommend testing your data source in a non-prod environment and reviewing the data utilizing the capabilities of CMDB 360.

 

cmdb_datasource_last_update: 

https://www.servicenow.com/docs/r/servicenow-platform/configuration-management-database-cmdb/create-....

Information about the last discovery source that updates each attribute is stored in the Data Source History [cmdb_datasource_last_update] table, but only after enabling the reconciliation rule. Therefore, there might be unexpected updates after you enable the rule until the highest priority data source has updated the CI.

 

Hope this helps.

 

//CasperJT

fknell
Tera Patron

Hi @RahulY00040,

You can simulate the IRE as described in my post to verify your rules. Identification Simulation: Testing IRE Rules and Creating Mock Data 

 

Hope this helps!

RahulY00040
Tera Contributor

This covers the Identification part of it. I am looking to validate and justify how different attributes getting updated when different Discovery Sources try to update the CI attributes. E.g. how to validate & justify if configured Reconciliation Rules work to update attributes such as name, hostname, etc. Also, how entries get updated in this table-cmdb_datasource_last_update? What would happen if entries get deleted from this table? 

 

Thanks,
Rahul

Hi @RahulY00040,

With the following script, you can insert the generated payload as outlined in the previous post to the CMDB and trigger both Identification and Reconciliation Rules. You only need to set the discovery source according to your environment. The records will be visible in the multi source table as well, once you enabled the feature.

 

Please make sure to do this in sub-prod systems only.

 

I also updated the initial post based on your feedback. Thank you for bringing this topic up. This is option 1 from the examples of how to reuse the mock data. 

 

var payload = {
   "items": [],
   "relations": []
}

var jsonUtil = new JSON();
var input = jsonUtil.encode(payload);
var output = SNC.IdentificationEngineScriptableApi.createOrUpdateCI('SOURCE', input);
gs.print(output);

 

Hope this helps!