aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorDoug Knight <doug.knight@karmix.org>2011-10-07 11:59:17 -0800
committerBill Nottingham <notting@redhat.com>2011-10-07 16:28:26 -0400
commit10879fce0abfb298ae7dcf231572825aa3bedce9 (patch)
treea14bf67e21ac2b26790dfc685cb6f30cb18b8d20
parent0111a41100a30c0ff6324b8aab5de296d8ec1faf (diff)
downloadinitscripts-10879fce0abfb298ae7dcf231572825aa3bedce9.tar
initscripts-10879fce0abfb298ae7dcf231572825aa3bedce9.tar.gz
initscripts-10879fce0abfb298ae7dcf231572825aa3bedce9.tar.bz2
initscripts-10879fce0abfb298ae7dcf231572825aa3bedce9.tar.xz
initscripts-10879fce0abfb298ae7dcf231572825aa3bedce9.zip
Only use the first ARP response in netconsole (#744309)
-rw-r--r--rc.d/init.d/netconsole2
1 files changed, 1 insertions, 1 deletions
diff --git a/rc.d/init.d/netconsole b/rc.d/init.d/netconsole
index 7f91a6c6..42733de0 100644
--- a/rc.d/init.d/netconsole
+++ b/rc.d/init.d/netconsole
@@ -54,7 +54,7 @@ print_address_info ()
target=$host
fi
if [ -z "$SYSLOGMACADDR" ]; then
- arp=$(LANG=C /sbin/arping -c 1 -I $DEV $target 2>/dev/null | awk '/ reply from .*[.*]/ { print gensub(".* reply from .* \\[(.*)\\].*","\\1","G") }')
+ arp=$(LANG=C /sbin/arping -c 1 -I $DEV $target 2>/dev/null | awk '/ reply from .*[.*]/ { print gensub(".* reply from .* \\[(.*)\\].*","\\1","G"); exit }')
[ -n "$arp" ] && echo "SYSLOGMACADDR=$arp"
fi
}