removing stale records from cmdb_rel_ci table
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
02-13-2024 01:54 AM
Hi Guys,
We wanted to remove stale records from cmdb_rel_ci table, we would like to know what criteria can use to remove stale relationships records.
We have been thinking below criteria
Criteria 1 : Parent CI is retired AND Parent's most recent discovery before 12 months AND cmdb_rel_ci record is updated more than 1 year ago
Criteria 2 : Child CI is retired AND Child's most recent discovery before 12 months AND cmdb_rel_ci record is updated more than 1 year ago
Criteria 3: Parent is retire AND Child is retired AND Parent's most recent discovery is more than 12 months ago AND cmdn_rel_ci record updated 1 year ago.
Thank you
Somnath Shilimkar
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
02-13-2024 02:55 AM
OOTB, SN use this condition
If my response proves useful, please indicate its helpfulness by selecting " Accept as Solution" and " Helpful." This action benefits both the community and me.
Regards
Dr. Atul G. - Learn N Grow Together
ServiceNow Techno - Functional Trainer
LinkedIn: https://www.linkedin.com/in/dratulgrover
YouTube: https://www.youtube.com/@LearnNGrowTogetherwithAtulG
Topmate: https://topmate.io/atul_grover_lng [ Connect for 1-1 Session]
****************************************************************************************************************
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
02-13-2024 08:39 AM
Please set up the staleness rule for the CIs according to your criteria run the Correctness health job and then run the relationship health job to compute to stale and orphan relationships.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
02-13-2024 09:36 AM
Hi @Somnath Shilimk,
This could quite quickly turn into a bigger and wider conversation so I'll try and answer your question directly and simply (at first).
Your thought process outlined seems logical.
As you've probably read, CMDB Health measures CI relationship health in 3 ways in the baseline configuration:
- Orphan relationships: A relationship that is missing a parent or missing a child.
- Duplicate relationships: A relationships that have an identical parent, child and relationship type.
(and what's relevant for you)
- Stale relationships: A relationship in which one of the CIs is stale. For a stale CI – its associated relationships are also stale
The stale relationship is purely measuring if a CI has been updated within a specific number of days (for example, 90 days) so the additional aspects you bring certainly seem logical and add to the simple example SN provides.
The health highlights why CI ownership and maintenance (reminders and a program about confirming CI statuses) help with the bigger picture.
I would also consider the other 2 CI relationships outlined above in your review - Orphan relationships and Duplicate relationships.
To help others (or for me to help you more directly), please mark this response correct by clicking on Accept as Solution and/or Helpful.
Thanks, Robbie
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
02-15-2024 07:45 AM - edited 02-20-2024 01:36 AM
Hi @Somnath Shilimk,
How are you getting on? Did you see my earlier response?
This could quite quickly turn into a bigger and wider conversation so I'll try and answer your question directly and simply (at first).
Your thought process outlined seems logical.
As you've probably read, CMDB Health measures CI relationship health in 3 ways in the baseline configuration:
- Orphan relationships: A relationship that is missing a parent or missing a child.
- Duplicate relationships: A relationships that have an identical parent, child and relationship type.
(and what's relevant for you)
- Stale relationships: A relationship in which one of the CIs is stale. For a stale CI – its associated relationships are also stale
The stale relationship is purely measuring if a CI has been updated within a specific number of days (for example, 90 days) so the additional aspects you bring certainly seem logical and add to the simple example SN provides.
The health highlights why CI ownership and maintenance (reminders and a program about confirming CI statuses) help with the bigger picture.
I would also consider the other 2 CI relationships outlined above in your review - Orphan relationships and Duplicate relationships.
To help others (or for me to help you more directly), please mark this response correct by clicking on Accept as Solution and/or Helpful.
Thanks, Robbie