≡ Menu

default gateway

Linux Static IP Address Configuration

How do I configure the Internet Protocol version 4 (IPv4) properties of a network connection with a static IP address for servers running Linux operating systems? How do I configure static IP address under Debian Linux or Redhat / RHEL / Fedora / Redhat Enterprise Linux server?
[click to continue…]

CentOS / Redhat: KVM Bridged Network Configuration

With bridged networking you can share actual network device with KVM machines. This is required for servers with multiple network cards and gives you good performance. You can choose to put multiple segments into one bridged network or to divide it into different networks interconnected by routers.
[click to continue…]

What Is The Meaning of In Routing Table?

My home Linux laptop is connected to ADSL router and whenever I run route -n command at the prompt it says is set to my routers IP What is the meaning of
[click to continue…]

Ubuntu Linux Configure Gateway / Default Routing IP Address

Q. How do I configure default router or gateway IP address under Ubuntu Linux / Debian Linux? How do I change default router / gateway IP under Ubuntu Linux?
[click to continue…]

How To AIX UNIX Configure TCP/IP Networking ( NIC )

Q. How do I configuring TCP/IP and the network interface under AIX UNIX operating system?
[click to continue…]

Linux Share a Dial Up Internet Connection

Q. My modem is connected to CentOS Linux server. I'm using wvdial to connect to my ISP; I'd like to connect my laptop via same modem. How do I share a dial up Internet account?
[click to continue…]

Solaris UNIX Add Static Routes

Q. How do I add Static Routes under Solaris UNIX? My default gateway configured in /etc/defaultrouter, but what is the proper place to configure static routes for a Solaris UNIX server? Can you tell me exact configuration file name for a static routing?
[click to continue…]

Linux route Add Command Examples

I am a new Linux user. How do I add a new or default gateway using route command on Linux operating systems? How can I use route command to show or set a new route on Linux based server or desktop system?
[click to continue…]

Red Hat / CentOS Linux Setting a Default Gateway

Q. How do I setup up a default Gateway for all interfaces (eth0 and eth1) under CentOS Linux 5?

A.There are different ways to setup TCP/IP hosts so that you can reach to remote destinations. The simplest one is to setup default gateway by modifying the /etc/sysconfig/network

Setup a default Gateway

Open /etc/sysconfig/network file:
# vi /etc/sysconfig/network
Setup GATEWAY={Router-IP}, if router IP is, type:
Save and close the file. Here is my complete file:

You need to restart networking service:
# /etc/init.d/networking restart

Debian / Ubuntu Linux Setting a Default Gateway

Q. How do I setup a default gateway on Debian or Ubuntu Linux? My router IP is and I'd like to setup this as a default gateway for Debian Linux.

A. You can use command line tool such as
a] ip command - show / manipulate routing, devices, policy routing and tunnels

b] route command - show / manipulate the IP routing table

c] Save routing information to a configuration file so that after reboot you get same default gateway.

ip command to set a default router to

Login as the root and type:
# ip route add default via
$ sudo ip route add default via

route command to set a default router to

Login as the root and type:
# route add default gw
$ sudo route add default gw

Save routing information to a configuration file /etc/network/interfaces

Open /etc/network/interfaces file
# vi /etc/network/interfaces
$ sudo vi /etc/network/interfaces
Find eth0 or desired network interface and add following option
Save and close the file. Restart networking:
# /etc/init.d/networking restart
$ sudo /etc/init.d/networking restart