Getting all IPs of devices connected to the same router [duplicate]











up vote
4
down vote

favorite
2













This question already has an answer here:




  • Get devices name on the network

    7 answers




I have several linux devices connected to the same router (of which I am not a administrator). How can I find out the ip addresses of all other devices by executing some commands in one of them?










share|improve this question













marked as duplicate by Isaac, RalfFriedl, Thomas, DarkHeart, GAD3R 16 hours ago


This question has been asked before and already has an answer. If those answers do not fully address your question, please ask a new question.















  • related (with links to a lot of duplicate quesions): How can I list all IPs in the connected network, through Terminal preferably?
    – Alexander Malakhov
    Oct 22 '16 at 9:24










  • If this is a router and not a switch, I'm not sure if you can. A router doesn't pass broadcasts by default, and each device might be on a different subnet, so arp/nmap/fing/ping might be useless.
    – Dani_l
    19 hours ago















up vote
4
down vote

favorite
2













This question already has an answer here:




  • Get devices name on the network

    7 answers




I have several linux devices connected to the same router (of which I am not a administrator). How can I find out the ip addresses of all other devices by executing some commands in one of them?










share|improve this question













marked as duplicate by Isaac, RalfFriedl, Thomas, DarkHeart, GAD3R 16 hours ago


This question has been asked before and already has an answer. If those answers do not fully address your question, please ask a new question.















  • related (with links to a lot of duplicate quesions): How can I list all IPs in the connected network, through Terminal preferably?
    – Alexander Malakhov
    Oct 22 '16 at 9:24










  • If this is a router and not a switch, I'm not sure if you can. A router doesn't pass broadcasts by default, and each device might be on a different subnet, so arp/nmap/fing/ping might be useless.
    – Dani_l
    19 hours ago













up vote
4
down vote

favorite
2









up vote
4
down vote

favorite
2






2






This question already has an answer here:




  • Get devices name on the network

    7 answers




I have several linux devices connected to the same router (of which I am not a administrator). How can I find out the ip addresses of all other devices by executing some commands in one of them?










share|improve this question














This question already has an answer here:




  • Get devices name on the network

    7 answers




I have several linux devices connected to the same router (of which I am not a administrator). How can I find out the ip addresses of all other devices by executing some commands in one of them?





This question already has an answer here:




  • Get devices name on the network

    7 answers








networking ip






share|improve this question













share|improve this question











share|improve this question




share|improve this question










asked Oct 22 '14 at 19:08









qed

99141119




99141119




marked as duplicate by Isaac, RalfFriedl, Thomas, DarkHeart, GAD3R 16 hours ago


This question has been asked before and already has an answer. If those answers do not fully address your question, please ask a new question.






marked as duplicate by Isaac, RalfFriedl, Thomas, DarkHeart, GAD3R 16 hours ago


This question has been asked before and already has an answer. If those answers do not fully address your question, please ask a new question.














  • related (with links to a lot of duplicate quesions): How can I list all IPs in the connected network, through Terminal preferably?
    – Alexander Malakhov
    Oct 22 '16 at 9:24










  • If this is a router and not a switch, I'm not sure if you can. A router doesn't pass broadcasts by default, and each device might be on a different subnet, so arp/nmap/fing/ping might be useless.
    – Dani_l
    19 hours ago


















  • related (with links to a lot of duplicate quesions): How can I list all IPs in the connected network, through Terminal preferably?
    – Alexander Malakhov
    Oct 22 '16 at 9:24










  • If this is a router and not a switch, I'm not sure if you can. A router doesn't pass broadcasts by default, and each device might be on a different subnet, so arp/nmap/fing/ping might be useless.
    – Dani_l
    19 hours ago
















related (with links to a lot of duplicate quesions): How can I list all IPs in the connected network, through Terminal preferably?
– Alexander Malakhov
Oct 22 '16 at 9:24




related (with links to a lot of duplicate quesions): How can I list all IPs in the connected network, through Terminal preferably?
– Alexander Malakhov
Oct 22 '16 at 9:24












If this is a router and not a switch, I'm not sure if you can. A router doesn't pass broadcasts by default, and each device might be on a different subnet, so arp/nmap/fing/ping might be useless.
– Dani_l
19 hours ago




If this is a router and not a switch, I'm not sure if you can. A router doesn't pass broadcasts by default, and each device might be on a different subnet, so arp/nmap/fing/ping might be useless.
– Dani_l
19 hours ago










2 Answers
2






active

oldest

votes

















up vote
12
down vote













I believe you could use nmap to get such information.



The below command lists me all the machines/devices connected in my network. It is a home network and it lists me all the machines in my home.



nmap -sP 192.168.1.0/24


I believe you need to modify the subnet mask and IP range that you are in to suit your requirements.






