Q. What is the ip trace command in bash? How do I trace IP address in Linux / UNIX bash shell prompt?
A. You can use any one of the following command in bash to trace IP address and other stuff:
a] traceroute - It tracks the route packets take across an IP network on their way to a given host. It utilizes the IP protocol’s time to live (TTL) field and attempts to elicit an ICMP TIME_EXCEEDED response from each gateway along the path to the host.
b] tracepath - It traces path to destination discovering MTU along this path. It uses UDP port port or some random port. It is similar to traceroute, only does not not require uperuser privileges. Option -c causes tracepath to use the return address instead of the reply type (connection refused) to determine when to stop.
traceroute command example
To trace IP router it, enter:
$ traceroute {IP-address}
$ traceroute 202.54.2.5
$ traceroute google.com
Sample output:
1 sl1-dallas.simplyguide.org (74.86.48.97) 0.539 ms 0.740 ms 0.727 ms 2 po102.dar01.dal01.dallas-datacenter.com (66.228.118.177) 0.713 ms 0.705 ms 0.900 ms 3 po1.cer02.dal01.dallas-datacenter.com (66.228.118.204) 1.125 ms 1.115 ms 1.102 ms 4 xe-7-4.r02.dllstx09.us.bb.gin.ntt.net (157.238.224.69) 168.721 ms 168.716 ms 168.704 ms 5 4.68.63.221 (4.68.63.221) 1.748 ms te-10-1-0.edge2.Dallas3.level3.net (4.68.63.225) 1.722 ms 1.940 ms 6 ge-1-3-0-79.bbr2.Dallas1.Level3.net (4.68.19.66) 1.928 ms ge-1-3-0-79.bbr1.Dallas1.Level3.net (4.68.19.65) 1.055 ms ge-6-1-0-99.bbr1.Dallas1.Level3.net (4.68.19.193) 1.053 ms 7 as-1-0.bbr1.Atlanta1.Level3.net (209.247.9.101) 21.007 ms ae-0-0.bbr2.Atlanta1.Level3.net (64.159.1.46) 21.242 ms as-1-0.bbr1.Atlanta1.Level3.net (209.247.9.101) 21.235 ms 8 ae-21-52.car1.Atlanta1.Level3.net (4.68.103.34) 21.696 ms ae-11-51.car1.Atlanta1.Level3.net (4.68.103.2) 21.691 ms ae-21-52.car1.Atlanta1.Level3.net (4.68.103.34) 21.907 ms 9 GOOGLE-INC.car1.Atlanta1.Level3.net (4.78.209.194) 21.897 ms 22.126 ms 22.097 ms 10 209.85.254.243 (209.85.254.243) 22.576 ms 188.966 ms 209.85.254.241 (209.85.254.241) 22.549 ms 11 209.85.253.145 (209.85.253.145) 22.180 ms 209.85.253.133 (209.85.253.133) 30.700 ms 209.85.253.137 (209.85.253.137) 30.647 ms 12 yx-in-f100.google.com (74.125.45.100) 22.369 ms 22.295 ms 22.278 ms
tracert equivalents to traceroute -I
To run Windows equivalent tracert command, enter:
$ traceroute -I google.com
tracepath example
Type the command as follows:
$ tracepath {ip-address}
$ tracepath google.com
You should follow me on twitter here or grab rss feed to keep track of new changes.
Featured Articles:
- 30 Handy Bash Shell Aliases For Linux / Unix / Mac OS X
- Top 30 Nmap Command Examples For Sys/Network Admins
- 25 PHP Security Best Practices For Sys Admins
- 20 Linux System Monitoring Tools Every SysAdmin Should Know
- 20 Linux Server Hardening Security Tips
- Linux: 20 Iptables Examples For New SysAdmins
- Top 20 OpenSSH Server Best Security Practices
- Top 20 Nginx WebServer Best Security Practices
- 20 Examples: Make Sure Unix / Linux Configuration Files Are Free From Syntax Errors
- 15 Greatest Open Source Terminal Applications Of 2012

- My 10 UNIX Command Line Mistakes
- Top 10 Open Source Web-Based Project Management Software
- Top 5 Email Client For Linux, Mac OS X, and Windows Users
- The Novice Guide To Buying A Linux Laptop











![Bash Shell Scripting Disable Control-C [ CTRL+C ] Keys](http://s13.cyberciti.org/images/shared/rp/3/6.jpg)

{ 0 comments… add one now }