search cancel

Discovery Profiles Not showing up afer saving


Article ID: 200514


Updated On:


CA Infrastructure Management CA Performance Management - Usage and Administration DX NetOps


I am trying to create a new Discovery Profile on CAPC and after saving it, it does not show up.

The Discovery Profile list returns "No Data Available". There are many previously created Discovery Profiles that should appear.

Going to http://<DA_HOST>:8585/rest/discoveryprofiles returns an error. It states it is a "413: Request to large" error.


All supported Performance Management releases


Custom script issues REST calls to create Discovery Profiles and run them. It does not reuse existing Discovery Profiles. It does not delete the ones it creates and runs.

This results in an excessive count of Discovery Profiles. The following Vsql query will reveal how many are created. In this scenario we found 2.09 million Discovery Profiles generated.

select count(*) from dauser.v_item_facet where facet_qname like '%}DiscoveryProfile;

Sample lab output with just 3 profiles:

dauser=> select count(*) from dauser.v_item_facet where facet_qname like '%}DiscoveryProfile';
(1 row)

The Discovery Profile pane in the web UI uses the DA REST endpoint /rest/discoveryprofiles to build it's list. If the endpoint on it's own also returns a 413 error, there are to many entries for the response to be completed. As a result the UI list will be blank.


To resolve this we'll need to delete the majority of Discovery Profiles created.

This vsql query will generate a list of Discovery Profiles showing their item_id value in the DB, and their related name.

select item_id,name freom v_item where item_id in (select  item_id from v_item_facet where facet_qname like '%}DiscoveryProfile');

A lab sample matches the UI with just three Discovery Profiles.

dauser=> select item_id,name from v_item where item_id in (select item_id from v_item_facet where facet_qname like '%}DiscoveryProfile');
 item_id |      name
    1340 | Default Domain
    3986 | Sim Discovery
  132614 | Paris
(3 rows)

This is almost the same query. It generates a simpler list with only the item_ids from the first query.

dauser=> select item_id from v_item where item_id in (select item_id from v_item_facet where facet_qname like '%}DiscoveryProfile');
(3 rows)

Run the first command, then the second, putting the output from each into it's on text file.

Review the file with the names of the profiles from the first query output.

For any Discovery Profile that we'll keep, remove it's item_id from the item_id only list from the second query output.

That should leave a text file that contains ONLY the item_id values tied to the Discovery Profiles that will be deleted.

The main ones we'd recommended keeping are system generated ones from things like the Spectrum Integration. Usually called by the same name as a Domain it's related to. Default Domain would have the Default Domain named Discovery Profile. A domain named "Innova" would have a Discovery Profile named the same, "Innova". Etc., etc.

Lastly using the file with the final list of only item_id values for Discovery Profiles to delete, the following small script will iterate through the list. It will issue a REST DELETE via curl for each item_id in the list. 

Should result in all of them being deleted.

for itemid in `cat filename`
  curl -X DELETE http://<DA_Host>:8581/rest/discoveryprofiles/$itemid

Replace <DA_Host> with DA host name. If script is run on DA itself, can also specify localhost as host name.

After this, engineering recommends setting up one Discovery Profile per SNMP Profile configured. Then add the correct IPs to each and re-run them to associate them to the devices.

In the future update the pre-created profiles adding or removing IPs as needed and running them as needed or setting them to run on a schedule.