Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- # lines 97 to 108 of /etc/rc.d/rc.network
- # http://www.pearltrees.com/s243a/stop-all-rc-network-puppylinux/id16440719
- # A function to stop everything (at shutdown, for example)
- # Enable accepting a param to pass to ifconfig (i.e. -a)
- stop_all(){
- for INTERFACE in $(ifconfig $1 | grep -F 'Link encap:Ethernet' | cut -f 1 -d " ") ; do
- # Skip it wake-on-lan enabled # 7mar10 stop even wake-on-lan enabled
- #ethtool $INTERFACE | grep -Fq 'Wake-on: g' && continue
- # clean up (kills dhcpcd, wpa_supplicant etc.)
- cleanUpInterface "$INTERFACE" >/dev/null 2>&1
- ip route flush dev "$INTERFACE"
- ifconfig "$INTERFACE" down
- done
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement