packages: munin/munin-plugins.patch, munin/munin.spec - rel 4 - ip6 compati...

baggins baggins at pld-linux.org
Wed Mar 16 12:44:51 CET 2011


Author: baggins                      Date: Wed Mar 16 11:44:51 2011 GMT
Module: packages                      Tag: HEAD
---- Log message:
- rel 4
- ip6 compatible fix for ip_ plugin

---- Files affected:
packages/munin:
   munin-plugins.patch (1.45 -> 1.46) , munin.spec (1.92 -> 1.93) 

---- Diffs:

================================================================
Index: packages/munin/munin-plugins.patch
diff -u packages/munin/munin-plugins.patch:1.45 packages/munin/munin-plugins.patch:1.46
--- packages/munin/munin-plugins.patch:1.45	Mon Sep 20 18:21:29 2010
+++ packages/munin/munin-plugins.patch	Wed Mar 16 12:44:45 2011
@@ -789,12 +789,18 @@
 +}' $NFSD
 --- munin-1.3.4/plugins/node.d.linux/ip_.in~	2008-03-08 02:42:39.000000000 +0100
 +++ munin-1.3.4/plugins/node.d.linux/ip_.in	2008-05-20 13:00:17.000000000 +0200
-@@ -40,16 +40,16 @@
+@@ -113,15 +113,19 @@
+     *:*) # I know this! This is IPv6!
  	# This is a fun hack to make the plugin ip6 compatible.
  	# Suggested in ticket #439 by "jodal".
- 	eval 'function iptables() {
+-	eval 'function iptables() {
 -	    /sbin/ip6tables "$@"
++	eval 'iptables() {
 +	    /usr/sbin/ip6tables "$@"
++	}'
++	;;
++    *) eval 'iptables() {
++	    /usr/sbin/iptables "$@"
  	}'
  	;;
  esac
@@ -804,33 +810,30 @@
 -		iptables -L ${INPUT} -v -n -x >/dev/null 2>/dev/null
 +		/usr/sbin/iptables -L ${INPUT} -v -n -x >/dev/null 2>/dev/null
  		if [ $? -gt 0 ]; then
--			echo "no (could not run iptables as user `whoami`)"
-+			echo "no (could not run /usr/sbin/iptables as user `whoami`)"
+ 			echo "no (could not run iptables as user `whoami`)"
  			exit 0
- 		else
- 			echo yes
-@@ -62,9 +62,9 @@
+@@ -136,9 +140,9 @@
  fi
  
  if [ "$1" = "suggest" ]; then
 -    iptables -L ${INPUT} -v -n -x 2>/dev/null | awk --posix '$8 ~ /^([0-9]{1,3}\.){3}[0-9]{1,3}$/ { if (done[$8]!=1) {print $8; done[$8]=1;}}'
-+    /usr/sbin/iptables -L ${INPUT} -v -n -x 2>/dev/null | awk --posix '$8 ~ /^([0-9]{1,3}\.){3}[0-9]{1,3}$/ { if (done[$8]!=1) {print $8; done[$8]=1;}}'
 -    if [ -x /sbin/ip6tables ]; then
 - 	ip6tables -L ${INPUT} -v -n -x 2>/dev/null | awk --posix '$7 ~ /\/128$/ { if (done[$7]!=1) {a=$7;gsub(/\/128$/, "", a); print a; done[$7]=1;}}'
++    /usr/sbin/iptables -L ${INPUT} -v -n -x 2>/dev/null | awk --posix '$8 ~ /^([0-9]{1,3}\.){3}[0-9]{1,3}$/ { if (done[$8]!=1) {print $8; done[$8]=1;}}'
 +    if [ -x /usr/sbin/ip6tables ]; then
 + 	/usr/sbin/ip6tables -L ${INPUT} -v -n -x 2>/dev/null | awk --posix '$7 ~ /\/128$/ { if (done[$7]!=1) {a=$7;gsub(/\/128$/, "", a); print a; done[$7]=1;}}'
      fi
      exit 0
  fi
-@@ -173,6 +173,6 @@
+@@ -173,6 +177,5 @@
  # Escape .'s so they don't match _everything_?
  IP="$( echo $IP | sed 's~\.~\\.~g' )"
  
 -iptables -L ${INPUT} -v -n -x   | awk "/$IP"'[ /]/ { print "in.value " $2; exit 0; }'
-+/usr/sbin/iptables -L ${INPUT} -v -n -x   | awk "/$IP"'[ /]/ { print "in.value " $2; exit 0; }'
- 
+-
 -iptables -L ${OUTPUT} -v -n -x  | awk "/$IP"'[ /]/ { print "out.value " $2; exit 0; }'
-+/usr/sbin/iptables -L ${OUTPUT} -v -n -x  | awk "/$IP"'[ /]/ { print "out.value " $2; exit 0; }'
++iptables -L ${INPUT} -v -n -x   | awk "/$IP"'[ \/]/ { print "in.value " $2; exit 0; }'
++iptables -L ${OUTPUT} -v -n -x  | awk "/$IP"'[ \/]/ { print "out.value " $2; exit 0; }'
 --- munin-1.3.4/plugins/node.d.linux/vlan_inetuse_.in~	2008-03-08 02:42:39.000000000 +0100
 +++ munin-1.3.4/plugins/node.d.linux/vlan_inetuse_.in	2008-05-20 13:00:50.000000000 +0200
 @@ -37,8 +37,8 @@

================================================================
Index: packages/munin/munin.spec
diff -u packages/munin/munin.spec:1.92 packages/munin/munin.spec:1.93
--- packages/munin/munin.spec:1.92	Wed Jan  5 18:37:00 2011
+++ packages/munin/munin.spec	Wed Mar 16 12:44:45 2011
@@ -11,7 +11,7 @@
 Summary(pl.UTF-8):	Munin - agent danych RRD Linpro
 Name:		munin
 Version:	1.4.5
-Release:	3
+Release:	4
 License:	GPL
 Group:		Applications/WWW
 Source0:	http://dl.sourceforge.net/munin/%{name}-%{version}.tar.gz
@@ -301,6 +301,10 @@
 All persons listed below can be reached at <cvs_login>@pld-linux.org
 
 $Log$
+Revision 1.93  2011/03/16 11:44:45  baggins
+- rel 4
+- ip6 compatible fix for ip_ plugin
+
 Revision 1.92  2011/01/05 17:37:00  baggins
 - rel 3
 
================================================================

---- CVS-web:
    http://cvs.pld-linux.org/cgi-bin/cvsweb.cgi/packages/munin/munin-plugins.patch?r1=1.45&r2=1.46&f=u
    http://cvs.pld-linux.org/cgi-bin/cvsweb.cgi/packages/munin/munin.spec?r1=1.92&r2=1.93&f=u



More information about the pld-cvs-commit mailing list