[mon/el6] Fix logging to syslog. Same was fixed in debian's mon in 2011.

Jan-Frode Myklebust janfrode at fedoraproject.org
Sun Oct 20 11:49:36 UTC 2013


commit 7d54f2bec22fc7b6b672101c6646021463270695
Author: Jan-Frode Myklebust <janfrode at tanso.net>
Date:   Sun Oct 20 13:41:43 2013 +0200

    Fix logging to syslog. Same was fixed in debian's mon in 2011.
    
    Ref:
       http://sourceforge.net/p/mon/bugs/107/
       http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=611751
       http://anonscm.debian.org/gitweb/?p=collab-maint/mon.git;a=commit;h=9d4e7dbfc523c49ad0ff4b40d3481bebfff32430

 mon.spec     |    9 ++++++++-
 syslog.patch |   14 ++++++++++++++
 2 files changed, 22 insertions(+), 1 deletions(-)
---
diff --git a/mon.spec b/mon.spec
index 02eee07..5cac7c5 100644
--- a/mon.spec
+++ b/mon.spec
@@ -7,7 +7,7 @@
 Name:           mon
 Summary:        General-purpose resource monitoring system
 Version:        1.2.0
-Release:        8%{?dist}
+Release:        9%{?dist}
 License:        GPLv2+
 Group:          Applications/Internet
 URL:            http://www.kernel.org/software/mon/
@@ -22,6 +22,9 @@ Source5:        userfile
 
 Patch0:         mon-1.2.0-perl.patch
 Patch1:         mon-1.2.0-uucp.patch
+# #107 mon is not logging anything to syslog 
+# http://sourceforge.net/p/mon/bugs/107/
+Patch2:         syslog.patch
 
 Requires:       perl(Authen::PAM)
 Requires:       iputils
@@ -50,6 +53,7 @@ required, the mon server will not need to be changed.
 %setup -q -a 1 -a 2
 %patch0 -p1
 %patch1 -p1
+%patch2 -p1
 
 # Filter out unwanted requires
 cat << \EOF > %{name}-req
@@ -172,6 +176,9 @@ fi
 
 
 %changelog
+* Fri Oct 11 2013 Jan-Frode Myklebust <janfrode at tanso.net> - 1.2.0-9
+- Add patch for upstream bug #107, mon not logging anything to syslog.
+
 * Sun Apr 24 2011 Jan-Frode Myklebust <janfrode at tanso.net> - 1.2.0-8
 - Remove perl-Authen-Radius dependency since it's not available in EPEL6 either.
 
diff --git a/syslog.patch b/syslog.patch
new file mode 100644
index 0000000..a86bd55
--- /dev/null
+++ b/syslog.patch
@@ -0,0 +1,14 @@
+--- a/mon	2011-02-01 14:13:05.425802661 -0500
++++ b/mon	2011-02-01 14:17:43.814709129 -0500
+@@ -5392,9 +5392,10 @@
+ 
+ no warnings; # Redefining syslog
+ sub syslog {
++   my @args = @_;
+    eval {
+        local $SIG{"__DIE__"}= sub { }; 
+-       my @log = map { s/\%//mg; } @_;
++       my @log = map { s/\%//mg; $_ } @args;
+        Sys::Syslog::syslog(@log);
+    }
+ }


More information about the scm-commits mailing list