mirror of
https://github.com/Ysurac/openmptcprouter-feeds.git
synced 2025-03-09 15:40:03 +00:00
fix netift
This commit is contained in:
parent
b76bbb581c
commit
5930a09dfc
38 changed files with 1918 additions and 68 deletions
|
@ -14,8 +14,8 @@ set_classless_routes() {
|
|||
}
|
||||
|
||||
setup_interface() {
|
||||
echo "udhcpc: ip addr add $ip/${subnet:-255.255.255.0} broadcast ${broadcast:-+} dev $interface"
|
||||
ip addr add $ip/${subnet:-255.255.255.0} broadcast ${broadcast:-+} dev $interface
|
||||
echo "udhcpc: ifconfig $interface $ip netmask ${subnet:-255.255.255.0} broadcast ${broadcast:-+}"
|
||||
ifconfig $interface $ip netmask ${subnet:-255.255.255.0} broadcast ${broadcast:-+}
|
||||
|
||||
[ -n "$router" ] && [ "$router" != "0.0.0.0" ] && [ "$router" != "255.255.255.255" ] && {
|
||||
echo "udhcpc: setting default routers: $router"
|
||||
|
@ -41,7 +41,7 @@ setup_interface() {
|
|||
applied=
|
||||
case "$1" in
|
||||
deconfig)
|
||||
ip -4 addr flush dev "$interface"
|
||||
ifconfig "$interface" 0.0.0.0
|
||||
;;
|
||||
renew)
|
||||
setup_interface update
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue