Skip to content

Instantly share code, notes, and snippets.

@lbdremy
Last active December 17, 2015 11:49
Show Gist options
  • Save lbdremy/5604643 to your computer and use it in GitHub Desktop.
Save lbdremy/5604643 to your computer and use it in GitHub Desktop.
routing configuration for my pi
pi@raspberrypi ~ $ route -n
Kernel IP routing table
Destination     Gateway         Genmask         Flags Metric Ref    Use Iface
0.0.0.0         192.168.1.254   0.0.0.0         UG    0      0        0 wlan0
0.0.0.0         10.5.5.1        0.0.0.0         UG    2      0        0 eth0
10.5.5.0        0.0.0.0         255.255.255.0   U     0      0        0 eth0
192.168.1.0     0.0.0.0         255.255.255.0   U     0      0        0 wlan0

configured with route utility. e.g:

sudo route add -net default gw 10.5.5.1 netmask 0.0.0.0 dev eth0 metric 2
sudo route del -net default gw 10.5.5.1 netmask 0.0.0.0 dev eth0 metric 0
sudo route add -net default gw 192.168.1.254 netmask 0.0.0.0 dev wlan0 metric 0
sudo route del -net default gw 0.0.0.0.0 netmask 255.255.255.0 dev wlan0 metric 0
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment