Results 1 to 6 of 6

Thread: List used IP numbers in the LAN

  1. #1
    Join Date
    Oct 2006
    Location
    Sacramento, California
    Beans
    529
    Distro
    Ubuntu 12.04 Precise Pangolin

    List used IP numbers in the LAN

    How can I list used IP number in my LAN via terminal?

  2. #2
    Join Date
    Aug 2005
    Location
    South Carolina, USA
    Beans
    26,043
    Distro
    Ubuntu Development Release

    Re: List used IP numbers in the LAN

    Try this:
    Code:
    fping -g 192.168.1.100 192.168.1.150
    Substitute your IP range as needed. The command:
    Code:
    ifconfig
    will tell you whether your range is 192.168.0.x or 192.168.1.x. You will get something like this:
    chili@LAPTOP40:~$ fping -g 192.168.1.100 192.168.1.150
    192.168.1.100 is alive
    192.168.1.101 is alive
    192.168.1.105 is alive
    192.168.1.108 is alive
    192.168.1.116 is alive
    192.168.1.118 is alive
    192.168.1.121 is alive

  3. #3
    Join Date
    Mar 2006
    Location
    Williams Lake
    Beans
    Hidden!
    Distro
    Ubuntu Development Release

    Re: List used IP numbers in the LAN

    I created a script with this line it it to to check which computers were up on the network:

    Code:
    sudo nmap -PR -sP 192.168.1.0/24j
    Jim

  4. #4
    Join Date
    Oct 2006
    Location
    Sacramento, California
    Beans
    529
    Distro
    Ubuntu 12.04 Precise Pangolin

    Re: List used IP numbers in the LAN

    Thanks for your responses.

    fping creates an infinite loop. Once all ip numbers in that subnet is checked, it is checked again. It would be nice if it could stop after one round, and only output the active addresses.

    nmap does what I wanted it to, as in only outputting used addresses. However, only a fraction of used addresses are detected (running it as root as suggested fixes this, though I don't understand why). Furthermore, what I wish it could do is listing the hostname. Right now, only a few computers are listed with their host name. However, the NIC vendor is listed, which is pretty neat.
    Last edited by MockY; February 26th, 2009 at 01:33 AM.

  5. #5
    Join Date
    Sep 2009
    Beans
    3

    Re: List used IP numbers in the LAN

    I think fping is a good solution :

    install :
    sudo apt-get install fping

    then use it :
    fping -a -g 192.168.1.0/24 2> /dev/null
    192.168.1.10
    192.168.1.20


    source :
    http://kriom.blogspot.fr/2013/01/how...y-respond.html

  6. #6
    Join Date
    Jan 2006
    Location
    Not heaven... Iowa
    Beans
    Hidden!
    Distro
    Ubuntu

    Re: List used IP numbers in the LAN

    Closed - old thread.
    Linux User #415691 Ubuntu User #8629
    Iowa Team (LoCo): [Wiki] [Launchpad]
    IRC channel: #ubuntu-us-ia on irc.freenode.net

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •