Thursday, November 20, 2014

Ping vs. Traceroute vs Pathping


One of the biggest misconceptions of all time in networking is the use of a traceroute to determine that your communication with a server has high latency. On windows, traceroute is the same command as tracert.
Many people beleive that when they see high latency such as 250ms+ in a single hop of a trace-route that it means that that device in the transit path is responsible for the degraded network performance when in fact it could not be more further from the truth.
First lets look at how ping works.
PING, is an application based on the ICMP protocol which is used to send echo packets to a destination and expecting to receive an echo response and it calculates the RTT (Round Trip Time) from when the packet was sent to when the echo response was received. Generally when using PING on a LAN network you can trust that what it is saying is accurate unless you have foreknowledge of network devices in the transit path that prioritize ICMP over mission critical TCP/UDP Traffic. This however is very common in networks that utilize unified communications, meaning voice and data on the same network. This is because QoS Policies are put in place to ensure voice traffic and other mission critical traffic is prioritized over ICMP thus indirectly affecting the RTT time of an ICMP ping test.
Trace-route is another method commonly used by technicians and engineers to diagnosis latency in the transit path however any engineer that has studied how trace-route works would know that its results are nearly always misleading.
Trace-route works in a manner similar to ping however it uses the TTL feature to make each successive hop in the transit path respond with an ICMP TTL Expired packet. Thus gives you the ability to determine which network devices the ICMP packet is traversing.
When you dig deeper into the operation of traceroute you will see that traceroute utilizes 3 probe packets for each successive hop by default unless you specify other wise. Each probe packet indirectly measures the latency between the source and the device where the TTL is declared expired. This latency calculation is a by product of its true intended purpose. Keep in mind even if you send probes to a device that is five hops away, random latency spikes in any four devices prior to the fifth hop can result in the fifth hop looking like it has high latency.
Also note that any Control Plane Policing policy enforced on any device in the transit path could result in ICMP being prioritized to the control plane of the transit device. ICMP is processed switched by most devices whereas TCP/UDP is express forwarded.
An example below of a traceroute on Windows 7;
C:\>tracert www.google.com -d

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

  1     1 ms    <1 ms    <1 ms  10.100.38.2
  2     1 ms     1 ms    <1 ms  209.51.231.145
  3     5 ms     4 ms     3 ms  64.65.234.204
  4     7 ms     7 ms     7 ms  64.69.98.140
  5    29 ms    29 ms    29 ms  64.69.97.217
  6    30 ms    29 ms    29 ms  64.69.97.219
  7    31 ms    31 ms    32 ms  128.242.186.161
  8    30 ms    30 ms    29 ms  129.250.197.146
  9    30 ms    29 ms    30 ms  209.85.254.120
 10    33 ms    30 ms    30 ms  209.85.240.150
 11    29 ms    30 ms    29 ms  74.125.225.113

Trace complete.

C:\>
You can see from the trace route shown above that there is 3 probes per hop between the source and destination and that it does not appear to have latency until traffic traverses 64.69.97.217
The whole point of this blog is to teach you how to interpret such data. Just because you see a spike in latency on the 5th hop does not mean that the 5th hop is causing latency. It can easily mean that the control plane in the device on the fifth hop is under marginal load and that the processor does not respond to the ICMP immediately due to other processes with priority.
Just because you see potential latency with trace-route, you should never expect that to be an accurate representation of latency for TCP/UDP traffic because ICMP and TCP/UDP traffic is treated completely different when it comes to the routers control/forwarding planes.
Most ISP’s use control-plane policing (CoPP) to prevent overwhelming ICMP flooding to a devices control plane. This type of flood prevention mechanism can also result in skewed data in trace routes.
Shown below is a simple CoPP Policy which can result in skewed trace route data.
!
class-map match-all Catch-All-IP
 match access-group 124
class-map match-all Management
 match access-group 121
class-map match-all Normal
 match access-group 122
