Changeset 35657


Ignore:
Timestamp:
2013-02-18T10:59:35+01:00 (5 years ago)
Author:
florian
Message:

muninlite: fix getting bridge data

This patch fix a bug while getting data for interfaces like br-lan, pppoa-wan.

[florian: bump PKG_RELEASE to 4]

Signed-off-by: Luca Dariz <luca.dariz@…>
Signed-off-by: Florian Fainelli <florian@…>

Location:
packages/admin/muninlite
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • packages/admin/muninlite/Makefile

    r30983 r35657  
    1010PKG_NAME:=muninlite 
    1111PKG_VERSION:=1.0.4 
    12 PKG_RELEASE:=3 
     12PKG_RELEASE:=4 
    1313 
    1414PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz 
  • packages/admin/muninlite/patches/210-add-bridge-devs.patch

    r26974 r35657  
    11--- a/munin-node.in 
    22+++ b/munin-node.in 
    3 @@ -72,7 +72,8 @@ RES="" 
     3@@ -72,17 +72,17 @@ RES="" 
    44 for PLUG in $PLUGINS 
    55 do  
    66   if [ "$PLUG" = "if_" ]; then   
    77-    for INTER in $(grep '^ *\(ppp\|eth\|wlan\|ath\|ra\|ipsec\|tap\)\([^:]\)\{1,\}:' /proc/net/dev | cut -f1 -d: | sed 's/ //g'); 
    8 +    for INTER in $(grep '^ *\(ppp\|eth\|wlan\|ath\|ra\|ipsec\|tap\|br-\)\([^:]\)\{1,\}:' /proc/net/dev | cut -f1 -d: | sed 's/ //g 
    9 +s/\-/_/g'); 
     8+    for INTER in $(grep '^ *\(ppp\|eth\|wlan\|ath\|ra\|ipsec\|tap\|br-\)\([^:]\)\{1,\}:' /proc/net/dev | cut -f1 -d: | sed 's/ //g'); 
    109     do 
    11        INTERRES=$(echo $INTER | sed 's/\./VLAN/') 
     10-      INTERRES=$(echo $INTER | sed 's/\./VLAN/') 
     11+      INTERRES=$(echo $INTER | sed -e 's/\./VLAN/' -e 's/\-/_/') 
    1212       RES="$RES if_$INTERRES" 
    13 @@ -80,7 +81,8 @@ do 
     13       eval "fetch_if_${INTERRES}() { fetch_if $INTER $@; };" 
    1414       eval "config_if_${INTERRES}() { config_if $INTER $@; };" 
    1515     done 
    1616   elif [ "$PLUG" = "if_err_" ]; then 
    1717-    for INTER in $(grep '^ *\(ppp\|eth\|wlan\|ath\|ra\|ipsec\|tap\)\([^:]\)\{1,\}:' /proc/net/dev | cut -f1 -d: | sed 's/ //g'); 
    18 +    for INTER in $(grep '^ *\(ppp\|eth\|wlan\|ath\|ra\|ipsec\|tap\|br-\)\([^:]\)\{1,\}:' /proc/net/dev | cut -f1 -d: | sed 's/ //g 
    19 +s/\-/_/g'); 
     18+    for INTER in $(grep '^ *\(ppp\|eth\|wlan\|ath\|ra\|ipsec\|tap\|br-\)\([^:]\)\{1,\}:' /proc/net/dev | cut -f1 -d: | sed 's/ //g'); 
    2019     do 
    21        INTERRES=$(echo $INTER | sed 's/\./VLAN/') 
     20-      INTERRES=$(echo $INTER | sed 's/\./VLAN/') 
     21+      INTERRES=$(echo $INTER | sed -e 's/\./VLAN/' -e 's/\-/_/') 
    2222       RES="$RES if_err_$INTERRES" 
     23       eval "fetch_if_err_${INTERRES}() { fetch_if_err $INTER $@; };" 
     24       eval "config_if_err_${INTERRES}() { config_if_err $INTER $@; };" 
Note: See TracChangeset for help on using the changeset viewer.