/[monit]/monit/monit.pod
ViewVC logotype

Diff of /monit/monit.pod

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 1.64 by hauk, Sun Mar 2 14:15:22 2003 UTC revision 1.65 by hauk, Wed Apr 30 23:24:22 2003 UTC
# Line 1112  much easier to read at a glance. The pun Line 1112  much easier to read at a glance. The pun
1112   start           The program for starting the specified   start           The program for starting the specified
1113                   process. Full path is required. This                   process. Full path is required. This
1114                   statement is optional.                   statement is optional.
1115     uid and gid     Optional part of the start statement. May
1116                     be used to specify a user id and a group id
1117                     the program should be started as. The uid
1118                     and gid may be specified as a name or as a
1119                     number. This extension can only be used if
1120                     the super-user is running monit.
1121   stop            The program for stopping the specified   stop            The program for stopping the specified
1122                   process -- full path is required. This                   process -- full path is required. This
1123                   statement is optional.                   statement is optional.
# Line 1275  for the process to stop and then execute Line 1281  for the process to stop and then execute
1281     port 80       port 80  
1282     port 443     port 443
1283    
1284    This example demonstrate how you can run a program as a specified
1285    user (uid) and with a specified group (gid). Many daemon programs
1286    will do the uid and gid switch by itself, but for those programs
1287    that does not (e.g. java programs), monit's ability to start a
1288    program as a certain user can be very useful.  In this example we
1289    start the Tomcat Java Servlet Engine as the standard I<nobody>
1290    user and group. Please note that monit will only change uid and
1291    gid for a program if the super-user is running monit, otherwise
1292    monit will simply ignore the request to change uid and gid.
1293    
1294     check tomcat with pidfile /var/run/tomcat.pid
1295       start program = "/etc/init.d/tomcat start"
1296          as uid nobody and gid nobody
1297       stop program  = "/etc/init.d/tomcat stop"
1298          # You can also use id numbers instead and write:
1299          as uid 99 and with gid 99
1300       port 8080
1301    
1302    
1303  In this example we use udp for connection testing to check if the  In this example we use udp for connection testing to check if the
1304  'named' service is running and also use timeout and alert:  'named' service is running and also use timeout and alert:
1305    

Legend:
Removed from v.1.64  
changed lines
  Added in v.1.65

savannah-hackers-public@gnu.org
ViewVC Help
Powered by ViewVC 1.1.26