class-map match-all Undesirable
 match access-group 123
class-map match-all Routing
 match access-group 120
!
policy-map RTR_CoPP
 class Undesirable
 police 8000 1500 1500 conform-action drop exceed-action drop
 class Routing
 police 1000000 50000 50000 conform-action transmit exceed-action transmit
 class Management
 police 100000 20000 20000 conform-action transmit exceed-action drop
 class Normal
 police 50000 5000 5000 conform-action transmit exceed-action drop
 class Catch-All-IP
 police 50000 5000 5000 conform-action transmit exceed-action drop
 class class-default
 police 8000 1500 1500 conform-action transmit exceed-action transmit
!
access-list 120 permit tcp any gt 1024 10.0.1.0 0.0.0.255 eq bgp
access-list 120 permit tcp any eq bgp 10.0.1.0 0.0.0.255 gt 1024 established
access-list 120 permit tcp any gt 1024 10.0.1.0 0.0.0.255 eq 639
access-list 120 permit tcp any eq 639 10.0.1.0 0.0.0.255 gt 1024 established
access-list 120 permit tcp any 10.0.1.0 0.0.0.255 eq 646
access-list 120 permit udp any 10.0.1.0 0.0.0.255 eq 646
access-list 120 permit ospf any 10.0.1.0 0.0.0.255
access-list 120 permit ospf any host 224.0.0.5
access-list 120 permit ospf any host 224.0.0.6
access-list 120 permit eigrp any 10.0.1.0 0.0.0.255
access-list 120 permit eigrp any host 224.0.0.10
access-list 121 permit tcp 10.0.2.0 0.0.0.255 10.0.1.0 0.0.0.255 eq telnet
access-list 121 permit tcp 10.0.2.0 0.0.0.255 eq telnet 10.0.1.0 0.0.0.255 established
access-list 121 permit tcp 10.0.2.0 0.0.0.255 10.0.1.0 0.0.0.255 eq 22
access-list 121 permit tcp 10.0.2.0 0.0.0.255 eq 22 10.0.1.0 0.0.0.255 established
access-list 121 permit udp 10.0.2.0 0.0.0.255 10.0.1.0 0.0.0.255 eq snmp
access-list 121 permit tcp 10.0.2.0 0.0.0.255 10.0.1.0 0.0.0.255 eq www
access-list 121 permit udp 10.0.2.0 0.0.0.255 10.0.1.0 0.0.0.255 eq 443
access-list 121 permit tcp 10.0.2.0 0.0.0.255 10.0.1.0 0.0.0.255 eq ftp
access-list 121 permit tcp 10.0.2.0 0.0.0.255 10.0.1.0 0.0.0.255 eq ftp-data
access-list 121 permit udp 10.0.2.0 0.0.0.255 10.0.1.0 0.0.0.255 eq syslog
access-list 121 permit udp 10.0.3.0 0.0.0.255 eq domain 10.0.1.0 0.0.0.255
access-list 121 permit udp 10.0.4.0 0.0.0.255 10.0.1.0 0.0.0.255 eq ntp
access-list 122 permit icmp any 10.0.1.0 0.0.0.255 echo
access-list 122 permit icmp any 10.0.1.0 0.0.0.255 echo-reply
access-list 122 permit icmp any 10.0.1.0 0.0.0.255 ttl-exceeded
access-list 122 permit icmp any 10.0.1.0 0.0.0.255 packet-too-big
access-list 122 permit icmp any 10.0.1.0 0.0.0.255 port-unreachable
access-list 122 permit icmp any 10.0.1.0 0.0.0.255 unreachable
access-list 122 permit pim any any
access-list 122 permit udp any any eq pim-auto-rp
access-list 122 permit igmp any any
access-list 122 permit gre any any
access-list 123 permit icmp any any fragments
access-list 123 permit udp any any fragments
access-list 123 permit tcp any any fragments
access-list 123 permit ip any any fragments
access-list 123 permit udp any any eq 1434
access-list 123 permit tcp any any eq 639 rst
access-list 123 permit tcp any any eq bgp rst
access-list 124 permit tcp any any
access-list 124 permit udp any any
access-list 124 permit icmp any any
access-list 124 permit ip any any
!
control-plane
 service-policy input RTR_CoPP
