This discussion has been locked.
You can no longer post new replies to this discussion. If you have a question you can start a new discussion

LIST HOSTS IN NETWORK DEFINITIONS TO FIND IP ADDRESS THAT ARE NOT IN USE

Hi experts,

There is some way to list all IPv4 adresses that are NOT in use in a specific network in Sophos UTM (via command line or Web GUI)?

Willing to know.

Thanks.



This thread was automatically locked due to age.
  • Olá Antonio,

    Do you have a Sophos hardware appliance or are you running UTM software on your own computer?  Is the UTM doing DHCP for the computers on your LAN?

    Cheers - Bob

     
    Sophos UTM Community Moderator
    Sophos Certified Architect - UTM
    Sophos Certified Engineer - XG
    Gold Solution Partner since 2005
    MediaSoft, Inc. USA
  • Hi Bob, Yes, I do have Sophos UTM Appliance with firmware v. 9.705-3, It is doing DHCP to the hosts. However ALL hosts are defined to aquire an fixed IP address based in MAC address in the host definition.

  • To list the IPs that have been "seen" by the UTM in the last 7 days:

    /usr/local/bin/count_active_ip.plx --showcount

    If you suspect that there are assigned IPs that haven't been active, and your LAN is 172.20.20.0/24, you can list assigned addresses:

    cc get_objects network host|grep address|grep '172\.20\.20\.'

    Cheers - Bob

     
    Sophos UTM Community Moderator
    Sophos Certified Architect - UTM
    Sophos Certified Engineer - XG
    Gold Solution Partner since 2005
    MediaSoft, Inc. USA
  • cc get_objects network host|grep address|grep '172\.20\.20\.' -> COMMAND NOT FOUND

  • You must execute that as root, Antonio.

    Cheers - Bob

     
    Sophos UTM Community Moderator
    Sophos Certified Architect - UTM
    Sophos Certified Engineer - XG
    Gold Solution Partner since 2005
    MediaSoft, Inc. USA
  • Yes Bob, I know and I did it.

    Can you write here the command to list and export to a TXT file all host with their respective IP address and name? Thanks in advance.

  • List all of the Host names followed by a list of all Host addresses in the same order:

    cd /home; cc get_objects network host|grep \'name\'>hosts.txt ;cc get_objects network host|grep \'address\'>>hosts.txt

    Download from /home using WinSCP and manipulate with a spreadsheet.  A real 'nix guru could probably come up with a better solution.

    In WebAdmin, on the 'Network Definitions' tab, you can select to just see "Hosts" at the top instead of "All" definitions.

    Cheers - Bob

     
    Sophos UTM Community Moderator
    Sophos Certified Architect - UTM
    Sophos Certified Engineer - XG
    Gold Solution Partner since 2005
    MediaSoft, Inc. USA