SCCM writing into the alm_hardware table

tvo1992
Tera Contributor

Hi,

 

I just completed a SCCM integration to ServiceNow.  When I reviewed the asset table I was surprised to find virtual CI records created by SCCM and inserted to the alm_hardware table.  The show XML indicates:

 

<sys_class_name>alm_hardware</sys_class_name>
<sys_created_by>SG-SCCM</sys_created_by>
<sys_created_on>2023-07-14 04:32:08</sys_created_on>
 
As far as I know the SCCM Service Graph Connector does not write into asset table.  I cannot find any transform map that does so.  My assumption is that some other background processes/schedule job is doing this.
 
Any insight?
 
Thanks,
Tom.
1 ACCEPTED SOLUTION

CMDB Whisperer
Mega Sage
Mega Sage

If the computer is registered in SCCM then it will be entered into the Computer (cmdb_ci_computer) table or possibly the Windows Server table (cmdb_ci_server_win).  If any virtual computer is entered in to the CMDB then it will create an asset by default, until you inform ServiceNow of which Product Model(s) are virtual computers and instruct the system not to create assets for those models.

 

To resolve this:

1.  Identify the Product Models for all virtual computers/servers.

2.  Go to those Product Model records and set the Asset Tracking Strategy to "Do not create assets"

3.  Since you have already created some assets, you will need to go to the asset records and select Delete Asset Only, so that the asset record will be deleted but the CI record will be retained.  You can also script this for all assets of a particular model in a Background Script or Fix Script. 

 

From that point on, new CIs for those specific product models will not result in Asset creation.  However, you will need to keep an eye on this and repeat the process as needed, since it is possible that new Models will be imported for different virtualization platforms, and each time a new Model is created, its default will be to create assets. 


The opinions expressed here are the opinions of the author, and are not endorsed by ServiceNow or any other employer, company, or entity.

View solution in original post

3 REPLIES 3

CMDB Whisperer
Mega Sage
Mega Sage

If the computer is registered in SCCM then it will be entered into the Computer (cmdb_ci_computer) table or possibly the Windows Server table (cmdb_ci_server_win).  If any virtual computer is entered in to the CMDB then it will create an asset by default, until you inform ServiceNow of which Product Model(s) are virtual computers and instruct the system not to create assets for those models.

 

To resolve this:

1.  Identify the Product Models for all virtual computers/servers.

2.  Go to those Product Model records and set the Asset Tracking Strategy to "Do not create assets"

3.  Since you have already created some assets, you will need to go to the asset records and select Delete Asset Only, so that the asset record will be deleted but the CI record will be retained.  You can also script this for all assets of a particular model in a Background Script or Fix Script. 

 

From that point on, new CIs for those specific product models will not result in Asset creation.  However, you will need to keep an eye on this and repeat the process as needed, since it is possible that new Models will be imported for different virtualization platforms, and each time a new Model is created, its default will be to create assets. 


The opinions expressed here are the opinions of the author, and are not endorsed by ServiceNow or any other employer, company, or entity.

Ashok Sasidhara
Tera Sage
Tera Sage

Yes. SCCM integration directly populates CMDB tables only (like cmdb_ci_computer & cmdb_ci_disk). But there is a business rule named 'Create Asset on insert' which will populate asset tables with new asset records when new CIs are created. This needs to be turned off if you don't need to create any assets at all.

 

But if you would like to control asset creation in a more granular manner, you can do it using attributes in either model category or product model records (This is the recommended method. The settings specified in individual models will override the settings in model categories if they conflict)

p_tishberg
Tera Guru

Tom,

I wanted to point out one warning regarding what Ashok has stated below.  Yes, the preferred method for controlling whether devices have their assets created only, their CI's created only or both created and maintaining synchronization between the asset and the ci.  The product model, as opposed to the Model Category or more importantly the Business Rule, should not be tampered with for this functional process.  

Most of the time, you want when a CI is discovered the system to create an asset record for the device and when you acquire an asset (ASN process prime example) you want a CI record to also be created.  That automatic creation is accomplished thru 2 business rules named 'Create Asset on insert' which will populate asset tables with new asset records when new CIs are created and the  business rule named 'Create CI on insert' which will populate CI tables with new CI records when new assets are created.

But the next sentence Ashok recommends as a solution for your question below states that  "This needs to be turned off if you don't need to create any assets at all.".  PLEASE DO NOT turn off any business rules unless you are fully aware of the implications in doing so.  I have firmly always believed that you don't turn off business rules but you mitigate through configuration, scripts, platform fields and special user created fields in existing or new tables.  Most firms have both CI's and Assets so the BR's are in place to ensure devices stay in sync between CMDB and AMDB.  For things like Software Licenses (Asset no CI),  Virtual Machine Instances (CI no Asset) you control that creation by defining the asset tracking strategy on the product model records (cmdb_model table).  There are 3 choices, "Leave to Category" - the default, "Do Not Create Assets" - put in place for Virtual Cis, and "Create Consumable Asset" (which  allows for non-uniqueness tracking for devices and no need for synchronization - think of device types like mice, keyboards, consumable items.