Tuesday, December 24, 2013

Linux : Ip Commands

Linux : Ip Commands

ifconfig : Display Current Config for all NIC’s.

ifconfig eth0 : Display Current Config for eth0.

ifconfig eth0 : Assign IP.

ping -c 3 : Ping.

ifconfig eth0:0 : Assign multiple IP’s.

ifconfig eth0:1 : Assign second IP.

ifconfig eth0 down : Disable network card.

ifconfig eth0 up : Enable network card.

route “or” route -n : View current routing table.

arp “or” arp -n : View arp cache.

ifconfig eth0 netmask : Assign IP/Subnet.

route add default gw : Assign Default Gateway.

traceroute www.google.com : Trace Route.

tracepath www.google.com : Trace Path.

host www.google.com : DNS Test.

dig www.google.com : Advanced DNS Test.

Note : Some commands will need root privilege, so better to Enter as Root to perform them all.


Share this article :


Post a Comment