!
If you examine the CoPP policy in detail you will notice that all ICMP destined to the control plane is limited to 50000bps as shown below. It can bust up to 5000bps and if it conforms to the policy it is transmited, if it exceeds the policy the ICMP is dropped.
class Catch-All-IP
 police 50000 5000 5000 conform-action transmit exceed-action drop
With this in mind you should always use trace route for its intended purpose which is to determine the route traffic takes when traversing the transit path and that latency shown on the per hop probe basis is to be taken with at grain of salt when traversing public devices.
The intended purpose of the 3 probe count is to determine if the traffic traverses multiple routed paths due to route engineering, not to determine the latency 3 times.
I will conclude this blog with the pathping command. This command found on windows is a command similar to traceroute but it combines traceroute with ping to give you a better understanding of latency in the transit path.
Pathping works first by doing a traceroute to the destination then it uses ICMP to ping each hop in the transit path 100 times. This is used to verify latency between the source and destination via icmp echo per each hop. But remember what I said earlier, you cannot rely ICMP when public devices are involved. So you can run into cases where you see ICMP pings destined to one hop in the transit drop 40% of the traffic whereas the next hop has 100% success rate. This is due to CoPP.
Pathping in general is a much better tool to diagnosis latency from a specific source to destination with arelative degree of accuracy. Note that I said Relative, this is because latency is ALWAYS relative to your location on the network.
Shown below is an example of pathping in the works;
C:\>pathping www.google.com -n

Tracing route to www.google.com [74.125.225.116]
over a maximum of 30 hops:
  0  10.100.38.162
  1  10.100.38.2
  2  209.51.231.145
  3  64.65.234.204
  4  64.69.98.171
  5  64.69.99.238
  6  165.121.238.178
  7  64.214.141.253
  8  67.16.132.174
  9  72.14.218.13
 10  72.14.238.232
 11  72.14.236.206
 12  216.239.46.215
 13  72.14.237.132
 14  209.85.240.150
 15  74.125.225.116

Computing statistics for 375 seconds...
            Source to Here   This Node/Link
Hop  RTT    Lost/Sent = Pct  Lost/Sent = Pct  Address
  0                                           10.100.38.162
                                0/ 100 =  0%   |
  1    1ms     0/ 100 =  0%     0/ 100 =  0%  10.100.38.2
                                0/ 100 =  0%   |
  2    0ms     0/ 100 =  0%     0/ 100 =  0%  209.51.231.145
                                0/ 100 =  0%   |
  3    4ms     0/ 100 =  0%     0/ 100 =  0%  64.65.234.204
                                0/ 100 =  0%   |
  4    6ms     0/ 100 =  0%     0/ 100 =  0%  64.69.98.171
                                0/ 100 =  0%   |
  5   22ms     0/ 100 =  0%     0/ 100 =  0%  64.69.99.238
                                0/ 100 =  0%   |
  6   10ms     0/ 100 =  0%     0/ 100 =  0%  165.121.238.178
                                0/ 100 =  0%   |
  7   34ms     0/ 100 =  0%     0/ 100 =  0%  64.214.141.253
                                0/ 100 =  0%   |
  8   37ms     0/ 100 =  0%     0/ 100 =  0%  67.16.132.174
                                0/ 100 =  0%   |
  9   35ms     0/ 100 =  0%     0/ 100 =  0%  72.14.218.13
                                0/ 100 =  0%   |
 10  ---     100/ 100 =100%   100/ 100 =100%  72.14.238.232
                                0/ 100 =  0%   |
 11  ---     100/ 100 =100%   100/ 100 =100%  72.14.236.206
                                0/ 100 =  0%   |
 12  ---     100/ 100 =100%   100/ 100 =100%  216.239.46.215
                                0/ 100 =  0%   |
 13  ---     100/ 100 =100%   100/ 100 =100%  72.14.237.132
                                0/ 100 =  0%   |
 14  ---     100/ 100 =100%   100/ 100 =100%  209.85.240.150
                                0/ 100 =  0%   |
 15   36ms     0/ 100 =  0%     0/ 100 =  0%  74.125.225.116

Trace complete.

C:\>
As you can see from the pathping shown above there are some hops in the transit path that completely drop ICMP. You can also notice that the latency to hop 5 is higher then the latency is to hop 6. This shows that either Control Plane Policing is used on 64.69.99.238 or the process utilization on hop 5 is relatively higher.
You should know that there are other tools out there that are extremely useful when trying to diagnosis latency related problems. Most of these tools rely on ICMP and your decision to trust them is based on your understanding the transit path. One of these tools being Ping Plotter. There are several useful tools included in the Solarwinds Engineers Toolset however this toolset is extremely expensive. You can download a trial and check it out at Solarwinds Engineers Toolset
The most accurate tools depend on TCP however since TCP is a connection oriented protocol, both the source and destination must be willing to participate in the testing. Some tools are hardware based such as the Fluke Network EtherScope which cost several thousand dollars.
So in conclusion, your decision to trust and use data from ICMP based troubleshooting should be based on your relative understanding of the transit path. You should never take a traceroute that has high latency on it and say its a network issue just because hope 7 has latency greater then 250ms. This is no different the a doctor telling you your spleen is the result of your headaches without factual basis.
If you do not have clear factual data when diagnosing a problem and you blame the network because of a traceroute, you may very well be completely missing the root cause of the problem. Think of it as getting tunneled vision when sh!t hits the fan and management is expecting answers and the first thing you notice is high latency on a traceroute. With out completely understanding traceroute you may be fixating on an issue that is really not an issue at all.

Friday, September 19, 2014

Learn Engineering and Professional Courses Book Here

i Learners ,

Welcome Learners 

Engineering and Programming Books 
Need any Ebook contact : sobhi89@gmail.com or +91-9467572809 (watsapp only)

For Downloading E-books :
1. Go to Bookforce1
2. Click on Folders
3. Download your Fav File

https://sites.google.com/site/bookforce1/

Saturday, March 30, 2013

How To Make A Bootable Usb For Windows 8

Hope My All Fans Are Fine.Many Person Want To How To Make A Bootable Usb Or Flash Drive,How to Create Bootable Windows 8 USB,How To Create Bootable Windows 7 UsbDrive From Iso Image.This Topic Uploaded Byfullypcgames.blogpsot.com Now I Am Share This Topic WithEasy Method.

Just You Have Need 3 Items.

1)   1st 4gb Flash Drive.... 
2)   Software For Make Bootable Usb... DownloadPassword=fullypcgames.blogspot.com
3)   Download Window 8 Or Window 7 Its Your Choice....Window 7,Window 8

Follow Steps 
1) plug 4gb usb, 4gb minimum Size 
2)Run Software You have already downloaded This 
3)Step 2 click browse and select Iso file and click next.
4)Choose Usb to make bootable usb .
5)Now select usb drive and click begin copying.
6)wait a moment for complete progress.
7)After That Your bootable usb Done !
Enjoy.Post comments Below post And  Share With YourFriends Thanks.

Process Screen Shot!




How can I break the memory card password on my Mobiles

The use of memory cards is increasing day-by-day, flash memory being one of the most crucial. Micro SD Cards</gras> are compact space saving memory devices which can create a headache if their password is lost. This article will discuss the way to find out the memory card's passwordquickly. When the password to a Micro SD Card</gras> gets lost, the card is blocked and none of the information inside it can be accessed. Interfacing your computer and the mobile via Bluetooth can restore and reset the password. Infrared can also be used to regain access to the files. 





This article tells you how to recover a a micro SD card password and micro SD card password reset. 
This document deals with the issue of losing a password for a MICRO SD card. If the password for the card is lost then it will be blocked for further use.www.fullypcgames.blogspot.com In such a situation, the user can interface their mobile with the PC using Bluetooth or Infrared, make the changes then find the password in the file created thereafter. 

Issue

I have lost the password for my 1GB micro SD card and now it is blocked. 

Solutions

Solution one:

  • Go to file manager on your mobile
  • In Settings choose system folders,
  • In the System folder, find a file called mmcstore
  • Send the file to your PC using IR/Bluetooth
  • Open the file in Notepad
  • The password you need for your memory card is located within that file

Solution two:

1. Insert your card into your phone, without accessing it through the phone 

2. Run FExplorer and Open the path C:\system 

3. Find the file called mmcstore, and rename it mmcstore.txt 

4. Copy that file (mmcstore.txt) to your PC and open it in Notepad 

5. Your password will be located within that file. 
6. Download FExplorer
For Micro SD : - 

Put the card in any E series mobile or N95 etc and format it. It will not ask for a password. 

Cisco Discovery Protocol For Windows

UPDATE: Checkout and download my CDP client for Windows over on github

 Lets face it.  We have all been there; "where does this network cable / uplink / port go?"

Until now, it has been a matter of looking up cable numbers in databases, fiddling about in the back of server and network racks or worst case - sending the smallest guy down to play hunchback in the windy air conditioned gloom under the floor.

There must be a better way to tell where a network cable goes to without having to go to all that trouble every time...

Well there is.  It's called Cisco Discovery Protocol (CDP).  From Wikipedia:

The Cisco Discovery Protocol (CDP) is a proprietary Data Link Layer network protocol developed by Cisco Systems that is implemented in most Cisco networking equipment and is used to share information about other directly connected Cisco equipment, such as the operating system version and IP address.

In other words, CDP packets will give you a lot of valuable information if you can capture them. They will give you all the details of the Cisco switch your on and the port on that switch you're connected to.  Of course as CDP is proprietary, you typically won't find it anywhere else other than on Cisco networking kit.

However, VMware knew all about this "trace the cable game" when they where putting together ESX and ESXi v3.5.  VMware's solution was to build in support for CDP on all physical network interfaces of the ESX Hypervisor:
VMware CDP in action

Well, this was a revelation!  For the first time us server techies can check up on the networks techies.  Not only could we tell instantly where a network cable was plugged in, we could tell them if it was in the wrong place too! [bwah ha haaa - rubs hands in a maniacal way!]

Of course this is OK for VMware Hypervisors and Linux based servers / desktops but what about Windows servers / desktops?

Capturing CDP is tough in Windows: CDPR will do it, as will Wireshark, but both require WinPcapto be installed.  This isn't really practical as potentially I want to find CDP data without installing any additional software or rebooting the host (WinPcap requires a reboot).

The Solution - TCPDump
I've found a version of TCPDump for Windows that was built on the WinPCap SDK; this means this little 500k utility can capture CDP packets on a machine without any additional tools.  What's more, as it's shipped as single command line .exe file, it's portable meaning it can be run from a USB stick, a batchfile, etc.  

You can get this updated version of TCPDump from micoOLAP

Using TCPDump
Quite simple, but don't be put off by the plethora of switches.

Firstly you need to find the interface number of the network adaptor you are trying to find CDP data for.  Use this command:

tcpdump -D

This will provide you information similar to this:
TCPDump Listing Interfaces

I'm interested in capturing data from my HP NC7782 Gigabit Adaptor; interface 2.

So lets run the command and capture some CDP data!  Here is the command:

tcpdump -i 2 -nn -v -s 1500 -c 1 ether[20:2] == 0x2000

