Added a new degrade action result code (161) to degrade the open-ldap service if FD limit is reached. Result code 160 indicates open FD is approaching to the limit, it will reset the degraded state as well as normal result code 0. SM was not designed to raise service level warnings/alarms. A major alarms will be raised by collectd when open-ldap open file descriptors is approaching to the limit (above 95%), and a critical alarm will be raised when the limit is reached (100%). Ref collectd changes: https://review.opendev.org/c/starlingx/monitoring/+/819137 Partial-bug: 1952126 Change-Id: I893c137ab81fcf01e949c9ca13cedcbe8fe5d86d Signed-off-by: Bin Qian <bin.qian@windriver.com>
The SM database is generated by the corresponding SQL scripts:
create_sm_db.sql -> sm.db
create_sm_hb_db.sql -> sm.db.hb
Instructions:
1. Update the corresponding SQL script i.e, create_sm_db.sql or create_sm_hb_db.sql:
Add proper SQL statement(s) (insert, update, delete) to the sql file.