EzDevInfo.com

traceroute interview questions

Top traceroute frequently asked interview questions

Linux Traceroute and Linux Tracert

Im with a problem with traceroute on linux, the command traceroute its not working but tracert is working but both commands run the traceroute command, tracert is just a symbolic link to traceroute strangely just tracert work.

Attached is the image.

traceroute not working, just tracert

Somebody can help?


Source: (StackOverflow)

How to print only an IP address list of traceroute?

How do I print only an IP address list of a traceroute run?

I don't want the web addresses like something-online.net and their round trip times.

How do I get a "simple" traceroute from the terminal?


Source: (StackOverflow)

Advertisements

Destination IP Faking?

I have a closed-source Windows 7 application that wants to make an HTTP connection to an internet-resident IP address. I want it to instead make it connect to a LAN IP address.

If the application went after a DNS entry, I would just let my internal DNS server dictate where the resource is, or change the HOSTS file. But it's not using DNS, just IP.

I tried using the Windows route commands but nothing seems to work.

Can anyone recommend an OS-level workaround to proxy/fake/route one IP address with another?

Thanks.


Source: (StackOverflow)

Packet sizes for ping and traceroute

Why is a ping packet's data length 32 while a traceroute packet's data length is 64 bytes? Is there any reason for that? Or are there any advantages for this difference?


Source: (StackOverflow)

Slow tracert between hops

Each hop in the tracert reports 2ms or less latency, but trying to get to the end of one hop to another goes really slow. What would cause the latency to be so low yet take so long to perform the hop?


Source: (StackOverflow)

Can't ping but can access internet just fine?

I'm wondering if anyone has ideas on this one, since it's a first for me. I can access the internet just fine with a browser, but using PING or TRACERT from a command prompt just shows requests timing out once they leave my network.

To take some variables out of the equation, I tried reducing my network infrastructure down to just the Comcast cable line coming out of the wall connected to a Linksys BEFCMU10 v4 cable modem which went directly to my Windows 7 laptop with no software firewall, and the issue was still present.

Again, I'm browsing the internet (like posting this question) just fine, but can't ping anything (including this site right now) without all the packets getting lost.

I'm not blocking ICMP on my side, and I don't suspect Comcast is systematically blocking it all the sudden. What am I overlooking?


Source: (StackOverflow)

I can tracert to an IP address, but not ping it

On Windows, if I tracert to Google I get the following;

C:\Users\Dave>tracert -d -w 100 www.google.com

Tracing route to www.google.com [216.58.220.100]
over a maximum of 30 hops:

  1    <1 ms    <1 ms    <1 ms  192.168.1.1
  2    17 ms     *       16 ms  [redacted]
  3    17 ms    16 ms    17 ms  [redacted]
  4    34 ms    34 ms    34 ms  150.101.33.18
  5    35 ms    43 ms    33 ms  72.14.221.174
  6    33 ms    33 ms    33 ms  66.249.95.234
  7    31 ms    31 ms    31 ms  209.85.142.11
  8    33 ms    33 ms    38 ms  216.58.220.100

Trace complete.

Now, if I ping the third last IP address of 66.249.95.234, I get this...

C:\Users\Dave>ping 66.249.95.234

Pinging 66.249.95.234 with 32 bytes of data:
Request timed out.
Request timed out.
Request timed out.
Request timed out.

Ping statistics for 66.249.95.234:
    Packets: Sent = 4, Received = 0, Lost = 4 (100% loss),

How is it that the 'ping' internal to tracert somehow works differently to that of the real ping? How are they different? What do I need to do to get ping to work like tracert?


Source: (StackOverflow)

what does it mean if nslookup and ping fail to resolve a host name but tracert does not?

This problem concerns an internal DNS server that for some reason sometimes fails to resolve the host names of some machines on the network. When it fails to resolve a host name, and this can happen on any client machine, the following commands return the following:

ipconfig /displaydns:
vm1host.domain.local - Name does not exist.

nslookup vm1host:
dnsserver1.domain.local can't find vm1host: Non-existent domain

ping vm1host:
Ping request could not find host vm1host. Please check the name and try again.

tracert vm1host:
Unable to resolve target system name vm1host.

nslookup vm1host.domain.local :
dnsserver1.domain.local can't find vm1host.domain.local: Non-existent domain

ping vm1host.domain.local:
Ping request could not find host vm1host.domain.local Please check the name and try again.

tracert vm1host.domain.local:
Unable to resolve target system name vm1host.domain.local.

nslookup <vm1-ip-address>:
Works Ok...

ping <vm1-ip-address>:
Works Ok...

tracert <vm1-ip-address>: Works Ok... (also displays vm1host.domain.local)