Breaking this down:
  • -i 2 = interface 2
  • -nn = not resolving dns or port numbers
  • -v = verbose mode
  • -s 1500 = snagging up to 1500 bytes of the CDP packet
  • -c 1 = capture one packet before exiting 
  • ether[20:2] == 0x2000 = checking bytes 20 and 21 from the start of the ethernet header for a value of 2000 (hex)
Phew! I feel a batch file coming on, because I'm never going to remember all of that!

Here is what output looks like:
CDP Data in Windows!

Excellent.

Oh and by the way, tell the apprentice he can come out from under the computer room floor now, we know where these cables go.

*** UPDATE: 4 May 2010 ***
Here is the batch file I use to list adaptors, prompt for adaptor number and then run tcpdump on that adaptor:
@echo off
tcpdump -D
echo.
echo.
echo.
Set /P adaptor=Please Enter Adaptor Number to Listen on: 
tcpdump -i %adaptor% -nn -v -s 1500 -c 1 ether[20:2] == 0x2000
pause

Windows 7: Fix Wireless Trouble

With the proliferation of wireless networks, it is becoming more and more likely that if you live in upwards of a fairly well a populated area, you are going to have problems with your wireless LAN.

Problems that are likely to include random wireless drops, undetectable or uncontactable wireless networks, data throughput problems, etc etc.

The question is - what can be done to try and get to the bottom of these problems?

Perhaps the best place to start is to run a single command line tool to find out as much information as we can about:
  • Wireless adapter model
  • Adapter card driver details
  • Configured wireless LAN profile(s)
  • Full details of wireless networks currently visible
As you can see, quite a lot of information from a single command!

Historically to get this level of information, you would need to look in several places (device manager, wireless networking info) and install 3rd party applications such as NetStumbler etc.

OK, so how do you get all this info from the single command?  Easy peasy.
  1. Click Start (aka Windows Orb) and enter cmd into the text box and hit enter to open a command prompt
  2. Into the command prompt window, enter the command:
  3. netsh wlan show all >wireless.txt
  4. This will run the command and pipe the output of the command into the file wireless.txt for easy reading
  5. Still in the command prompt window, run
  6. notepad wireless.txt
  7. This will open the output from the "netsh wlan show all" command in notepad
With a bit of luck, you should now be looking at something that looks a bit like this: 

=======================================================================
============================== SHOW DRIVERS ===========================
=======================================================================
Interface name: Wireless Network Connection

    Driver                    : Intel(R) PRO/Wireless 2200BG Network Connection
    Vendor                    : Intel Corporation
    Provider                  : Intel
    Date                      : Wed 19/12/2007
    Version                   : 9.0.4.39
    INF file                  : C:\Windows\INF\oem1.inf
    Files                     : 3 total
                                C:\Windows\system32\DRIVERS\w29n51.sys
                                C:\Windows\system32\Netw2c32.dll
                                C:\Windows\system32\Netw2r32.dll
    Type                      : Legacy Wi-Fi Driver
    Radio types supported     : 802.11g 802.11b
    FIPS 140-2 mode supported : No
    Hosted network supported  : No
    Authentication and cipher supported in infrastructure mode:
                                Open            None
                                Open            WEP
                                Shared          None
                                Shared          WEP
                                WPA-Enterprise  TKIP
                                WPA-Enterprise  CCMP
                                WPA-Personal    TKIP
                                WPA-Personal    CCMP
                                WPA2-Enterprise TKIP
                                WPA2-Enterprise CCMP
                                WPA2-Personal   TKIP
                                WPA2-Personal   CCMP
    Authentication and cipher supported in ad-hoc mode:
                                Open            WEP
                                Shared          WEP
                                Open            None
                                Shared          None

======================================================================= 
============================= SHOW INTERFACES ========================= 
=======================================================================
etc etc etc!

Troubleshooting:

