2 # Sample udhcpc bound script
4 RESOLV_CONF="/etc/udhcpc/resolv.conf"
6 [ -n "$broadcast" ] && BROADCAST="broadcast $broadcast"
7 [ -n "$subnet" ] && NETMASK="netmask $subnet"
9 /sbin/ifconfig $interface $ip $BROADCAST $NETMASK
13 echo "deleting routers"
14 while /sbin/route del default gw 0.0.0.0 dev $interface
21 /sbin/route add default gw $i dev $interface metric $((metric++))
25 # Only replace resolv.conf is we have at least one DNS server
28 echo -n > $RESOLV_CONF
29 [ -n "$domain" ] && echo domain $domain >> $RESOLV_CONF
33 echo nameserver $i >> $RESOLV_CONF