Lines Matching refs:dev
34 dev=${1%:*}
35 if [ "$dev" = "" -o "$1" = "help" ]; then
55 if [ "$ldev" != "$dev" ]; then
59 ip -4 addr flush dev $dev $label || exit 1
100 if [ "$ldev" = "$dev" -a "$ipaddr" != "" ]; then
105 ip addr del $pfx dev $dev $label || exit 1
111 if ! ip link set up dev $dev ; then
112 echo "Error: cannot enable interface $dev." 1>&2
117 if ! arping -q -c 2 -w 3 -D -I $dev $ipaddr ; then
118 echo "Error: some host already uses address $ipaddr on $dev." 1>&2
122 if ! ip address add $pfx brd + dev $dev $label; then
123 echo "Error: failed to add $pfx on $dev." 1>&2
127 arping -q -A -c 1 -I $dev $ipaddr
130 arping -q -U -c 1 -I $dev $ipaddr ) >& /dev/null </dev/null &
132 ip route add unreachable 224.0.0.0/24 >& /dev/null
133 ip route add unreachable 255.255.255.255 >& /dev/null
134 if [ "`ip link ls $dev | grep -c MULTICAST`" -ge 1 ]; then
135 ip route add 224.0.0.0/4 dev $dev scope global >& /dev/null
140 ip ro append default dev $dev metric 30000 scope global
143 ip ro append default via $peer dev $dev metric 30001