Channels in "SHOW NETWORKS MODE=BSSID" section 
Find your wireless LAN and compare this to the channel details of the other wireless networks detailed in the results file.  If your wireless network is using the same channel as someone else's then change your wireless access point or router to use a different wireless channel.   

Signal strength in "SHOW NETWORKS MODE=BSSID" section 
Yes I know the Windows 7 GUI gives you signal strength (and that's about all), but this method is more accurate.  Is the strength any good?  With a higher signal strength, is the wireless connection more stable? 
    These two are the most likely culprits when it comes to unstable wireless connections.

    Some more advance troubleshooting includes: 

    Driver in "SHOW DRIVERS" section
    In my case:
          Driver                    : Intel(R) PRO/Wireless 2200BG Network Connection
          Vendor                    : Intel Corporation
          Provider                  : Intel
          Date                      : Wed 19/12/2007
          Version                   : 9.0.4.39
      Armed with this info, I can hit Intel's website and see if there is a newer version driver available and update.

      Alternatively, I could go to the Windows Update Catalogue and search for MS approved driver updates or hotfixes.  See here for how to use the catalogue.

      Basic Rate and Other Rate in "SHOW NETWORKS MODE=BSSID" section
      Try configuring your wireless card via device manager to run at one of the basic rates listed.  Does this make any difference?  Trial and error to see how fast you can go whilst remaining stable.

      Conclusion
      As we have seen, by running one simple command you can grab all sorts of valuable wireless information and  have a real good stab at fixing wireless networking woes.

      If all else fails, then there is always Ethernet over power!

      Location via Wi-Fi MAC Address


      With all the iPhone tracking claims and counter claims, (seehere for details) it appears that Google have been silently collecting and building a publicly accessible Wireless router location database via their Streetview camera cars and virtually all Android devices.

      And now you too can interrogate that database to find any wireless router in the world!  All you need is the MAC address of the wireless router in question.

      Have a look at http://samy.pl/androidmap/

      When the phone detects any wireless network, encrypted or otherwise, it sends the BSSID (MAC address) of the router along with signal strength, and most importantly, GPS coordinates up to the mothership. This page allows you to ping that database and find exactly where any wi-fi router in the world is located.

      For furter reading on what a MAC address is have a look here


      Finding your Wireless Router's MAC Address
      Following assumes that you are wirelessly connected to the router you wish to find the MAC address of.

      Windows (any current version)
      Open a command prompt and enter the following command:
      ipconfig
      The return should look something like this:
      IP Address. . . . . . . . . . . . : xxx.xxx.xxx.xxx
      Subnet Mask . . . . . . . . . . . : 255.255.255.0
      Default Gateway . . . . . . . . . : yyy.yyy.yyy.yyy
      Taking the default gateway IP address, plumb it into the following command (obviously you will have numbers rather than y's):
       arp -g yyy.yyy.yyy.yyy
      The return should look something like this:
        Internet Address      Physical Address
        yyy.yyy.yyy.yyy       zz-zz-zz-zz-zz-zz
      Copy and paste the physical address (again you should have alphanumerics rather than just z's) into http://samy.pl/androidmap/ and hit probe.

      Linux 
      Open a terminal session and enter the following command:
      route -n
      The return should look something like this: 
      Kernel IP routing table
      Destination     Gateway         Genmask         Flags Metric Ref    Use Iface
      0.0.0.0         yyy.yyy.yyy.yyy    0.0.0.0         UG    0      0        0 wlan0
      Taking the default gateway IP address, plumb it into the following command (again, you will have numbers rather than y's):
       arp -vn yyy.yyy.yyy.yyy
      The return should look something like this:
      Address              HWtype  HWaddress
      yyy.yyy.yyy.yyy      ether   zz:zz:zz:zz:zz:zz
      Copy and paste the HWaddress (again you should have alphanumerics rather than just z's) intohttp://samy.pl/androidmap/ and hit probe.

      ====

      Oh look Google know where you are... again.

      Thanks goto @samykamkar for making android map available.