Network Discovery Script

Version 4

    Network discovery is an important feature for small and large scale VMS for monitoring and debugging the network. It is advised to turn on LLDP protocol on all the switches (Mellanox and any other 3rd Party) and in addition to install lldpad tool on your servers, and eventually to enable LLDP in your network.

    There may be several tools in the market that perform discovery based on LLDP. Mellanox supply a simple PERL script to do this job.


    To download the script click here

    The script simply uses the SNMP LLDP-MIB to get the per interface the remote neighbor and print it.


    In the example below there is an output example of the script that supplies per interface the speed and the remote system or server connected plus the remote interface.

    # -l list.txt -wt -V

    - Reading Devices  from file: list.txt

    Discovering topology for the following switches:

    1. r-qa-sit-sx01

    2. r-qa-sit-sx02

    3. r-qa-sit-sx03

    4. r-qa-sit-sx04

    5. r-qa-sit-sx05

    6. r-qa-sit-sx06

    7. r-qa-sit-sx104

    Topology file created 2013-07-04-09_33_51.etopo


            Eth1/1 40000 -> r-qa-sit-sx03 Eth1/2

            Eth1/2 40000 -> r-qa-sit-sx04 Eth1/2


            Eth1/1 40000 -> r-qa-sit-sx05 Eth1/1

            Eth1/10 40000 -> r-qa-sit-sx104 Eth1/1

            Eth1/2 40000 -> r-qa-sit-sx06 Eth1/1

            Eth1/20 40000 -> r-qa-sit-sx01 Eth1/49



            Eth1/1 40000 -> r-qa-sit-sx05 Eth1/2

            Eth1/2 40000 -> r-qa-sit-sx06 Eth1/2

            Eth1/20 40000 -> r-qa-sit-sx02 Eth1/1



            Eth1/1 40000 -> r-qa-sit-sx04 Eth1/20

            Eth1/20 40000 -> reg-r-vrt-002


            Eth1/49 40000 -> r-qa-sit-sx03 Eth1/20

            Eth1/60 40000 -> reg-r-vrt-001


            Eth1/1 40000 -> r-qa-sit-sx03 Eth1/10



            Eth1/1 40000 -> r-qa-sit-sx03 Eth1/1

            Eth1/2 40000 -> r-qa-sit-sx04 Eth1/1