Interestingly, tracert resolves the name appropriately using only 2 hops.

Even if subsequently nslookup/ping the host name, I get the same error messages above.

Flushing the dns does nothing, and even if it did it would not solve the underlying problem since it is experienced by all client machines.

What does the failure of nslookup/ping but the success of tracert suggest about the underlying problem?


Source: (StackOverflow)

I can get in, but I can't get out

Like most technical folks, I suppose, I'm my family's primary source of tech support. I'm a developer--not a sysadmin--by trade and tonight I bumped into something I've never seen before. I'm hoping someone here has.

In order to better help my Mom, I have her set up on a home network behind a Linksys router (WRT54G). She's got a Mac, so I have her router set up to forward SSH requests to her laptop's internal IP. I also have her router running DDNS through DynDns. Tonight she called to tell me that she can't access the Internet.

Assuming it was one of the many simple, stupid problems most of us encounter with parents, I logged into the router admin remotely and took a look around. Everything looked normal. Then I SSH'd into her machine to check out her IP, DNS, etc. settings. Everything still looked fine. Then I noticed something weird. When SSH'd into her machine, I can't ping her router.

In other words, I seem to be able to access her computer through her router, but not access her router from her computer. A traceroute dies immediately as well. Any ideas what I might try next? I've bounced her computer and even unplugged her router (it was plugged back in, of course).

Thanks.

UPDATE:

Oddly, this could be a problem at the ISP level. I walked her through bypassing the router all together (plugging her computer directly into her cable modem) and she still can't get out (where "get out" means "access a web page using Safari"). What confuses me is that I'm able to get in. That seems very odd to me.


Source: (StackOverflow)

Why does my tracert output not match my ipconfig?

When I ran into some intermittent Internet connectivity issues the other day at home, I decided to do something I rarely bother with - I plugged my laptop directly into the cable modem to see what was up. Once the connection came back up, I decided to do some diagnostics while I was still directly connected to be sure everything was properly functioning.

During this test:

  • My laptop was plugged directly into the cable modem.
    • As far as I know, this is a "dummy" modem - it's not an all-in-one cable modem/router/wifi device.
  • I had no other devices on the network being tested.
  • My laptop received an IP address and gateway via DHCP, both of which were publicly-routable "Class A" addresses.

If I ran a pathping or tracert to the gateway, everything came back normal - nothing appeared to be in between my laptop and the gateway.

However, when I ran the same utilities against other targets (Google, Yahoo, etc.) on the Internet, the first hop came back in the "Class A" range of RFC 1918 addresses. Also, the publicly-routable Default Gateway address did not show up at all in the traces.

Again, the only devices connected in my house at this point were my laptop and the cable modem. So, presumably the first hop to any address not in my DHCP-assigned subnet should always be whichever address shows up in ipconfig as the "Default Gateway".

Could someone explain how this can happen, and why there might be legitimate reason for it?


Source: (StackOverflow)

Traceroute to IP address fails, but traceroute to domain name with same IP address is okay. Why?

When I traceroute to this IP (108.162.198.181) it stops after 1 hop. But tracerouting to a domain (www.gomodule.com) with the same IP shows 9 hops ending in that target.

traceroute to www.gomodule.com (108.162.198.81), 64 hops max, 52 byte packets
 1  192.168.1.1 (192.168.1.1)  131.667 ms  48.532 ms  48.837 ms
 2  118.69.255.124 (118.69.255.124)  91.521 ms  79.177 ms  30.679 ms
 3  42.117.11.225 (42.117.11.225)  30.270 ms  32.091 ms  29.698 ms
 4  118.69.253.213 (118.69.253.213)  32.234 ms
    118.69.253.237 (118.69.253.237)  70.667 ms
    118.69.253.213 (118.69.253.213)  82.440 ms
 5  118.69.253.245 (118.69.253.245)  64.554 ms  80.277 ms  130.224 ms
 6  118.69.251.205 (118.69.251.205)  65.635 ms
    118.69.249.78 (118.69.249.78)  133.234 ms
    118.69.251.205 (118.69.251.205)  224.111 ms
 7  118.69.251.249 (118.69.251.249)  156.679 ms  111.965 ms  64.165 ms
 8  cloudflare1-rge.hkix.net (202.40.160.246)  64.102 ms  64.498 ms  74.581 ms
 9  108.162.198.81 (108.162.198.81)  66.873 ms  67.426 ms  69.054 ms

-vs-

traceroute to 108.162.198.181 (108.162.198.181), 64 hops max, 52 byte packets
 1  192.168.1.1 (192.168.1.1)  96.588 ms  3.003 ms  4.976 ms
 2  118.69.255.124 (118.69.255.124)  45.223 ms  31.449 ms  31.225 ms
 3  * * *
 4  * * *
 5  * * *
 6  * * *
 7  * * *
 8  * * *
 9  * * *
