The configdir is the place where ESM stores it's
configuration. Usually the configdir /etc/esm However you may change
that with command line options. Each monitor and sender has it's own
configuration file. When esmd starts up it reads each file in
configdir and adds the monitors and senders configured.
Adding a plugin is very easy. There are only 3 things you have to
specify.
The title of the plugin.
The command to execute to run the plugin. esmd will get the
command and run it with /bin/sh -c "<string>" Note that
the plugin path (usually /usr/local/esm/plugins, changable
via the Makefile) will be the first part of the search path.
Specifies that the plugin is a monitor.
Specifies that the plugin is a daemon monitor.
Specifies that the plugin is a sender. # is the priority of the
sender. Each priority group will be tried one at a time. All senders
of priority 1 will be tried first, then 2 then 3 etc.
Now that you have your plugin config file just save it with
any name, althrough I recomend logical names so you don't go
insane when you update things. :)
The file esmconfig is special. If a config file is named that a
different set of rules apply. esmconfig is used to set general options
like the update interval. However the format of esmconfig is the same
as any other config file.
The interval between updates. On each update each monitor is run,
a system report is made and the results are sent back to you. Defaults
to 10m
The timeout on monitors. After # seconds the monitor is
killed if it hasn't exited already. Defaults to 1m
Same as above but for senders. Defaults to 2m
When a plugin is killed esmd sends it a few signals. First SIGINT,
then SIGHUP, then SIGKILL. Between each signal esmd waits so the
plugin has a chance to cleanly exit. module_kill_signal_interval
specifies how long esmd waits. Defaults to 5s
Adding plugins.
title <string>
cmd <string>
monitor
dmonitor
sender #
The esmconfig file.
updateinterval #
monitortimeout #
sendertimeout #
module_kill_signal_interval #
Example monitor config file
title ESM Date
cmd esmdate
monitor
Example sender config file
title Email Sender
cmd emailsender
sender 1
Example esmconfig file
updateinterval 1m
monitortimeout 10s
sendertimeout 10s
module_kill_signal_interval 3s
Index
© 1999 Peter Todd
Created on 09/12/1999 Last update - $Id: configdir.html,v 4.1 1999/10/07 23:22:10 pete Exp $