share|improve this answer

















  • 1




    why 192.168.1.0/24? what means?
    – Tarlo_x
    Nov 7 '15 at 13:15






  • 2




    nmap -sA 192.168.1.0/24 nmap option -sA shows similar descriptive results with better readability, which includes device name, IP, mac, etc as with option -sP. I personally prefer -sA over -sP for the readability sake.
    – Jay
    Feb 3 '16 at 10:17












  • @Tarlo_x superuser.com/questions/970380/…
    – Alessandro Jacopson
    Sep 2 at 9:30


















up vote
1
down vote













For a more compact list of connected devices:



nmap -sL 192.168.0.* | grep (1


Explanation
nmap -sL 192.168.0.* will list all IPs in subnetwork and mark those, that have name:



Nmap scan report for 192.168.0.0
Nmap scan report for Dlink-Router.Dlink (192.168.0.1)
Nmap scan report for 192.168.0.2
...
Nmap scan report for android-473e80f183648322.Dlink (192.168.0.53)
...
Nmap scan report for 192.168.0.255


As all interesting records contain parenthesis ( and digit 1, we filter for that with | grep (1 (backslash is needed to escape parenthesis)



Quirk

Beware that if two devices have the same name, nmap will show only the one, that was connected to router last






share|improve this answer






























    2 Answers
    2






    active

    oldest

    votes








    2 Answers
    2






    active

    oldest

    votes









    active

    oldest

    votes






    active

    oldest

    votes








    up vote
    12
    down vote













    I believe you could use nmap to get such information.



    The below command lists me all the machines/devices connected in my network. It is a home network and it lists me all the machines in my home.



    nmap -sP 192.168.1.0/24


    I believe you need to modify the subnet mask and IP range that you are in to suit your requirements.






    share|improve this answer

















    • 1




      why 192.168.1.0/24? what means?
      – Tarlo_x
      Nov 7 '15 at 13:15






    • 2




      nmap -sA 192.168.1.0/24 nmap option -sA shows similar descriptive results with better readability, which includes device name, IP, mac, etc as with option -sP. I personally prefer -sA over -sP for the readability sake.
      – Jay
      Feb 3 '16 at 10:17












    • @Tarlo_x superuser.com/questions/970380/…
      – Alessandro Jacopson
      Sep 2 at 9:30















    up vote
    12
    down vote













    I believe you could use nmap to get such information.



    The below command lists me all the machines/devices connected in my network. It is a home network and it lists me all the machines in my home.



    nmap -sP 192.168.1.0/24


    I believe you need to modify the subnet mask and IP range that you are in to suit your requirements.






    share|improve this answer

















    • 1




      why 192.168.1.0/24? what means?
      – Tarlo_x
      Nov 7 '15 at 13:15






    • 2




      nmap -sA 192.168.1.0/24 nmap option -sA shows similar descriptive results with better readability, which includes device name, IP, mac, etc as with option -sP. I personally prefer -sA over -sP for the readability sake.
      – Jay
      Feb 3 '16 at 10:17












    • @Tarlo_x superuser.com/questions/970380/…
      – Alessandro Jacopson
      Sep 2 at 9:30













    up vote
    12
    down vote










    up vote
    12
    down vote









    I believe you could use nmap to get such information.



    The below command lists me all the machines/devices connected in my network. It is a home network and it lists me all the machines in my home.



    nmap -sP 192.168.1.0/24


    I believe you need to modify the subnet mask and IP range that you are in to suit your requirements.






    share|improve this answer












    I believe you could use nmap to get such information.



    The below command lists me all the machines/devices connected in my network. It is a home network and it lists me all the machines in my home.



    nmap -sP 192.168.1.0/24


    I believe you need to modify the subnet mask and IP range that you are in to suit your requirements.







    share|improve this answer












    share|improve this answer



    share|improve this answer










    answered Oct 22 '14 at 19:18









    Ramesh

    23.1k32101180




    23.1k32101180








    • 1




      why 192.168.1.0/24? what means?
      – Tarlo_x
      Nov 7 '15 at 13:15






    • 2




      nmap -sA 192.168.1.0/24 nmap option -sA shows similar descriptive results with better readability, which includes device name, IP, mac, etc as with option -sP. I personally prefer -sA over -sP for the readability sake.
      – Jay
      Feb 3 '16 at 10:17












    • @Tarlo_x superuser.com/questions/970380/…
      – Alessandro Jacopson
      Sep 2 at 9:30














    • 1




      why 192.168.1.0/24? what means?
      – Tarlo_x
      Nov 7 '15 at 13:15






    • 2




      nmap -sA 192.168.1.0/24 nmap option -sA shows similar descriptive results with better readability, which includes device name, IP, mac, etc as with option -sP. I personally prefer -sA over -sP for the readability sake.
      – Jay
      Feb 3 '16 at 10:17












    • @Tarlo_x superuser.com/questions/970380/…
      – Alessandro Jacopson
      Sep 2 at 9:30








    1




    1




    why 192.168.1.0/24? what means?
    – Tarlo_x
    Nov 7 '15 at 13:15




    why 192.168.1.0/24? what means?
    – Tarlo_x
    Nov 7 '15 at 13:15




    2




    2




    nmap -sA 192.168.1.0/24 nmap option -sA shows similar descriptive results with better readability, which includes device name, IP, mac, etc as with option -sP. I personally prefer -sA over -sP for the readability sake.
    – Jay
    Feb 3 '16 at 10:17






    nmap -sA 192.168.1.0/24 nmap option -sA shows similar descriptive results with better readability, which includes device name, IP, mac, etc as with option -sP. I personally prefer -sA over -sP for the readability sake.
    – Jay
    Feb 3 '16 at 10:17














    @Tarlo_x superuser.com/questions/970380/…
    – Alessandro Jacopson
    Sep 2 at 9:30




    @Tarlo_x superuser.com/questions/970380/…
    – Alessandro Jacopson
    Sep 2 at 9:30












    up vote
    1
    down vote













    For a more compact list of connected devices:



    nmap -sL 192.168.0.* | grep (1


    Explanation
    nmap -sL 192.168.0.* will list all IPs in subnetwork and mark those, that have name:



    Nmap scan report for 192.168.0.0
    Nmap scan report for Dlink-Router.Dlink (192.168.0.1)
    Nmap scan report for 192.168.0.2
    ...
    Nmap scan report for android-473e80f183648322.Dlink (192.168.0.53)
    ...
    Nmap scan report for 192.168.0.255


    As all interesting records contain parenthesis ( and digit 1, we filter for that with | grep (1 (backslash is needed to escape parenthesis)



    Quirk

    Beware that if two devices have the same name, nmap will show only the one, that was connected to router last






    share|improve this answer



























      up vote
      1
      down vote













      For a more compact list of connected devices:



      nmap -sL 192.168.0.* | grep (1


      Explanation
      nmap -sL 192.168.0.* will list all IPs in subnetwork and mark those, that have name:



      Nmap scan report for 192.168.0.0
      Nmap scan report for Dlink-Router.Dlink (192.168.0.1)
      Nmap scan report for 192.168.0.2
      ...
      Nmap scan report for android-473e80f183648322.Dlink (192.168.0.53)
      ...
      Nmap scan report for 192.168.0.255


      As all interesting records contain parenthesis ( and digit 1, we filter for that with | grep (1 (backslash is needed to escape parenthesis)



      Quirk

      Beware that if two devices have the same name, nmap will show only the one, that was connected to router last






      share|improve this answer

























        up vote
        1
        down vote










        up vote
        1
        down vote









        For a more compact list of connected devices:



        nmap -sL 192.168.0.* | grep (1


        Explanation
        nmap -sL 192.168.0.* will list all IPs in subnetwork and mark those, that have name:



        Nmap scan report for 192.168.0.0
        Nmap scan report for Dlink-Router.Dlink (192.168.0.1)
        Nmap scan report for 192.168.0.2
        ...
        Nmap scan report for android-473e80f183648322.Dlink (192.168.0.53)
        ...
        Nmap scan report for 192.168.0.255


        As all interesting records contain parenthesis ( and digit 1, we filter for that with | grep (1 (backslash is needed to escape parenthesis)



        Quirk

        Beware that if two devices have the same name, nmap will show only the one, that was connected to router last






        share|improve this answer














        For a more compact list of connected devices:



        nmap -sL 192.168.0.* | grep (1


        Explanation
        nmap -sL 192.168.0.* will list all IPs in subnetwork and mark those, that have name:



        Nmap scan report for 192.168.0.0
        Nmap scan report for Dlink-Router.Dlink (192.168.0.1)
        Nmap scan report for 192.168.0.2
        ...
        Nmap scan report for android-473e80f183648322.Dlink (192.168.0.53)
        ...
        Nmap scan report for 192.168.0.255


        As all interesting records contain parenthesis ( and digit 1, we filter for that with | grep (1 (backslash is needed to escape parenthesis)



        Quirk

        Beware that if two devices have the same name, nmap will show only the one, that was connected to router last







        share|improve this answer














        share|improve this answer



        share|improve this answer








        edited Oct 21 '16 at 10:05

























        answered Oct 20 '16 at 10:23









        Alexander Malakhov

        11114




        11114















            Popular posts from this blog

            サソリ

            広島県道265号伴広島線

            Setup Asymptote in Texstudio