Update subnet-up.tmpl
This commit is contained in:
parent
5e833c5471
commit
f252a38d97
@ -6,11 +6,13 @@ if [ -z "\$nonMACChars" ]; then
|
|||||||
# This subnet is a MAC
|
# This subnet is a MAC
|
||||||
echo "\$SUBNET" > \$macFile
|
echo "\$SUBNET" > \$macFile
|
||||||
else
|
else
|
||||||
# This subnet is likely an IP address, add it to the ARP table
|
if echo "\$SUBNET" | grep -q -E ".+/32$"; then
|
||||||
if test -f "\$macFile"; then
|
# This subnet is likely an IP address, add it to the ARP table
|
||||||
mac=`cat \$macFile`
|
if test -f "\$macFile"; then
|
||||||
arp -s "\$SUBNET" "\$mac"
|
mac=`cat \$macFile`
|
||||||
else
|
arp -s "\$SUBNET" "\$mac"
|
||||||
echo "[WARNING] No MAC known for node \$NODE, can't route \$SUBNET. This is only a problem if this is a remote route."
|
else
|
||||||
|
echo "[WARNING] No MAC known for node \$NODE, can't route \$SUBNET. This is only a problem if this is a remote route."
|
||||||
|
fi
|
||||||
fi
|
fi
|
||||||
fi
|
fi
|
||||||
|
Loading…
x
Reference in New Issue
Block a user