10  * * *
...

Source: (StackOverflow)

Find slow network nodes between two data centers

I've got a problem with syncing big amount of data between two data centers. Both machines have got a gigabit connection and are not fully occupied but the fastest that I am able to get is something between 6 and 10 Mbit => not acceptable!

Yesterday I made some traceroute which indicates huge load on a LEVEL3 router but the problem exists for weeks now and the high response time is gone (20ms instead of 300ms).

How can I trace this to find the actual slow node? Thought about a traceroute with bigger packages but will this work?

In addition this problem might not be related to one of our servers as there are much higher transmission rates to other servers or clients. Actually office => server is faster than server <=> server!

Any idea is appreciated ;)

Update
We actually use rsync over ssh to copy the files. As encryption tends to have more bottlenecks I tried a HTTP request but unfortunately it is just as slow.

We have a SLA with one of the data centers. They said they already tried to change the routing because they say this is related to a cheap network where the traffic gets routed through. It is true that it will route through a "cheapnet" but only the other way around. Our direction goes through LEVEL3 and the other way goes through lambdanet (which they said is not a good network). If I got it right (I'm a network intermediate) they simulated a longer path to force routing through LEVEL3 and they announce LEVEL3 in the AS path.

I basically want to know if they're right or they're just trying to abdicate their responsibility. The thing is that the problem exists in both directions (while different routes), so I think it is in the responsibility of our hoster. And honestly, I don't believe that there is a DC2DC connection which only can handle 600kb/s - 1,5 MB/s for weeks! The question is how to detect WHERE this bottleneck is


Source: (StackOverflow)

Is traceroute output correct concerning the actual path to a target

The man page for traceroute says " traceroute tracks the route packets taken from an IP network on their way to a given host." , but while doing research on the topic I was not able to find any statistical data / scientific work on how precise Traceroute actually is as whether the route displayed is the route actually taken (maybe the different packets use completely different routes) and what the error margin is, and whether it would be possible , due to different routing protocols, a Traceroute ping might display a complete different path than a subsequent TCP request or even the actual ping packets would take.

The only work I found, implicating that a Ping tracing might not be perfect is the documentation on scamper which says "ping is useful to measure end-to-end delay and loss, search for responsive IP addresses, and classify the behaviour of hosts by examining how they respond to probes." and (as far as I understood) uses MDA traceroute for path detection. Therefore implying that using PING might not have the desired result.

Therefore my question is: How reliable is path detection using Traceroute (also why)? I'd greatly appreciate links going into details about that topic, but a general explanation why or why not would also suffice.


Source: (StackOverflow)

How do you find out what country a file is hosted?

I'm downloading a file from Adobe which appears to be coming from a local source but im not sure.

Local traffic is free which is why im trying to find out. Download speed seems very slow to be local...

traceroute to 202.124.127.104 (202.124.127.104), 64 hops max, 52 byte packets 
1  citylink-wgtn.actrix.co.nz (203.96.59.1)  2.785 ms  2.601 ms  2.372 ms
2  202.49.152.197 (202.49.152.197)  3.154 ms  2.889 ms  3.134 ms
3  wn-cisco-r2-fa-0-0.connections.net.nz (202.49.152.218)  2.732 ms  2.510 ms  2.876 ms
4  snap.wix.net.nz (202.7.1.240)  3.546 ms  5.025 ms  3.664 ms
5  * * *
6  104.127.124.202.static.snap.net.nz (202.124.127.104)  18.275 ms  18.077 ms  19.211 ms

But what server is hop 5


Source: (StackOverflow)

private address in traceroute results

I SSH into a remote host 194.199.68.165 and then use traceroute to check paths to 132.227.62.122 , and I notice that there are some private IPs, like 10.230.10.1

    bash-4.0# traceroute -T 132.227.62.122
    traceroute to 132.227.62.122 (132.227.62.122), 30 hops max, 60 byte packets 
     1  194.199.68.161 (194.199.68.161)  1.103 ms  1.107 ms  1.097 ms
     2  sw-ptu.univ.run (10.230.10.1)  1.535 ms  1.625 ms  2.172 ms
     3  sw-univ-gazelle.univ.run (10.10.20.1)  6.891 ms  6.937 ms  6.927 ms
     4  10.10.5.6 (10.10.5.6)  1.544 ms  1.517 ms  1.518 ms
     5  194.167.142.22 (194.167.142.22)  2.993 ms  2.985 ms  2.976 ms

why there are private addresses near the host?

what are the purposes that these private addresses are used? I mean why they want to put the public IP behind private IPs?

thanks!


Source: (StackOverflow)