'Discovery source' field is empty for cmdb_ci_spkg CI after Discovery is complete
This content was last updated in 2020. It may still be useful, but could contain outdated information. Please confirm its accuracy before relying on it.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
11-11-2020 02:29 AM
Dear Community,
as I haven't found the clear answer to the question, decided to raise it again here. After I complete the WMI Discovery for Windows Servers, I've got server CIs created together with multiple related CIs. All the CIs are populated with 'Discovery Source' = 'ServiceNow', but Software (cmdb_ci_spkg) remains empty.
Did anyone change the default sensors and can advise what exactly must be adjusted in order to set 'Discovery Source' = 'ServiceNow' for Software CIs (cmdb_ci_spkg)? I know there is a sensor called 'Windows - Installed Software', that does
this.addToRelatedList('cmdb_ci_spkg', filteredPackages, '', '');
but after checking 'filteredPackages' variable and called 'InstallSoftwareFilter' script include, I still couldn't identify the line to set the discovery source field.
Appreciated for the help.
- Labels:
-
Discovery
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
11-11-2020 04:33 AM
yes for cmdb_ci_spkg dsicovery source is not populated.
you can add step to set discovery type concerned pattern[refer screen shot to discovery type]

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
11-11-2020 04:41 AM
Hi
I guess the discovery type is different from discovery source, this will give you discovery type whether horizontal/service mapping but discovery source has ServiceNow or ServiceWatch etc..
I guess the discovery source is set in the discovery flow by the discovery engine and not handled in patterns.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
11-11-2020 05:30 AM
Right, 'Discovery Source' field is set in the Script Includes, like 'DiscoveryIDSensor'. The challenge is to find out, how this can be aligned to cmdb_ci_spkg class discovery.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
11-11-2020 05:57 AM
Sorry my bad i thought you are looking for discovery type.
You can this line to your script include to populate discovery source .
var sourceName = gs.getProperty('glide.discovery.source_name', "ServiceNow");
Then you need to set the source using glide record api