Codebase list ps-watcher / 49403a9
Imported Upstream version 1.08 Jan Wagner 10 years ago
9 changed file(s) with 340 addition(s) and 186 deletion(s). Raw diff Collapse all Expand all
11 ## autogenerated ChangeLog -- don't edit
22 ##
33
4 2008-12-25 Thursday 17:01 Rocky Bernstein <rocky@cpan.org>
4 2009-02-19 Thursday 17:00 Rocky Bernstein <rocky@gnu.org>
5
6 * configure.ac: We're in 1.08 now
7
8 2009-02-19 Thursday 16:57 Rocky Bernstein <rocky@gnu.org>
9
10 * THANKS, ps-watcher.in.in: pidfile support from Jan Wagner and
11 friends
12
13 2008-12-31 Wednesday 11:25 Rocky Bernstein <rocky@gnu.org>
14
15 * home-page/: index.html: Presumably a little more compliant
16
17 2008-12-31 Wednesday 11:17 Rocky Bernstein <rocky@gnu.org>
18
19 * home-page/index.html: Convert to use css
20
21 2008-12-25 Thursday 17:34 Rocky Bernstein <rocky@gnu.org>
22
23 * .cvsignore: This time, for sure!
24
25 2008-12-25 Thursday 17:33 Rocky Bernstein <rocky@gnu.org>
26
27 * cvs2cl_usermap: More administrivia
28
29 2008-12-25 Thursday 17:31 Rocky Bernstein <rocky@gnu.org>
30
31 * .cvsignore: Administrivia
32
33 2008-12-25 Thursday 17:01 Rocky Bernstein <rocky@gnu.org>
534
635 * Makefile.am, samples/root-procs.ini: Add sample code using
736 perl-action.
837
9 2008-12-25 Thursday 16:42 Rocky Bernstein <rocky@cpan.org>
38 2008-12-25 Thursday 16:42 Rocky Bernstein <rocky@gnu.org>
1039
1140 * configure.ac, tests/paction.cnf: More Darwin9 fixes: tty can be
1241 many token so put at end of parsing.
1342
14 2008-12-25 Thursday 16:39 Rocky Bernstein <rocky@cpan.org>
43 2008-12-25 Thursday 16:39 Rocky Bernstein <rocky@gnu.org>
1544
1645 * Makefile.am, NEWS, configure.ac: Get ready for 1.07 release
1746
18 2008-12-23 Tuesday 11:09 Rocky Bernstein <rocky@cpan.org>
47 2008-12-23 Tuesday 11:09 Rocky Bernstein <rocky@gnu.org>
1948
2049 * ps-watcher.in.in: Typo: svz -> vsz. Thanks to Oliver Guerrier for
2150 pointing out.
2251
23 2008-12-18 Thursday 01:07 Rocky Bernstein <rocky@cpan.org>
52 2008-12-18 Thursday 01:07 Rocky Bernstein <rocky@gnu.org>
2453
2554 * ps-watcher.in.in: Bug in duplicating log
2655
27 2008-12-17 Wednesday 20:08 Rocky Bernstein <rocky@cpan.org>
56 2008-12-17 Wednesday 20:08 Rocky Bernstein <rocky@gnu.org>
2857
2958 * ANNOUNCE, AUTHORS, configure.ac: test cygwin and NetBSD and
3059 update contact info
3160
32 2008-12-17 Wednesday 19:28 Rocky Bernstein <rocky@cpan.org>
61 2008-12-17 Wednesday 19:28 Rocky Bernstein <rocky@gnu.org>
3362
3463 * post-configure.in: Tolerate older Perl's enough to warn that we
3564 can't use them.
3665
37 2008-12-17 Wednesday 18:31 Rocky Bernstein <rocky@cpan.org>
66 2008-12-17 Wednesday 18:31 Rocky Bernstein <rocky@gnu.org>
3867
3968 * configure.ac: Linux newline nuke fixes along the lines of the
4069 Darwin code
4170
42 2008-12-17 Wednesday 17:06 Rocky Bernstein <rocky@cpan.org>
71 2008-12-17 Wednesday 17:06 Rocky Bernstein <rocky@gnu.org>
4372
4473 * configure.ac, ps-watcher.in.in: Better about dealing with
4574 unwritable log file
4675
47 2008-12-17 Wednesday 16:31 Rocky Bernstein <rocky@cpan.org>
76 2008-12-17 Wednesday 16:31 Rocky Bernstein <rocky@gnu.org>
4877
4978 * configure.ac: In 1.07 now
5079
51 2008-12-17 Wednesday 16:27 Rocky Bernstein <rocky@cpan.org>
80 2008-12-17 Wednesday 16:27 Rocky Bernstein <rocky@gnu.org>
5281
5382 * configure.ac: Changes for Darwin9
5483
55 2006-11-17 Friday 14:02 Rocky Bernstein <rocky@cpan.org>
84 2006-11-17 Friday 14:02 Rocky Bernstein <rocky@gnu.org>
5685
5786 * ps-watcher.in.in, home-page/index.html: Small typos.
5887
59 2006-09-21 Thursday 23:07 Rocky Bernstein <rocky@cpan.org>
88 2006-09-21 Thursday 23:07 Rocky Bernstein <rocky@gnu.org>
6089
6190 * home-page/index.html: Correct for new sf link
6291
63 2006-03-11 Saturday 03:16 Rocky Bernstein <rocky@cpan.org>
92 2006-03-11 Saturday 03:16 Rocky Bernstein <rocky@gnu.org>
6493
6594 * ps-watcher.in.in: More doc changes
6695
67 2006-03-10 Friday 19:33 Rocky Bernstein <rocky@cpan.org>
96 2006-03-10 Friday 19:33 Rocky Bernstein <rocky@gnu.org>
6897
6998 * NEWS: Last change before release
7099
71 2006-03-10 Friday 19:07 Rocky Bernstein <rocky@cpan.org>
100 2006-03-10 Friday 19:07 Rocky Bernstein <rocky@gnu.org>
72101
73102 * configure.ac, post-configure.in, ps-watcher.in.in,
74103 tests/basic.t.in: Deal with time on netbsdelf and regression
75104 tests. basic.t.in: generalize time handling - not just cygwin.
76105 post-configure.in configure.ac: clean up a little.
77106
78 2006-03-10 Friday 13:12 Rocky Bernstein <rocky@cpan.org>
107 2006-03-10 Friday 13:12 Rocky Bernstein <rocky@gnu.org>
79108
80109 * tests/: args.t.in, basic.t.in, count.t.in, full.t.in: Run
81110 ps-watcher in tests with configured Perl location.
82111
83 2006-03-10 Friday 12:47 Rocky Bernstein <rocky@cpan.org>
112 2006-03-10 Friday 12:47 Rocky Bernstein <rocky@gnu.org>
84113
85114 * tests/: full.cnf, full.t.in: Add a test and adjust for cygwin.
86115
87 2006-03-10 Friday 12:26 Rocky Bernstein <rocky@cpan.org>
116 2006-03-10 Friday 12:26 Rocky Bernstein <rocky@gnu.org>
88117
89118 * configure.ac, post-configure.in, ps-watcher.in.in,
90119 tests/basic.t.in: Changes to make this work on more
92121 to get invocation work eveywhere basic.t.in: test for cputime;
93122 forgot !
94123
95 2006-03-10 Friday 04:51 Rocky Bernstein <rocky@cpan.org>
124 2006-03-10 Friday 04:51 Rocky Bernstein <rocky@gnu.org>
96125
97126 * configure.ac: Darwin 8 is okay
98127
99 2006-03-10 Friday 04:50 Rocky Bernstein <rocky@cpan.org>
128 2006-03-10 Friday 04:50 Rocky Bernstein <rocky@gnu.org>
100129
101130 * configure.ac: Bug in running right Perl in post-configure
102131
103 2006-03-10 Friday 03:49 Rocky Bernstein <rocky@cpan.org>
132 2006-03-10 Friday 03:49 Rocky Bernstein <rocky@gnu.org>
104133
105134 * configure.ac, post-configure.in: Use PERL value specified more.
106135
107 2006-03-10 Friday 03:39 Rocky Bernstein <rocky@cpan.org>
136 2006-03-10 Friday 03:39 Rocky Bernstein <rocky@gnu.org>
108137
109138 * NEWS, configure.ac: Add configure option to specify Perl location
110139
111 2006-03-10 Friday 03:24 Rocky Bernstein <rocky@cpan.org>
140 2006-03-10 Friday 03:24 Rocky Bernstein <rocky@gnu.org>
112141
113142 * tests/args.t.in: typo: it's ok not okay.
114143
115 2006-03-10 Friday 03:21 Rocky Bernstein <rocky@cpan.org>
144 2006-03-10 Friday 03:21 Rocky Bernstein <rocky@gnu.org>
116145
117146 * configure.ac, ps-watcher.in.in, tests/args.t.in,
118147 tests/basic.t.in, tests/full.t.in, tests/paction.t: Add minimal
119148 cygwin support
120149
121 2006-03-09 Thursday 17:37 Rocky Bernstein <rocky@cpan.org>
150 2006-03-09 Thursday 17:37 Rocky Bernstein <rocky@gnu.org>
122151
123152 * configure.ac, post-configure.in, tests/01.pod.t.in,
124153 tests/Makefile.am: 01.pod.t.in: add POD testing routine
125154 configure.ac: do chmod +x on perl-substituted files.
126155
127 2006-03-09 Thursday 16:46 Rocky Bernstein <rocky@cpan.org>
156 2006-03-09 Thursday 16:46 Rocky Bernstein <rocky@gnu.org>
128157
129158 * NEWS, ps-watcher.in.in: Document security better.
130159
131 2006-03-08 Wednesday 22:52 Rocky Bernstein <rocky@cpan.org>
160 2006-03-08 Wednesday 22:52 Rocky Bernstein <rocky@gnu.org>
132161
133162 * configure.ac, ps-watcher.in.in, home-page/index.html: Get ready
134163 for 1.06 release.
135164
136 2006-03-08 Wednesday 22:24 Rocky Bernstein <rocky@cpan.org>
165 2006-03-08 Wednesday 22:24 Rocky Bernstein <rocky@gnu.org>
137166
138167 * ps-watcher.in.in: Correction in getting signal name.
139168
140 2006-03-08 Wednesday 19:21 Rocky Bernstein <rocky@cpan.org>
169 2006-03-08 Wednesday 19:21 Rocky Bernstein <rocky@gnu.org>
141170
142171 * touch.pl: Reinstate since Makefile.am uses.
143172
144 2006-03-08 Wednesday 19:15 Rocky Bernstein <rocky@cpan.org>
173 2006-03-08 Wednesday 19:15 Rocky Bernstein <rocky@gnu.org>
145174
146175 * AUTHORS, Makefile.am, cvs2cl_usermap, post-configure.in,
147176 ps-watcher.in.in, touch.pl: ps-watcher.in.in: Wasn't terminating
151180 *: rocky@panix.com -> rocky@cpan.org touch.pl: now handled inside
152181 post-configure by Perl
153182
154 2006-02-03 Friday 02:23 Rocky Bernstein <rocky@cpan.org>
183 2006-02-03 Friday 02:23 Rocky Bernstein <rocky@gnu.org>
155184
156185 * ps-watcher.in.in: One more small typo.
157186
158 2006-02-03 Friday 02:15 Rocky Bernstein <rocky@cpan.org>
187 2006-02-03 Friday 02:15 Rocky Bernstein <rocky@gnu.org>
159188
160189 * post-configure.in, ps-watcher.in.in, home-page/index.html: Mostly
161190 small changes:
168197
169198 home-page/index.html: Probably remove a W3C error.
170199
171 2006-01-17 Tuesday 10:00 Rocky Bernstein <rocky@cpan.org>
200 2006-01-17 Tuesday 10:00 Rocky Bernstein <rocky@gnu.org>
172201
173202 * home-page/index.html: Make valid HTML as per W3C.
174203
175 2005-10-12 Wednesday 01:14 Rocky Bernstein <rocky@cpan.org>
204 2005-10-12 Wednesday 01:14 Rocky Bernstein <rocky@gnu.org>
176205
177206 * ps-watcher.in.in, NEWS: Add BUGS section to manual to describe
178207 common problems.
179208
180 2005-09-12 Monday 17:03 Rocky Bernstein <rocky@cpan.org>
209 2005-09-12 Monday 17:03 Rocky Bernstein <rocky@gnu.org>
181210
182211 * configure.ac: Now in 1.06cvs territory
183212
184 2005-09-12 Monday 17:03 Rocky Bernstein <rocky@cpan.org>
213 2005-09-12 Monday 17:03 Rocky Bernstein <rocky@gnu.org>
185214
186215 * ps-watcher.in.in: Guard against uninitialized variables
187216
188 2005-06-22 Wednesday 01:59 Rocky Bernstein <rocky@cpan.org>
217 2005-06-22 Wednesday 01:59 Rocky Bernstein <rocky@gnu.org>
189218
190219 * home-page/index.html: <Code> instead of <kbd>?
191220
192 2005-06-22 Wednesday 01:57 Rocky Bernstein <rocky@cpan.org>
221 2005-06-22 Wednesday 01:57 Rocky Bernstein <rocky@gnu.org>
193222
194223 * home-page/index.html: Correct grammar courtesy of Sir Monitor
195224 Lizard, Ph. Mad.
196225
197 2005-05-17 Tuesday 22:00 Rocky Bernstein <rocky@cpan.org>
226 2005-05-17 Tuesday 22:00 Rocky Bernstein <rocky@gnu.org>
198227
199228 * NEWS: What's new.
200229
201 2005-05-17 Tuesday 09:56 Rocky Bernstein <rocky@cpan.org>
230 2005-05-17 Tuesday 09:56 Rocky Bernstein <rocky@gnu.org>
202231
203232 * configure.ac: NetBSD works like FreeBSD
204233
205 2005-05-17 Tuesday 09:52 Rocky Bernstein <rocky@cpan.org>
234 2005-05-17 Tuesday 09:52 Rocky Bernstein <rocky@gnu.org>
206235
207236 * COPYING, Makefile.am, NEWS, config.guess, config.sub,
208237 configure.ac, missing, post-configure.in, docs/Makefile.am,
211240
212241 GPL address change.
213242
214 2005-04-09 Saturday 18:06 Rocky Bernstein <rocky@cpan.org>
243 2005-04-09 Saturday 18:06 Rocky Bernstein <rocky@gnu.org>
215244
216245 * ps-watcher.in.in: Like this a tad better.
217246
218 2005-04-04 Monday 23:58 Rocky Bernstein <rocky@cpan.org>
247 2005-04-04 Monday 23:58 Rocky Bernstein <rocky@gnu.org>
219248
220249 * NEWS, ps-watcher.in.in: Note recent change.
221250
222 2005-04-04 Monday 23:53 Rocky Bernstein <rocky@cpan.org>
251 2005-04-04 Monday 23:53 Rocky Bernstein <rocky@gnu.org>
223252
224253 * THANKS: Add thanks to Iñaki Sánchez.
225254
226 2005-04-04 Monday 23:50 Rocky Bernstein <rocky@cpan.org>
255 2005-04-04 Monday 23:50 Rocky Bernstein <rocky@gnu.org>
227256
228257 * ps-watcher.in.in, tests/basic.cnf.in: Allow $ps_pat to be used in
229258 action. Patch courtesy of Iñaki Sánchez. (i s a n c h e z at
230259 unav dot es)
231260
232 2004-09-11 Saturday 13:29 Rocky Bernstein <rocky@cpan.org>
261 2004-09-11 Saturday 13:29 Rocky Bernstein <rocky@gnu.org>
233262
234263 * docs/.cvsignore: More pod2htm stuff.
235264
236 2004-09-09 Thursday 10:58 Rocky Bernstein <rocky@cpan.org>
265 2004-09-09 Thursday 10:58 Rocky Bernstein <rocky@gnu.org>
237266
238267 * NEWS, cvs2cl_header, cvs2cl_usermap: ChangeLog-creation
239268 improvements.
240269
241 2004-09-07 Tuesday 13:51 Rocky Bernstein <rocky@cpan.org>
270 2004-09-07 Tuesday 13:51 Rocky Bernstein <rocky@gnu.org>
242271
243272 * Makefile.am, ps-watcher.in.in, docs/Makefile.am,
244273 samples/port-watch.ini: Make distcheck works. Show how to use
245274 $PROLOG to do a no-ps like thing such as watching a port (via
246275 lsof).
247276
248 2004-05-26 Wednesday 13:46 Rocky Bernstein <rocky@cpan.org>
277 2004-05-26 Wednesday 13:46 Rocky Bernstein <rocky@gnu.org>
249278
250279 * ps-watcher.in.in: Small change.
251280
252 2004-05-26 Wednesday 13:42 Rocky Bernstein <rocky@cpan.org>
281 2004-05-26 Wednesday 13:42 Rocky Bernstein <rocky@gnu.org>
253282
254283 * Makefile.am, configure.ac, ps-watcher.in.in, docs/Makefile.am:
255284 ps-watcher.in.in: smallish changes - call closelog on
263292 configure.ac: now in version 1.05 now. Allow maintainer mode (to
264293 create ChangeLog)
265294
266 2004-02-15 Sunday 12:03 Rocky Bernstein <rocky@cpan.org>
295 2004-02-15 Sunday 12:03 Rocky Bernstein <rocky@gnu.org>
267296
268297 * docs/Makefile.am: Set title to name without the .in.
269298
270 2004-01-18 Sunday 12:20 Rocky Bernstein <rocky@cpan.org>
299 2004-01-18 Sunday 12:20 Rocky Bernstein <rocky@gnu.org>
271300
272301 * ps-watcher.in.in: Update copyright.
273302
274 2004-01-18 Sunday 11:49 Rocky Bernstein <rocky@cpan.org>
303 2004-01-18 Sunday 11:49 Rocky Bernstein <rocky@gnu.org>
275304
276305 * ps-watcher.in.in: Improve documentation with respect to
277306 perl-action.
278307
279 2004-01-15 Thursday 03:23 Rocky Bernstein <rocky@cpan.org>
308 2004-01-15 Thursday 03:23 Rocky Bernstein <rocky@gnu.org>
280309
281310 * ps-watcher.in.in: perldoc fix.
282311
283 2004-01-15 Thursday 03:02 Rocky Bernstein <rocky@cpan.org>
312 2004-01-15 Thursday 03:02 Rocky Bernstein <rocky@gnu.org>
284313
285314 * tests/paction.t: Regression test for $PROLOG, $EPILOG and
286315 perl-action.
287316
288 2004-01-15 Thursday 03:00 Rocky Bernstein <rocky@cpan.org>
317 2004-01-15 Thursday 03:00 Rocky Bernstein <rocky@gnu.org>
289318
290319 * configure.ac, ps-watcher.in.in, tests/Makefile.am,
291320 tests/paction.cnf: Add $PROLOG, $EPILOG and perl-action sections.
292321 Allows one to accumulate information over all processes and take
293322 action on that.
294323
295 2004-01-10 Saturday 04:39 Rocky Bernstein <rocky@cpan.org>
324 2004-01-10 Saturday 04:39 Rocky Bernstein <rocky@gnu.org>
296325
297326 * ps-watcher.in.in: Documentation enhancement, I think.
298327
299 2003-11-22 Saturday 12:31 Rocky Bernstein <rocky@cpan.org>
328 2003-11-22 Saturday 12:31 Rocky Bernstein <rocky@gnu.org>
300329
301330 * ps-watcher.in.in: And another formatting change...
302331
303 2003-11-22 Saturday 12:27 Rocky Bernstein <rocky@cpan.org>
332 2003-11-22 Saturday 12:27 Rocky Bernstein <rocky@gnu.org>
304333
305334 * ps-watcher.in.in: One more trivial typo....
306335
307 2003-11-22 Saturday 12:26 Rocky Bernstein <rocky@cpan.org>
336 2003-11-22 Saturday 12:26 Rocky Bernstein <rocky@gnu.org>
308337
309338 * ps-watcher.in.in: Documentation typo.
310339
311 2003-11-22 Saturday 12:01 Rocky Bernstein <rocky@cpan.org>
340 2003-11-22 Saturday 12:01 Rocky Bernstein <rocky@gnu.org>
312341
313342 * NEWS, configure.ac: Get ready for new (minor) release.
314343
315 2003-11-21 Friday 02:36 Rocky Bernstein <rocky@cpan.org>
344 2003-11-21 Friday 02:36 Rocky Bernstein <rocky@gnu.org>
316345
317346 * ps-watcher.in.in, tests/basic.cnf.in, tests/basic.t.in: Add
318347 first-trigger feature.
319348
320 2003-09-11 Thursday 03:17 Rocky Bernstein <rocky@cpan.org>
349 2003-09-11 Thursday 03:17 Rocky Bernstein <rocky@gnu.org>
321350
322351 * NEWS: Get ready for a release.
323352
324 2003-09-10 Wednesday 07:30 Rocky Bernstein <rocky@cpan.org>
353 2003-09-10 Wednesday 07:30 Rocky Bernstein <rocky@gnu.org>
325354
326355 * ps-watcher.in.in: Fix example configuration as suggested in bug
327356 #776229.
328357
329 2003-09-05 Friday 00:23 Rocky Bernstein <rocky@cpan.org>
358 2003-09-05 Friday 00:23 Rocky Bernstein <rocky@gnu.org>
330359
331360 * ps-watcher.in.in: More complicated trigger example suggested by
332361 jason
333362
334 2003-09-03 Wednesday 02:04 Rocky Bernstein <rocky@cpan.org>
363 2003-09-03 Wednesday 02:04 Rocky Bernstein <rocky@gnu.org>
335364
336365 * ps-watcher.in.in: Add troubleshooting section
337366
338 2003-09-03 Wednesday 01:42 Rocky Bernstein <rocky@cpan.org>
367 2003-09-03 Wednesday 01:42 Rocky Bernstein <rocky@gnu.org>
339368
340369 * configure.ac, ps-watcher.in.in: Fixes for FreeBSD
341370
342 2003-08-31 Sunday 21:22 Rocky Bernstein <rocky@cpan.org>
371 2003-08-31 Sunday 21:22 Rocky Bernstein <rocky@gnu.org>
343372
344373 * tests/basic.cnf.in: perhaps some processes use so little CPU that
345374 the elapsed time will round to zero. Deal with it.
346375
347 2003-08-30 Saturday 20:49 Rocky Bernstein <rocky@cpan.org>
376 2003-08-30 Saturday 20:49 Rocky Bernstein <rocky@gnu.org>
348377
349378 * ps-watcher.in.in: Update date.
350379
351 2003-08-29 Friday 10:49 Rocky Bernstein <rocky@cpan.org>
380 2003-08-29 Friday 10:49 Rocky Bernstein <rocky@gnu.org>
352381
353382 * configure.ac: Get ready for another release.
354383
355 2003-08-29 Friday 10:48 Rocky Bernstein <rocky@cpan.org>
384 2003-08-29 Friday 10:48 Rocky Bernstein <rocky@gnu.org>
356385
357386 * tests/: args.t.in, basic.t.in, count.t.in, full.t.in: Regression
358387 tests need to deal with timestamped output.
359388
360 2003-08-29 Friday 10:47 Rocky Bernstein <rocky@cpan.org>
389 2003-08-29 Friday 10:47 Rocky Bernstein <rocky@gnu.org>
361390
362391 * ps-watcher.in.in: Add syslog-like timestamp to logfile output.
363392 Problems with getting ps-output now appears only on debug output.
364393
365 2003-08-29 Friday 10:45 Rocky Bernstein <rocky@cpan.org>
394 2003-08-29 Friday 10:45 Rocky Bernstein <rocky@gnu.org>
366395
367396 * post-configure.in: Use -w (warning) on perl invocation
368397
369 2003-08-13 Wednesday 02:33 Rocky Bernstein <rocky@cpan.org>
398 2003-08-13 Wednesday 02:33 Rocky Bernstein <rocky@gnu.org>
370399
371400 * configure.ac: PS_CAN_RETURN_MULTIPLE_LINES not set on AIX which
372401 broke it.
373402
374 2003-07-11 Friday 05:56 Rocky Bernstein <rocky@cpan.org>
403 2003-07-11 Friday 05:56 Rocky Bernstein <rocky@gnu.org>
375404
376405 * Makefile.am: Add sample files
377406
378 2003-07-11 Friday 05:47 Rocky Bernstein <rocky@cpan.org>
407 2003-07-11 Friday 05:47 Rocky Bernstein <rocky@gnu.org>
379408
380409 * configure.ac: typo
381410
382 2003-07-11 Friday 05:46 Rocky Bernstein <rocky@cpan.org>
411 2003-07-11 Friday 05:46 Rocky Bernstein <rocky@gnu.org>
383412
384413 * configure.ac: Get ready for 1.0 release.
385414
386 2003-07-11 Friday 05:43 Rocky Bernstein <rocky@cpan.org>
415 2003-07-11 Friday 05:43 Rocky Bernstein <rocky@gnu.org>
387416
388417 * Makefile.am, tests/Makefile.am, tests/args.t.in,
389418 tests/count.t.in, tests/full.t.in: Make "make distcheck" work.
390419
391 2003-07-11 Friday 05:42 Rocky Bernstein <rocky@cpan.org>
420 2003-07-11 Friday 05:42 Rocky Bernstein <rocky@gnu.org>
392421
393422 * THANKS: Update as appropriate.
394423
395 2003-07-10 Thursday 12:20 Rocky Bernstein <rocky@cpan.org>
424 2003-07-10 Thursday 12:20 Rocky Bernstein <rocky@gnu.org>
396425
397426 * configure.ac, post-configure.in: A tad better for making "make
398427 distcheck" work: Use $srcdir in post-configure and arrange for
399428 srcdir to be passed in.
400429
401 2003-07-10 Thursday 11:50 Rocky Bernstein <rocky@cpan.org>
430 2003-07-10 Thursday 11:50 Rocky Bernstein <rocky@gnu.org>
402431
403432 * THANKS, TODO, config.cache, configure.ac, ps-watcher.in.in: Deal
404433 with ps (e.g. Solaris's) which return more than one line for a
405434 single pid.
406435
407 2003-07-10 Thursday 11:42 Rocky Bernstein <rocky@cpan.org>
436 2003-07-10 Thursday 11:42 Rocky Bernstein <rocky@gnu.org>
408437
409438 * ps-watcher.in.in: Stupid mistake - comments are # not /* */.
410439
411 2003-05-19 Monday 16:33 Rocky Bernstein <rocky@cpan.org>
440 2003-05-19 Monday 16:33 Rocky Bernstein <rocky@gnu.org>
412441
413442 * configure.ac: Accomodate darwin6
414443
415 2003-05-19 Monday 16:33 Rocky Bernstein <rocky@cpan.org>
444 2003-05-19 Monday 16:33 Rocky Bernstein <rocky@gnu.org>
416445
417446 * tests/args.t.in: Add one test of --nosyslog
418447
419 2003-05-19 Monday 15:58 Rocky Bernstein <rocky@cpan.org>
448 2003-05-19 Monday 15:58 Rocky Bernstein <rocky@gnu.org>
420449
421450 * configure.ac: Add AIX support.
422451
423 2003-05-16 Friday 00:12 Rocky Bernstein <rocky@cpan.org>
452 2003-05-16 Friday 00:12 Rocky Bernstein <rocky@gnu.org>
424453
425454 * README: IniConf is now called Config::IniFiles
426455
427 2003-03-06 Thursday 05:57 Rocky Bernstein <rocky@cpan.org>
456 2003-03-06 Thursday 05:57 Rocky Bernstein <rocky@gnu.org>
428457
429458 * configure.ac: Failed full test. Need to add -x.
430459
431 2003-03-06 Thursday 05:48 Rocky Bernstein <rocky@cpan.org>
460 2003-03-06 Thursday 05:48 Rocky Bernstein <rocky@gnu.org>
432461
433462 * tests/full.cnf: Don't assume first is pid 1!
434463
435 2003-03-06 Thursday 05:37 Rocky Bernstein <rocky@cpan.org>
464 2003-03-06 Thursday 05:37 Rocky Bernstein <rocky@gnu.org>
436465
437466 * configure.ac, tests/Makefile.am, tests/.cvsignore,
438467 tests/full.cnf, tests/full.t.in: Add test that we can trigger on
439468 watching processes other than the ones under our account.
440469
441 2003-03-06 Thursday 03:54 Rocky Bernstein <rocky@cpan.org>
470 2003-03-06 Thursday 03:54 Rocky Bernstein <rocky@gnu.org>
442471
443472 * Makefile.am, NEWS, config.guess, configure.ac, docs/Makefile.am,
444473 tests/Makefile.am: Changes for Mac OS/X
445474
446 2003-03-04 Tuesday 18:01 Rocky Bernstein <rocky@cpan.org>
475 2003-03-04 Tuesday 18:01 Rocky Bernstein <rocky@gnu.org>
447476
448477 * aclocal.m4, docs/Makefile.am, tests/Makefile.in: Add more
449478 automake conversion idioms
450479
451 2003-03-04 Tuesday 14:14 Rocky Bernstein <rocky@cpan.org>
480 2003-03-04 Tuesday 14:14 Rocky Bernstein <rocky@gnu.org>
452481
453482 * autogen.sh: Omitted running aclocal, autoconf, automake...
454483
455 2003-03-04 Tuesday 14:08 Rocky Bernstein <rocky@cpan.org>
484 2003-03-04 Tuesday 14:08 Rocky Bernstein <rocky@gnu.org>
456485
457486 * docs/: Makefile.am, Makefile.in: More automake conversion pains.
458487
459 2003-03-04 Tuesday 14:05 Rocky Bernstein <rocky@cpan.org>
488 2003-03-04 Tuesday 14:05 Rocky Bernstein <rocky@gnu.org>
460489
461490 * .cvsignore, MANIFEST: MANIFEST: not used in automake
462491
463 2003-03-04 Tuesday 14:03 Rocky Bernstein <rocky@cpan.org>
492 2003-03-04 Tuesday 14:03 Rocky Bernstein <rocky@gnu.org>
464493
465494 * NEWS, autogen.sh: autogen.sh: useful for CVS NEWS: what's been
466495 happening?
467496
468 2003-03-04 Tuesday 13:59 Rocky Bernstein <rocky@cpan.org>
497 2003-03-04 Tuesday 13:59 Rocky Bernstein <rocky@gnu.org>
469498
470499 * Makefile.am, Makefile.in: More automake conversion work.
471500 Makefile.am: forgot to add Makefile.PL. Makefile.in: superceded
472501 by Makfile.am
473502
474 2003-03-04 Tuesday 13:55 Rocky Bernstein <rocky@cpan.org>
503 2003-03-04 Tuesday 13:55 Rocky Bernstein <rocky@gnu.org>
475504
476505 * AUTHORS, Makefile.am, Makefile.in, NEWS, aclocal.m4, version,
477506 docs/Makefile.am, docs/Makefile.in, tests/Makefile.am,
478507 tests/Makefile.in: Convert to use Makefile.am
479508
480 2003-03-04 Tuesday 02:53 Rocky Bernstein <rocky@cpan.org>
509 2003-03-04 Tuesday 02:53 Rocky Bernstein <rocky@gnu.org>
481510
482511 * configure.ac, ps-watcher.in.in, version, samples/sample.ini,
483512 tests/args.cnf: Changes for BSD/OS. Also potentially a bug in
484513 FreeBSD.
485514
486 2003-03-02 Sunday 16:35 Rocky Bernstein <rocky@cpan.org>
515 2003-03-02 Sunday 16:35 Rocky Bernstein <rocky@gnu.org>
487516
488517 * ps-watcher.in.in: More small document changes. Make HTML come out
489518 a tad better.
490519
491 2003-03-02 Sunday 15:28 Rocky Bernstein <rocky@cpan.org>
520 2003-03-02 Sunday 15:28 Rocky Bernstein <rocky@gnu.org>
492521
493522 * ps-watcher.in.in: Update link for netwinder location!
494523
495 2003-03-01 Saturday 21:38 Rocky Bernstein <rocky@cpan.org>
524 2003-03-01 Saturday 21:38 Rocky Bernstein <rocky@gnu.org>
496525
497526 * MANIFEST: Typo.
498527
499 2003-03-01 Saturday 21:37 Rocky Bernstein <rocky@cpan.org>
528 2003-03-01 Saturday 21:37 Rocky Bernstein <rocky@gnu.org>
500529
501530 * NEWS: What's up.
502531
503 2003-03-01 Saturday 21:35 Rocky Bernstein <rocky@cpan.org>
532 2003-03-01 Saturday 21:35 Rocky Bernstein <rocky@gnu.org>
504533
505534 * MANIFEST: Add Changelog
506535
507 2003-03-01 Saturday 21:23 Rocky Bernstein <rocky@cpan.org>
536 2003-03-01 Saturday 21:23 Rocky Bernstein <rocky@gnu.org>
508537
509538 * samples/sample.ini: Add $args example.
510539
511 2003-03-01 Saturday 21:12 Rocky Bernstein <rocky@cpan.org>
540 2003-03-01 Saturday 21:12 Rocky Bernstein <rocky@gnu.org>
512541
513542 * MANIFEST, configure.ac, ps-watcher.in.in: Add variables to
514543 control what ps can do, e.g. can nuke header line, has custom
515544 title (for nuking header line), what time variable we can test
516545 on.
517546
518 2003-03-01 Saturday 21:09 Rocky Bernstein <rocky@cpan.org>
547 2003-03-01 Saturday 21:09 Rocky Bernstein <rocky@gnu.org>
519548
520549 * tests/: .cvsignore, args.t.in, basic.cnf, basic.cnf.in: Don't
521550 assume etime is a ps-variable. Thanks, FreeBSD.
522551
523 2003-03-01 Saturday 21:08 Rocky Bernstein <rocky@cpan.org>
552 2003-03-01 Saturday 21:08 Rocky Bernstein <rocky@gnu.org>
524553
525554 * docs/Makefile.in: Cater to brain-dead make on FreeBSD.
526555
527 2003-02-28 Friday 16:45 Rocky Bernstein <rocky@cpan.org>
556 2003-02-28 Friday 16:45 Rocky Bernstein <rocky@gnu.org>
528557
529558 * MANIFEST, configure.ac: configure.ac: add freebsd4 check
530559 MANIFEST: add args test files
531560
532 2003-02-28 Friday 13:37 Rocky Bernstein <rocky@cpan.org>
561 2003-02-28 Friday 13:37 Rocky Bernstein <rocky@gnu.org>
533562
534563 * config.sub: Update with more recent version of this.
535564
536 2003-02-28 Friday 12:34 Rocky Bernstein <rocky@cpan.org>
565 2003-02-28 Friday 12:34 Rocky Bernstein <rocky@gnu.org>
537566
538567 * tests/: .cvsignore, args.cnf, args.t.in: Add args regression
539568 test.
540569
541 2003-02-28 Friday 12:33 Rocky Bernstein <rocky@cpan.org>
570 2003-02-28 Friday 12:33 Rocky Bernstein <rocky@gnu.org>
542571
543572 * configure.ac, ps-watcher.in.in, tests/Makefile.in,
544573 tests/basic.cnf, tests/basic.t.in, tests/count.t.in: Add args
545574 documentation and regression tests. count.t.in, basic.t.in: set
546575 perl mode for emacs
547576
548 2003-02-27 Thursday 23:46 Rocky Bernstein <rocky@cpan.org>
577 2003-02-27 Thursday 23:46 Rocky Bernstein <rocky@gnu.org>
549578
550579 * configure.ac, ps-watcher.in.in, version: Add $args variable to
551580 test on entire command. Perpare to make into another version.
552581
553 2003-02-27 Thursday 21:21 Rocky Bernstein <rocky@cpan.org>
582 2003-02-27 Thursday 21:21 Rocky Bernstein <rocky@gnu.org>
554583
555584 * configure.ac: Add args to the list of variables that are
556585 accepted.
557586
558 2003-01-27 Monday 22:41 Rocky Bernstein <rocky@cpan.org>
587 2003-01-27 Monday 22:41 Rocky Bernstein <rocky@gnu.org>
559588
560589 * MANIFEST, configure.stamp, version: MANIFEST: configre.in ->
561590 configure.ac Other files not sure about, but we'll try
562591 initially...
563592
564 2003-01-27 Monday 22:37 Rocky Bernstein <rocky@cpan.org>
593 2003-01-27 Monday 22:37 Rocky Bernstein <rocky@gnu.org>
565594
566595 * configure.ac: Remove touch of stamp file. Dunno...
567596
568 2003-01-27 Monday 22:35 Rocky Bernstein <rocky@cpan.org>
597 2003-01-27 Monday 22:35 Rocky Bernstein <rocky@gnu.org>
569598
570599 * configure.ac: Bump version number.
571600
572 2003-01-27 Monday 22:34 Rocky Bernstein <rocky@cpan.org>
601 2003-01-27 Monday 22:34 Rocky Bernstein <rocky@gnu.org>
573602
574603 * Makefile.in, NEWS, configure.ac, configure.in, ps-watcher.in.in,
575604 samples/sample.ini: Bug in running make dist.
0 Changes from 1.07 to 1.08 (March 15, 2009)
1
2 - pidfile support via Jan Wagner.
3 - Darwin9 support
4
05 Changes from 1.06 to 1.07 (December 25, 2008)
16 - Changed to include and tested on Darwin9
27
9297
9398 ps-watcher 0.93 -- first general release.
9499
95 $Id: NEWS,v 1.28 2008/12/25 16:39:17 rockyb Exp $
100 $Id: NEWS,v 1.29 2009/03/15 06:59:23 rockyb Exp $
1212 program to fire when no matching processes (e.g. when a process that
1313 should be running has died).
1414
15 Jan Wagner - Debian packaging and support; pidfile support addition.
16
1517 Thanks to Jason Welsh <jason at monsterjam dot org> for helping to track down
1618 a Solaris problem where ps returned multiple lines of output.
1719
2123 Musicological supervision by Stuart Frankel <gecko@dustyfeet.com>,
2224 cutrate Ph.D.
2325
24 $Id: THANKS,v 1.8 2006/03/08 19:17:33 rockyb Exp $
26 $Id: THANKS,v 1.9 2009/02/19 16:57:31 rockyb Exp $
2527
2628
2729
20062006
20072007 # Define the identity of the package.
20082008 PACKAGE=ps-watcher
2009 VERSION=1.07
2009 VERSION=1.08
20102010
20112011
20122012 cat >>confdefs.h <<_ACEOF
1717 dnl Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
1818 dnl 02110-1301 USA.
1919
20 dnl $Id: configure.ac,v 1.43 2008/12/25 16:42:49 rockyb Exp $
20 dnl $Id: configure.ac,v 1.45 2009/03/15 06:59:23 rockyb Exp $
2121 dnl Process this file with autoconf to produce a configure script.
2222
2323 AC_INIT(ps-watcher.in.in)
24 AM_INIT_AUTOMAKE(ps-watcher,1.07)
24 AM_INIT_AUTOMAKE(ps-watcher,1.08)
2525
2626 AM_MISSING_PROG(CVS2CL, cvs2cl, $missing_dir)
2727 AM_MAINTAINER_MODE
0 .\" Automatically generated by Pod::Man 2.17 (Pod::Simple 3.07)
0 .\" Automatically generated by Pod::Man 2.16 (Pod::Simple 3.05)
11 .\"
22 .\" Standard preamble:
33 .\" ========================================================================
66 .if t .Sp
77 .ne 5
88 .PP
9 \fB\&\\$1\fR
9 \fB\\$1\fR
1010 .PP
1111 ..
1212 .de Sp \" Vertical space (when we can't use .PP)
131131 .\" ========================================================================
132132 .\"
133133 .IX Title "ps-watcher 8"
134 .TH ps-watcher 8 "2008-12-25" "perl v5.8.8" "User Contributed Perl Documentation"
134 .TH ps-watcher 8 "2009-03-15" "perl v5.10.0" "User Contributed Perl Documentation"
135135 .\" For nroff, turn off justification. Always turn off hyphenation; it makes
136136 .\" way too many mistakes in technical documents.
137137 .if n .ad l
88
99 <body style="background-color: white">
1010
11
12 <!-- INDEX BEGIN -->
13 <div name="index">
1114 <p><a name="__index__"></a></p>
12 <!-- INDEX BEGIN -->
1315
1416 <ul>
1517
3032 </ul>
3133
3234 <li><a href="#example_configuration">EXAMPLE CONFIGURATION</a></li>
33 <li><a href="#using__prolog_for_getting_nonps_information">Using $PROLOG for getting non-ps information</a></li>
35 <li><a href="#using__prolog_for_getting_non_ps_information">Using $PROLOG for getting non-ps information</a></li>
3436 <li><a href="#security_considerations">SECURITY CONSIDERATIONS</a></li>
3537 <li><a href="#troubleshooting">TROUBLESHOOTING</a></li>
3638 <li><a href="#bugs">BUGS</a></li>
3840 <li><a href="#author">AUTHOR</a></li>
3941 <li><a href="#copyright">COPYRIGHT</a></li>
4042 </ul>
43
44 <hr name="index" />
45 </div>
4146 <!-- INDEX END -->
4247
43 <hr />
4448 <p>
4549 </p>
4650 <h1><a name="name">NAME</a></h1>
5761 <h1><a name="description">DESCRIPTION</a></h1>
5862 <p>Periodically a list of processes obtained via <code>ps</code>. More precisely
5963 each item in the list contains the process name (just what's listed in
60 the ``cmd'' field, not the full command and arguments) and its process
64 the &quot;cmd&quot; field, not the full command and arguments) and its process
6165 id (pid). A configuration file specifies a list of Perl
6266 regular-expression patterns to match the processes against. For each
6367 match, a Perl expression specified for that pattern is evaluated. The
101105 </p>
102106 <h2><a name="options">OPTIONS</a></h2>
103107 <dl>
104 <dt><strong><a name="item__2d_2dhelp">--help</a></strong></dt>
108 <dt><strong><a name="help" class="item">--help</a></strong></dt>
105109
106110 <dd>
107111 <p>Print a usage message on standard error and exit with a return code
108112 of 100.</p>
109113 <p></p>
110114 </dd>
111 <dt><strong><a name="item__2d_2ddoc">--doc</a></strong></dt>
115 <dt><strong><a name="doc" class="item">--doc</a></strong></dt>
112116
113117 <dd>
114118 <p>Extact the full documentation that you are reading now, print it and
115119 exit with a return code of 101.</p>
116120 <p></p>
117121 </dd>
118 <dt><strong><a name="item__2d_2dversion">--version</a></strong></dt>
122 <dt><strong><a name="version" class="item">--version</a></strong></dt>
119123
120124 <dd>
121125 <p>Print the version release on standard output and exit with a return
122126 code of 10.</p>
123127 <p></p>
124128 </dd>
125 <dt><strong><a name="item__2d_2ddebug_number">--debug <em>number</em></a></strong></dt>
129 <dt><strong><a name="debug_number" class="item">--debug <em>number</em></a></strong></dt>
126130
127131 <dd>
128132 <p>Give debugging output. The higher the number, the more the output. The
129133 default is 0 = none. 2 is the most debugging output.</p>
130134 </dd>
131 <dt><strong><a name="item__5b_2d_2dconfig_5d_configuration_file">[--config] <em>configuration file</em></a></strong></dt>
135 <dt><strong><a name="config_configuration_file" class="item">[--config] <em>configuration file</em></a></strong></dt>
132136
133137 <dd>
134138 <p>Specify configuration file. .</p>
137141 example of a configuration file.</p>
138142 <p></p>
139143 </dd>
140 <dt><strong><a name="item__2d_2dlog__5blog_file_5d">--log [<em>log file</em>]</a></strong></dt>
144 <dt><strong><a name="log_log_file" class="item">--log [<em>log file</em>]</a></strong></dt>
141145
142146 <dd>
143147 <p>Send or don't send error and debugging output to a log file. If option
145149 no error log file. See also --syslog below.</p>
146150 <p></p>
147151 </dd>
148 <dt><strong><a name="item__2d_2dsyslog__7c__2d_2dnosyslog">--syslog | --nosyslog</a></strong></dt>
152 <dt><strong><a name="syslog_nosyslog" class="item">--syslog | --nosyslog</a></strong></dt>
149153
150154 <dd>
151155 <p>Send or don't send error and debugging output to syslog. The default
152156 is to syslog error and debug output.</p>
153157 <p></p>
154158 </dd>
155 <dt><strong><a name="item__2d_2ddaemon__7c__2d_2dnodaemon">--daemon | --nodaemon</a></strong></dt>
159 <dt><strong><a name="daemon_nodaemon" class="item">--daemon | --nodaemon</a></strong></dt>
156160
157161 <dd>
158162 <p>Run or don't as a daemon.</p>
159163 <p></p>
160164 </dd>
161 <dt><strong><a name="item__2d_2dpath_search_2dpath">--path <em>search-path</em></a></strong></dt>
165 <dt><strong><a name="path_search_path" class="item">--path <em>search-path</em></a></strong></dt>
162166
163167 <dd>
164168 <p>Specify the executable search path used in running commands.</p>
165169 </dd>
166 <dt><strong><a name="item__2d_2dps_2dprog_program">--ps-prog <em>program</em></a></strong></dt>
170 <dt><strong><a name="ps_prog_program" class="item">--ps-prog <em>program</em></a></strong></dt>
167171
168172 <dd>
169173 <p>One can specify the command that gives ps information. By default, the
170 command is <em>/bin/ps</em>.</p>
171 <p></p>
172 </dd>
173 <dt><strong><a name="item__2d_2drun__7c__2d_2dnorun">--run | --norun</a></strong></dt>
174 command is <em class="file">/bin/ps</em>.</p>
175 <p></p>
176 </dd>
177 <dt><strong><a name="run_norun" class="item">--run | --norun</a></strong></dt>
174178
175179 <dd>
176180 <p>do/don't run actions go through the motions as though we were going
177181 to. This may be useful in debugging.</p>
178182 <p></p>
179183 </dd>
180 <dt><strong><a name="item__2d_2dsleep_interval_in_seconds">--sleep <em>interval in seconds</em></a></strong></dt>
184 <dt><strong><a name="sleep_interval_in_seconds" class="item">--sleep <em>interval in seconds</em></a></strong></dt>
181185
182186 <dd>
183187 <p>It is expected that one might want to run ps-watcher over and over
208212 <p>The format of a configuration file is a series of fully qualified
209213 filenames enclosed in square brackets followed by a number of
210214 parameter lines. Each parameter line has a parameter name followed by
211 an ``equal'' sign and finally value. That is:</p>
215 an &quot;equal&quot; sign and finally value. That is:</p>
212216 <pre>
213217 # This is a comment line
214218 ; So is this.
222226 <p>Comments start with # or ; and take effect to the end of the line.</p>
223227 <p>This should be familiar to those who have worked with text-readible
224228 Microsoft <code>.INI</code> files.</p>
225 <p>Note process patterns, (<em>process-pattern1</em> and <em>process-pattern2</em>
229 <p>Note process patterns, (<em class="file">process-pattern1</em> and <em class="file">process-pattern2</em>
226230 above) must be unique. If there are times when you may want to
227231 refer to the same process, one can be creative to make these unique.
228 e.g. <em>cron</em> and <em>[c]ron</em> which refer to the same process even
232 e.g. <em class="file">cron</em> and <em class="file">[c]ron</em> which refer to the same process even
229233 though they <em>appear</em> to be different.</p>
230234 <p>As quoted directly from the Config::IniFiles documentation:</p>
231235 <p>Multiline or multivalued fields may also be defined ala UNIX
232 ``here document'' syntax:</p>
236 &quot;here document&quot; syntax:</p>
233237 <pre>
234238 Parameter=&lt;&lt;EOT
235239 value/line 1
236240 value/line 2
237241 EOT</pre>
238 <p>You may use any string you want in place of ``EOT''. Note
239 that what follows the ``&lt;&lt;'' and what appears at the end of
242 <p>You may use any string you want in place of &quot;EOT&quot;. Note
243 that what follows the &quot;&lt;&lt;&quot; and what appears at the end of
240244 the text <em>must</em> match exactly, including any trailing
241245 whitespace.</p>
242 <p>There are two special ``process patterns'': $PROLOG and $EPILOG, the
246 <p>There are two special &quot;process patterns&quot;: $PROLOG and $EPILOG, the
243247 former should appear first and the latter last.</p>
244248 <p>You can put perl code to initialize variables here and do cleanup
245 actions in these sections using ``perl-action.''</p>
249 actions in these sections using &quot;perl-action.&quot;</p>
246250 <p>A description of parameters names, their meanings and potential values
247251 follows.</p>
248252 <dl>
249 <dt><strong><a name="item_trigger">trigger</a></strong></dt>
253 <dt><strong><a name="trigger" class="item">trigger</a></strong></dt>
250254
251255 <dd>
252256 <p>This parameter specifies the condition on which a process action is
253257 fired. The condition is evaluated with Perl <code>eval()</code> and should
254 therefore return something which is equivalent to ``true'' in a Perl
258 therefore return something which is equivalent to &quot;true&quot; in a Perl
255259 expression.</p>
256260 <p>If no trigger is given in a section, true or 1 is assumed and
257261 the action is unconditionally triggered.</p>
266270 [httpd$]
267271 trigger = $count &lt;= 4</pre>
268272 </dd>
269 <dt><strong><a name="item_occurs">occurs</a></strong></dt>
273 <dt><strong><a name="occurs" class="item">occurs</a></strong></dt>
270274
271275 <dd>
272276 <p>This parameter specifies how many times an action should be performed
273277 on processes matching the section trigger. Acceptable values are
274 ``every'', ``first'', ``first-trigger'', and ``none''.</p>
275 <p>Setting the occurs value to ``none'' causes the the trigger to be
278 &quot;every&quot;, &quot;first&quot;, &quot;first-trigger&quot;, and &quot;none&quot;.</p>
279 <p>Setting the occurs value to &quot;none&quot; causes the the trigger to be
276280 evaluated when there are no matching processes. Although one might
277 think ``$count == 0'' in the action expression would do the same thing,
281 think &quot;$count == 0&quot; in the action expression would do the same thing,
278282 currently as coded this does not work.</p>
279 <p>Setting the occurs value to ``first'' causes the process-pattern rule to
283 <p>Setting the occurs value to &quot;first&quot; causes the process-pattern rule to
280284 be finished after handling the first rule that matches, whether or not the
281285 trigger evaluated to true.</p>
282 <p>Setting the occurs value to ``first-trigger'' causes the process-pattern
286 <p>Setting the occurs value to &quot;first-trigger&quot; causes the process-pattern
283287 rule to be finished after handling the first rule that matches <em>and</em>
284288 the trigger evaluates to true.</p>
285 <p>If the item parameter is not specified, ``first'' is assumed.</p>
289 <p>If the item parameter is not specified, &quot;first&quot; is assumed.</p>
286290 <p>Examples:</p>
287291 <pre>
288292 [.]
308312 occurs = none
309313 action = /etc/init.d/syslogd start</pre>
310314 </dd>
311 <dt><strong><a name="item_action">action</a></strong></dt>
315 <dt><strong><a name="action" class="item">action</a></strong></dt>
312316
313317 <dd>
314318 <p>This specifies the action, a command that gets run by the system
317321 <pre>
318322 action = /etc/init.d/market_loader.init restart</pre>
319323 </dd>
320 <dt><strong><a name="item_perl_2daction">perl-action</a></strong></dt>
324 <dt><strong><a name="perl_action" class="item">perl-action</a></strong></dt>
321325
322326 <dd>
323327 <p>This specifies Perl statements to be eval'd. This can be especially
351355 <p>The following variables can be used in either the pattern or action
352356 fields.</p>
353357 <dl>
354 <dt><strong><a name="item__action">$action</a></strong></dt>
358 <dt><strong><a name="_action" class="item">$action</a></strong></dt>
355359
356360 <dd>
357361 <p>A string containing the text of the action to run.</p>
358362 <p></p>
359363 </dd>
360 <dt><strong><a name="item__perl_action">$perl_action</a></strong></dt>
364 <dt><strong><a name="_perl_action" class="item">$perl_action</a></strong></dt>
361365
362366 <dd>
363367 <p>A string containing the text of the perl_action to run.</p>
364368 <p></p>
365369 </dd>
366 <dt><strong><a name="item__ps_pat">$ps_pat</a></strong></dt>
370 <dt><strong><a name="_ps_pat" class="item">$ps_pat</a></strong></dt>
367371
368372 <dd>
369373 <p>The Perl regular expression specified in the beginning of the section.</p>
370374 <p></p>
371375 </dd>
372 <dt><strong><a name="item__command">$command</a></strong></dt>
376 <dt><strong><a name="_command" class="item">$command</a></strong></dt>
373377
374378 <dd>
375379 <p>The command that matched $ps_pat.</p>
386390 action = echo \&quot;Looks like you have a big \$command program: \$vsz KB\&quot;</pre>
387391 <p></p>
388392 </dd>
389 <dt><strong><a name="item__count">$count</a></strong></dt>
393 <dt><strong><a name="_count" class="item">$count</a></strong></dt>
390394
391395 <dd>
392396 <p>The number of times the pattern matched. Presumably the number of
393397 processes of this class running.</p>
394398 <p></p>
395399 </dd>
396 <dt><strong><a name="item__trigger">$trigger</a></strong></dt>
400 <dt><strong><a name="_trigger" class="item">$trigger</a></strong></dt>
397401
398402 <dd>
399403 <p>A string containing the text of the trigger.</p>
423427 used.</p>
424428 <p></p>
425429 <dl>
426 <dt><strong><a name="item__args">$args</a></strong></dt>
430 <dt><strong><a name="_args" class="item">$args</a></strong></dt>
427431
428432 <dd>
429433 <p>The command along with its command arguments. It is possible that this
431435 the case on Solaris).</p>
432436 <p></p>
433437 </dd>
434 <dt><strong><a name="item__ppid">$ppid</a></strong></dt>
438 <dt><strong><a name="_ppid" class="item">$ppid</a></strong></dt>
435439
436440 <dd>
437441 <p>The parent process id.</p>
438442 <p></p>
439443 </dd>
440 <dt><strong><a name="item__stime">$stime</a></strong></dt>
444 <dt><strong><a name="_stime" class="item">$stime</a></strong></dt>
441445
442446 <dd>
443447 <p>The start time of the process.</p>
444448 <p></p>
445449 </dd>
446 <dt><strong><a name="item__etime">$etime</a></strong></dt>
450 <dt><strong><a name="_etime" class="item">$etime</a></strong></dt>
447451
448452 <dd>
449453 <p>The end time of the process.</p>
450454 <p></p>
451455 </dd>
452 <dt><strong><a name="item__pmem">$pmem</a></strong></dt>
456 <dt><strong><a name="_pmem" class="item">$pmem</a></strong></dt>
453457
454458 <dd>
455459 <p>The process memory.</p>
456460 <p></p>
457461 </dd>
458 <dt><strong><a name="item__pcpu">$pcpu</a></strong></dt>
462 <dt><strong><a name="_pcpu" class="item">$pcpu</a></strong></dt>
459463
460464 <dd>
461465 <p>The percent CPU utilization.</p>
462466 <p></p>
463467 </dd>
464 <dt><strong><a name="item__tty">$tty</a></strong></dt>
468 <dt><strong><a name="_tty" class="item">$tty</a></strong></dt>
465469
466470 <dd>
467471 <p>The controlling tty.</p>
468472 <p></p>
469473 </dd>
470 <dt><strong><a name="item__vsz">$vsz</a></strong></dt>
474 <dt><strong><a name="_vsz" class="item">$vsz</a></strong></dt>
471475
472476 <dd>
473477 <p>Virtual memory size of the process</p>
539543 <p>
540544 </p>
541545 <hr />
542 <h1><a name="using__prolog_for_getting_nonps_information">Using $PROLOG for getting non-ps information</a></h1>
546 <h1><a name="using__prolog_for_getting_non_ps_information">Using $PROLOG for getting non-ps information</a></h1>
543547 <p>Here is an example to show how to use ps-watcher to do something not
544548 really possible from ps: check to see if a <em>port</em> is active. We make
545549 use of lsof to check port 3333 and the $PROLOG make sure it runs.</p>
608612 <p>See also <em>ps(1)</em> and <em>syslogd(8)</em>.</p>
609613 <p>Another cool program doing ps-like things is <code>xps</code>. Well okay, it's
610614 another program I distributed. It shows the process tree dynamically
611 updated using X Motif and tries to display the output ``attractively''
615 updated using X Motif and tries to display the output &quot;attractively&quot;
612616 but fast. You can the find the homepage at
613617 <a href="http://motif-pstree.sourceforge.net">http://motif-pstree.sourceforge.net</a> and it download via
614618 <a href="http://prdownloads.sourceforge.net/motif-pstree?sort_by=date&sort=desc">http://prdownloads.sourceforge.net/motif-pstree</a></p>
00 #!/usr/bin/perl -w
11 # -*- Perl -*-
22 use diagnostics;
3 my $vcid='$Id: ps-watcher.in.in,v 1.62 2008/12/23 11:09:24 rockyb Exp $ ';
3 my $vcid='$Id: ps-watcher.in.in,v 1.63 2009/02/19 16:57:31 rockyb Exp $ ';
44 # See usage subroutine or perlpod documentation below.
55
66 # Copyright (C) 2000, 2002, 2003, 2004, 2005, 2006, 2008
2222
2323 use vars qw($program $ps_cmd $ps_cmdfull $ps_fullcmd_fmt @ps_vars $ps_dvars
2424 $0 $logopened $ps_args_fmt $args
25 $count $pid $command $ps_arg_opts $DEVNULL %opts
25 $count $pid $command $ps_arg_opts $DEVNULL %opts $PIDFILE
2626 );
27
28 $PIDFILE = "/var/run/ps-watcher.pid";
29
2730 use strict;
2831 BEGIN { require 5.00503 }
2932
129132 sub read_config($);
130133 sub check_config_file($);
131134 sub run_trigger($$$);
135 sub check_pid();
132136
133137 init();
134138 process_options();
146150 }
147151
148152 if ($opts{daemon}) {
149 daemonize();
153 if (! check_pid()) {
154 exit 1;
155 }
156 if (! daemonize()) {
157 exit 1;
158 }
150159 }
151160
152161 install_handlers();
585594 exit 10;
586595 }
587596
597 sub check_pid() {
598 if (-f $PIDFILE) {
599 if (open(PID,$PIDFILE)) {
600 my $pid = <PID>;
601 if (!close(PID)) {
602 logger("Unable to close file handle PID for file '$PIDFILE': $!");
603 return;
604 }
605 if (-f "/proc/$pid/stat") {
606 if (open(FH,"/proc/$pid/stat")) {
607 my $line = <FH>;
608 if (!close(FH)) {
609 logger("Unable to close file handle FH for file '/proc/$pid/stat': $!");
610 return;
611 }
612 if ($line =~ /\d+[^(]*\((.*)\)\s*/) {
613 my $process = $1;
614 if ($process =~ /^$program$/) {
615 logger("$program already running at PID $pid; exiting.");
616 exit(0);
617 }
618 }
619 } else {
620 logger("Unable to open file handle FH for file '/proc/$pid/stat': $!");
621 return;
622 }
623 } else {
624 logger("Removing stale PID file.");
625 unlink($PIDFILE);
626 }
627 }else{
628 logger("Unable to open file handle PID for file '$PIDFILE': $!");
629 return;
630 }
631 }
632 return 1;
633 }
588634
589635 sub daemonize() {
590636 chdir '/' or die "Can't chdir to /: $!";
591637 defined(my $pid = fork) or die "Can't fork: $!";
592638 exit 0 if $pid;
639 if (open(FH,">$PIDFILE")) {
640 print FH $$;
641 if (!close(FH)) {
642 logger("Unable to close file handle FH for file '$PIDFILE': $!");
643 return;
644 }
645 } else {
646 logger("Unable to open file handle FH for file '$PIDFILE': $!");
647 return;
648 }
593649 use POSIX qw(setsid);
594650 setsid() or die "Can't start a new session: $!";
595651 umask 0;
652 return 1;
596653 }
597654
598655 # Time configuration file was last read.
00 #!@PERL@ -w
11 # -*- Perl -*-
22 use diagnostics;
3 my $vcid='$Id: ps-watcher.in.in,v 1.62 2008/12/23 11:09:24 rockyb Exp $ ';
3 my $vcid='$Id: ps-watcher.in.in,v 1.63 2009/02/19 16:57:31 rockyb Exp $ ';
44 # See usage subroutine or perlpod documentation below.
55
66 # Copyright (C) 2000, 2002, 2003, 2004, 2005, 2006, 2008
2222
2323 use vars qw($program $ps_cmd $ps_cmdfull $ps_fullcmd_fmt @ps_vars $ps_dvars
2424 $0 $logopened $ps_args_fmt $args
25 $count $pid $command $ps_arg_opts $DEVNULL %opts
25 $count $pid $command $ps_arg_opts $DEVNULL %opts $PIDFILE
2626 );
27
28 $PIDFILE = "/var/run/ps-watcher.pid";
29
2730 use strict;
2831 BEGIN { require 5.00503 }
2932
129132 sub read_config($);
130133 sub check_config_file($);
131134 sub run_trigger($$$);
135 sub check_pid();
132136
133137 init();
134138 process_options();
146150 }
147151
148152 if ($opts{daemon}) {
149 daemonize();
153 if (! check_pid()) {
154 exit 1;
155 }
156 if (! daemonize()) {
157 exit 1;
158 }
150159 }
151160
152161 install_handlers();
575584 exit 10;
576585 }
577586
587 sub check_pid() {
588 if (-f $PIDFILE) {
589 if (open(PID,$PIDFILE)) {
590 my $pid = <PID>;
591 if (!close(PID)) {
592 logger("Unable to close file handle PID for file '$PIDFILE': $!");
593 return;
594 }
595 if (-f "/proc/$pid/stat") {
596 if (open(FH,"/proc/$pid/stat")) {
597 my $line = <FH>;
598 if (!close(FH)) {
599 logger("Unable to close file handle FH for file '/proc/$pid/stat': $!");
600 return;
601 }
602 if ($line =~ /\d+[^(]*\((.*)\)\s*/) {
603 my $process = $1;
604 if ($process =~ /^$program$/) {
605 logger("$program already running at PID $pid; exiting.");
606 exit(0);
607 }
608 }
609 } else {
610 logger("Unable to open file handle FH for file '/proc/$pid/stat': $!");
611 return;
612 }
613 } else {
614 logger("Removing stale PID file.");
615 unlink($PIDFILE);
616 }
617 }else{
618 logger("Unable to open file handle PID for file '$PIDFILE': $!");
619 return;
620 }
621 }
622 return 1;
623 }
578624
579625 sub daemonize() {
580626 chdir '/' or die "Can't chdir to /: $!";
581627 defined(my $pid = fork) or die "Can't fork: $!";
582628 exit 0 if $pid;
629 if (open(FH,">$PIDFILE")) {
630 print FH $$;
631 if (!close(FH)) {
632 logger("Unable to close file handle FH for file '$PIDFILE': $!");
633 return;
634 }
635 } else {
636 logger("Unable to open file handle FH for file '$PIDFILE': $!");
637 return;
638 }
583639 use POSIX qw(setsid);
584640 setsid() or die "Can't start a new session: $!";
585641 umask 0;
642 return 1;
586643 }
587644
588645 # Time configuration file was last read.