Idea Details

Ability to delete alarms from database

Last activity 12-19-2016 09:23 AM
ttahkapaa's profile image
09-09-2016 07:11 AM

In MSP environment we quite often have requirements to store alarms in database for one or more months. This is not a problem in a perfect IT environment, but due to IT and UIM features the tables containing alarm history are growing quite quickly quite large and that makes then USM alarm portlet unable to use "Show Historical" feature. The code in USM seems to retrieve the whole history into browser and then do the filtering in context there. One solution for this could be some kind of documented way do delete selected alarms from alarm history tables. Now the only supported way is to DROP all those tables, meaning lose all the history and that is not always so suitable in MSP production env. We though could easily delete lots of alarms there, an example: Informational alarms from interface_traffic probe sending 10s of alarms per cycle telling that some ports are having operational status: down.


Comments

09-13-2016 02:25 AM

Thanks Luc,

 

yep, I have already done something like that in production environment and now waiting sky to fall. I just would love that software supports this kind of real life needs. Anyway this is again a conflict between two WAD features, so not actually a bug because obviously USM was not designed to support that kind of numbers of alarms in history, and there is no designed way to delete these kind of alarm storms from database except delete everything (not a good way in production).

09-13-2016 02:05 AM

Via "unsupported" sql queries you can obtain DB info and delete them afterwards.

Example: (nas_transaction_log: detail messages and nas_transaction_summary: one entry for each nimid)

 

=> list # of messages for probe interface_traffic for each robot and level

 

select distinct robot, prid, level, COUNT(*) '#msg'
from NAS_TRANSACTION_LOG
where prid = 'interface_traffic'
group by robot,prid,level
order by '#msg' desc

 

=> delete all messages for a specifoc robot and probe interface_traffic and level 0 (=clear)

delete
from NAS_TRANSACTION_LOG
where robot = 'bgbulab47'
and prid = 'interface_traffic'
and level = '0'

 

*** test this out in a pre-production environment and take a backup of the DB: CA_UIM before the delete ***

09-09-2016 09:05 AM

Based on support, the only "supported" way to delete some alarms from database is DROP all those alarm tables, live and historical.

09-09-2016 09:01 AM

I'm not too familiar with the UIM API yet, but surely this is possible via the API? Other tools like Spectrum let you do this so I assume UIM would allow this too. It might help to look at the API documentation. I wouldn't suggest deleting things from the database directly as this isn't usually supported as much.