logo

oasis-root

Compiled tree of Oasis Linux based on own branch at <https://hacktivis.me/git/oasis/> git clone https://anongit.hacktivis.me/git/oasis-root.git

rundeux.8 (3285B)


  1. .\" rundeux.8
  2. .\" wcm, 2009.12.11 - 2009.12.15
  3. .\" ===
  4. .TH rundeux 8 "January 2013" "runtools-2.07" "runtools"
  5. .SH NAME
  6. rundeux \- run a program with an associated logger
  7. .SH SYNOPSIS
  8. .B rundeux [\-hV] [\-d] [\-L
  9. .I label
  10. .B ] [\-S
  11. .I sep
  12. .B ] [\-x]
  13. .I program
  14. .BR < '::' |\c
  15. .RI ' sep '\c
  16. .B >
  17. .I logger
  18. .SH DESCRIPTION
  19. .I program
  20. and
  21. .I logger
  22. may each be one or more arguments.
  23. They are separated by the verbatim string ``::'',
  24. or by the
  25. .I sep
  26. argument defined with the
  27. .B \-S
  28. option.
  29. .PP
  30. .B rundeux
  31. starts
  32. .I program
  33. and
  34. .I logger
  35. with the stdout of
  36. .I program
  37. connected to the stdin of
  38. .IR logger .
  39. Normally
  40. .I program
  41. is intended to be a long-running process,
  42. and
  43. .I logger
  44. is a program that logs the data it reads on its standard input.
  45. Both
  46. .I program
  47. and
  48. .I logger
  49. should be set up to run under supervision as foreground processes.
  50. .PP
  51. After starting,
  52. .B rundeux
  53. continues to monitor both
  54. .I program
  55. and
  56. .IR logger .
  57. If either process should terminate,
  58. .B rundeux
  59. restarts it.
  60. When
  61. .B rundeux
  62. itself receives any signal it can catch,
  63. it passes it on to
  64. .I program
  65. with the
  66. .BR kill (2)
  67. command.
  68. .PP
  69. If
  70. .B rundeux
  71. receives SIGTERM,
  72. it flags itself to terminate and initiates a shutdown sequence.
  73. It sends SIGTERM and SIGCONT to
  74. .I program
  75. and waits for it to terminate.
  76. It then closes the stdin of
  77. .I logger
  78. and waits for it to terminate.
  79. Then
  80. .B rundeux
  81. itself exits normally.
  82. .SH OPTIONS
  83. .TP
  84. .B \-d
  85. Detach.
  86. Normally
  87. .B rundeux
  88. itself runs as a foreground process.
  89. The
  90. .B \-d
  91. option may be used to run
  92. .B rundeux
  93. as a background process, in its own session and process group,
  94. detached from the controlling terminal.
  95. .TP
  96. .B \-h
  97. Help.
  98. Print a brief usage message to stderr and exit.
  99. .TP
  100. .B \-L label
  101. Label.
  102. May be used to provide
  103. .I label
  104. as a distinctive tag for an instance of
  105. .BR rundeux ,
  106. such as for reference in
  107. .BR ps (1)
  108. listings.
  109. Otherwise, this option has no effect.
  110. .TP
  111. .B \-S sep
  112. Separator.
  113. Normally the
  114. .I program
  115. and
  116. .I logger
  117. arguments are separated by the verbatim string ``::''.
  118. This option may be used to specify
  119. .I sep
  120. as an alternative separator string.
  121. .TP
  122. .B \-V
  123. Version.
  124. Print the version number to stderr and exit.
  125. .TP
  126. .B \-x
  127. Exit.
  128. Normally
  129. .B rundeux
  130. itself stays resident as a system process that monitors
  131. .I program
  132. and
  133. .IR logger .
  134. The
  135. .B \-x
  136. option causes
  137. .B rundeux
  138. to start
  139. .IR logger ,
  140. and then replace itself with the
  141. .I program
  142. process.
  143. In this case,
  144. .I program
  145. and
  146. .I logger
  147. will run as unsupervised processes.
  148. May be combined with the
  149. .B \-d
  150. option.
  151. .SH SIGNALS
  152. When
  153. .B rundeux
  154. receives any catchable signal,
  155. it passes that signal on to the
  156. .I program
  157. under its supervision.
  158. .PP
  159. If
  160. .B rundeux
  161. receives SIGTERM,
  162. it takes it as a shutdown command and performs the following sequence:
  163. .IP \(bu 4
  164. Send SIGTERM and SIGCONT signals to the
  165. .I program
  166. process and wait for it to terminate.
  167. .IP \(bu 4
  168. Close the stdin of the
  169. .I logger
  170. process and wait for it to terminate.
  171. .IP \(bu 4
  172. .B rundeux
  173. itself then exits normally.
  174. .SH AUTHOR
  175. Wayne Marshall, http://b0llix.net/perp/
  176. .SH SEE ALSO
  177. .nh
  178. .BR runtools_intro (8),
  179. .BR runargs (8),
  180. .BR runargv0 (8),
  181. .BR runchoom (8),
  182. .BR rundetach (8),
  183. .BR runenv (8),
  184. .BR runfile (8),
  185. .BR runlimit (8),
  186. .BR runlock (8),
  187. .BR runpause (8),
  188. .BR runsession (8),
  189. .BR runtool (8),
  190. .BR runtrap (8),
  191. .BR runuid (8)
  192. .\" EOF