Porting SUSE's mon RPM to redhat (I'm intending to make it workable on any 
generic RPM-based distro, really), I came across a couple of patches  
of interest:

[EMAIL PROTECTED] /usr/src/redhat/SOURCES]# cat mon-perl-path.diff
diff -ru mon-0.99.2.orig/mon.d/file_change.monitor 
mon-0.99.2.lmb/mon.d/file_change.monitor
--- mon-0.99.2.orig/mon.d/file_change.monitor   Fri Jul 27 17:39:59 2001
+++ mon-0.99.2.lmb/mon.d/file_change.monitor    Fri Jul 26 12:23:20 2002
@@ -1,4 +1,4 @@
-#!/usr/local/bin/perl
+#!/usr/bin/perl
 #
 # mon monitor to watch for file changes
 #
Only in mon-0.99.2.lmb/mon.d: file_change.monitor~
diff -ru mon-0.99.2.orig/mon.d/up_rtt.monitor mon-0.99.2.lmb/mon.d/up_rtt.monitor
--- mon-0.99.2.orig/mon.d/up_rtt.monitor        Fri Jul 27 17:39:59 2001
+++ mon-0.99.2.lmb/mon.d/up_rtt.monitor Fri Jul 26 12:23:27 2002
@@ -1,4 +1,4 @@
-#!/usr/local/bin/perl
+#!/usr/bin/perl
 #
 # mon monitor to check for circuit up and measure RTT
 #

The ~ file notwithstanding, the second hunk has been applied but the
file_change.monitor in CVS still points at /usr/local/bin/perl and 
should probably be fixed -- the rest of alert.d and mon.d says /usr/bin

The next one looks harmless and potentially useful, I guess -- if it can't
run the real dialin.monitor setgid, the return code back to mon will be
nonzero, rather than silently failing.

--- mon.d/dialin.monitor.wrap.c
+++ mon.d/dialin.monitor.wrap.c 2004/02/27 08:27:15
@@ -25,5 +25,5 @@
     argv[0] = real_img;

     /* exec */
-    execv (real_img, argv);
+    return execv (real_img, argv);
 }

Archive-diving shows similar patches from the debian maintainer a while back:
http://marc.theaimsgroup.com/?l=mon&m=100047605305261&w=4

There's one more patch but its just really specific alerts to send stuff
over the Brazilian paging/cell networks.

Spec file to come shortly

-- 
  Eric Sorenson - Systems / Network Administrator, MIS - Transmeta Corporation

_______________________________________________
mon mailing list
[EMAIL PROTECTED]
http://linux.kernel.org/mailman/listinfo/mon

Reply via email to