[NTLUG:Discuss] Default gateway -where set

Terry trryhend at gmail.com
Sat Aug 27 09:23:26 CDT 2005


On 8/27/05, Leroy Tennison <leroy_tennison at prodigy.net> wrote:
> Where is the default gateway set on Linux (Red Hat or SuSE)?  I found
> references to /etc/sysconfig/network (Red Hat) but the gateway paramater
> in it is commented out yet I have a defautl gateway set for eth1 (dhcp
> for my dsl).
> 
> 
> _______________________________________________
> https://ntlug.org/mailman/listinfo/discuss
> 

You can set the default gateway temporarily, (for current session
only), with command:
# route add default gw [gateway.ip#.here]
i.e. (example):
# route add default gw 10.1.0.1
If you want to use that gateway permanently put following line
GATEWAY=10.1.0.1
 in 
/etc/sysconfig/network-scripts/ifcfg-eth0
or
/etc/sysconfig/network-scripts/ifcfg-eth1 
or.... well, you get the idea.. right?

-- 
<><




More information about the Discuss mailing list