Archive

Posts Tagged ‘Network’

How many hosts is running on Local Network ?

July 20, 2011 Leave a comment

Nmap (network mapper) is one of the best network-probing tools to learn in-depth. Be sure to to read the fine manual and practice carefully, because Nmap has mighty snooping powers and can get you in trouble. This command finds all hosts on a LAN subnet:

 $ nmap -sP 192.168.10.0/24 
Starting Nmap 5.00 ( http://nmap.org ) at 2011-07-18 11:01 PDT 
Host freya.alrac.net (192.168.10.105) is up (0.0018s latency). 
Host demeter.alrac.net 192.168.10.107 is up (0.00012s latency). 
Host persephone.alrac.net 192.168.10.109 is up (0.00015s latency). 
Nmap done: 256 IP addresses (3 hosts up) scanned in 27.31 seconds 

That is a simple ping sweep and reverse-DNS resolution that reports hostnames and IP addresses of all hosts on the network that respond to ICMP echo requests. It detects both wired and wireless hosts. On newer versions of nmap this has changed to nmap -sn. You can refine your IP address range using CIDR notation and lists of octets. For example, 192.168.0-5.100-150 scans only the 192.168.0.100-150 up to 192.168.5.100-150 address ranges. You can enter your specific address ranges in a text file, separated by spaces, tabs, or newlines, and call this file with the -iL filename option.

 Ref: http://www.linux.com/learn/tutorials/470979-who-and-what-is-on-my-network-probing-your-network-with-linux 
Tags: ,