Skip to content

Instantly share code, notes, and snippets.

@thorr18
Created August 15, 2019 00:20
Show Gist options
  • Save thorr18/61cb741bf3b5e0ca8446642b33683c4c to your computer and use it in GitHub Desktop.
Save thorr18/61cb741bf3b5e0ca8446642b33683c4c to your computer and use it in GitHub Desktop.
#!/usr/bin/env bash
mainInt="en4"
netstat -nr -f inet
for i in {0..3}; do
echo flushing,...
sudo route -n flush
done
netstat -nr -f inet
echo bouncing $mainInt,...
sudo ifconfig $mainInt down
sleep 1
sudo ifconfig $mainInt up
sleep 2
netstat -nr -f inet
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment