IP Address: 38.107.191.102
Hostname: 38.107.191.102

 

How to Change the Default Gateway in Linux

How can I change my default gateway in Linux?

Save to del.icio.us


Your machine needs to have a single default gateway. DHCP servers will automatically assign a default gateway to DHCP configured NICs, but NICs with configured static IP addresses will need to have a manually configured default gateway. This can be done with a simple command.

[root@linux etc]# route add default gw 192.168.1.1 eth0

In this case, make sure that the router/firewall with IP address 192.168.1.1 is connected to the same network as interface eth0!

Once done, you’ll need to update your /etc/sysconfig/network file to reflect the change. This file is used to configure your default gateway each time Linux boots.

NETWORKING=yes
HOSTNAME=linux
GATEWAY=192.168.1.1

Sponsored Ads:

Big Image

Ad Space

Random Articles:

Reset Trend IMSS Web Console Password

How can I reover my password for Trend InterScan Messaging Security Suite?

Create Duplicate User Profile

How to create a duplicate user profile with a different user name.

Recent Articles:

Outbound Call Problems with Cisco Call Manager

Users unable to make outbound 10 digit calls when using MGCP

Reset Websense Manager Password

How can I reset the password for the WebsenseAdministrator?

Disabling SSLv2

How can I disable SSL version 2 in Apache and IIS?