Sentinel provides a framework for the execution of system
monitoring tests. Individual tests are defined in a sentinel.conf file. Tests are
run at scheduled times as defined in the configuration file (similar in nature to crontab
schedule definitions). Tests can be contained in shared libraries which are loaded dynamically at
runtime or in separate executables (compiled or shell scripts).
Upon startup, Sentinel reads its configuration file, within which is defined all the
various tests to be run, required test parameters, and test schedules. If the test is contained
within a shared library object, the object is loaded at that time.
Each test can contain up to three separate entry points - an init(), run(),
and cleanup()
routine. Each init() routine is called by Sentinel for each test upon startup. This allows each
test to perform any initialization processing that might be required (opening files, allocating
data structures, etc). The test's run() routine is called at each scheduled time interval as
configured in the sentinel.conf file. It is during the run() stage that the specific
system test is performed. Finally, the cleanup() routine
is called upon shutdown of the process, allowing each individual test to release any
allocated resources (close files, free memory, etc.).
The following figure displays the basic design of this process.
Figure 1.
Source code: Sentinel Server,
Utility Routines,
Configuration File,
Sample Test
|