Change ip route metric

Posted by notphunny on Server Fault See other posts from Server Fault or by notphunny
Published on 2012-11-02T17:01:48Z Indexed on 2012/11/02 17:05 UTC
Read the original article Hit count: 174

Filed under:
|
|

I'm constantly switching between eth0 and wlan0 interface on my archlinux because I often change OpenWrt fw images on my second router (which isn't connected anywhere).

So I have problem with my routes when I'm connected to my wlan and want to connect with Ethernet to my router.

Both routers are on 192.168.1.1/24 and after connecting to my Ethernet profile eth0 route becomes default one (which is ok for the time), because of smaller metric I guess.

So I'm interested, how can I change routes metric so my applications can be connected to the internet (through out wlan)?

Maybe there is solution not to use Default Gateway on Ethernet profile, however I still want to know how to change metric. Or default route if there are more then one.

© Server Fault or respective owner

Related posts about linux

Related posts about ip