summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: dd2c298)
raw | patch | inline | side by side (parent: dd2c298)
author | cajus <cajus@594d385d-05f5-0310-b6e9-bd551577e9d8> | |
Thu, 21 Jun 2007 07:56:26 +0000 (07:56 +0000) | ||
committer | cajus <cajus@594d385d-05f5-0310-b6e9-bd551577e9d8> | |
Thu, 21 Jun 2007 07:56:26 +0000 (07:56 +0000) |
git-svn-id: https://oss.gonicus.de/repositories/gosa/trunk@6640 594d385d-05f5-0310-b6e9-bd551577e9d8
contrib/scripts/net-resolver.sh | patch | blob | history |
index 98364c271f6a8ba6042670054c083a51748e508f..bd120264a12689a1eb4dd102e9c9f2e26d416e5f 100755 (executable)
mac=""
ip=$(LANG=C $host $1 | grep address | head -n1 | sed 's/^.*[^0-9]\([0-9][0-9]*\.[0-9][0-9]*\.[0-9][0-9]*\.[0-9][0-9]*\).*$/\1/g')
+if [ -z "$ip" ]; then
+ echo ";"
+ exit 0
+fi
if $fping -c1 -r3 -t500 $ip &> /dev/null; then
mac=$($arp -n | awk "/^$ip/ {print \$3}")
fi