1Mono(Mono 1.0)                                                  Mono(Mono 1.0)
2
3
4

NAME

6       mono-service, mono-service2 - Mono ServiceProcess host
7

SYNOPSIS

9       mono-service [options] program.exe
10

DESCRIPTION

12       The  mono-service  is a host to run services built with the ServicePro‐
13       cess assembly.
14
15       Use mono-service to run services that use the 1.0  assemblies  and  use
16       mono-service2 to run services that use the 2.0 assemblies.
17
18       Services  can  be  paused by sending the SIGUSR1 signal to the process,
19       and execution can be resumed by sending the SIGUSR2 signal.   The  ser‐
20       vice  can  be  cleanly  shutdown  by  sending the SIGTERM signal to the
21       process.
22
23       Mono programs started with mono-service run with  the  MONO_DISABLE_SHM
24       variable  set.     This means that certain Mono features that depend on
25       it are not available to services.
26
27       The following options can be used to control the service:
28
29       -d:DIRECTORY
30              Use this option to specify the working directory  for  the  ser‐
31              vice.  The default is the current directory.
32
33       -l:LOCKFILE
34              Specifies the file to use for locking, the default is a filename
35              constructed in /tmp based on the name of the program that  hosts
36              the service.
37
38       -m:MESSAGE
39              Name to show in the syslog.
40
41       -n:NAME
42              Use  this  to specify the service to be launched (if the program
43              contains more than one service).   The default  is  to  run  the
44              first defined service.
45
46       --debug
47              Use  this  option to prevent mono-service from redirecting stdin
48              and stdout and prevent the program to be sent to the background.
49              Equivalent to --no-daemon
50
51       --no-daemon
52              Use  this  option to prevent mono-service from redirecting stdin
53              and stdout and prevent the program to be sent to the background.
54              Equivalent to --debug.
55

CONTROL

57       You  can control the service by sending signals to the process, you can
58       use the following commands:
59
60       Pausing service:
61                   kill -USR1 `cat <lock file>`
62
63       Resuming service:
64                   kill -USR2 `cat <lock file>`
65
66       Stopping the service:
67                   kill `cat <lock file>`
68

EXAMPLES

70       Start the MyService.exe assembly, with a lock in /root/service-lock:
71
72            mono-service -l:/root/service-lock MyService.exe
73
74

DEBUGGING

76       Messages produced by the service are logged on syslog.
77

MAILING LISTS

79       Visit http://lists.ximian.com/mailman/listinfo/mono-list for details.
80

WEB SITE

82       Visit: http://www.mono-project.com for details
83

SEE ALSO

85       mono(1)
86
87       N:System.ServiceProcess
88
89
90
91
92                                                                Mono(Mono 1.0)
Impressum