How To Assign Default Gateway In Linux?

How to Assign Default gateway in linux?Ans : In linux Default gateway is set through route command or GUI tools.Through Route command#route add default gw default-gatewayExample :#route add default gw 192.168.0.1Here 192.168.0.1 is the default gate of my system.Through GUI toolsUse system-config-network in terminal or GUI to set up default gateway. Please visit http://www.linuxnix.com for(…)

How To View Default Gateway In Linux?

This is asked in some of the interviews. We can get default gateway information in linux in many ways. Such as viewing network card file or executing a command.To see default gateway by view network interface card file content.#cat /etc/sysconfig/networking/devices/interface-noExample :[root@example ~]# cat /etc/sysconfig/networking/devices/ifcfg-eth0# Intel Corporation 82546EB Gigabit Ethernet Controller (Copper)DEVICE=eth0BOOTPROTO=noneHWADDR=00:02:a5:4c:af:99ONBOOT=yesTYPE=EthernetNETMASK=255.255.255.0IPADDR=10.200.0.21GATEWAY=10.200.0.1Through route commandrouteExample:Kernel IP routing(…)

How To Assign Or Change Hostname In Linux and Unix?

Computers are assigned with a name as we do for humans beings. This is called hostname in computer world. So how to assign a hostname to a Linux system? Its very much simple. Before doing this we should know every task in Linux can be done in two ways : 1. Temporary way(once you boot(…)