Jul 05 2017

Hardware Scanning and Auto Update in GLPI

Published by at 11:06 pm under GLPI

Having loads of physical sites, it is extremely difficult to keep track of device’s locations, and even if you do, you may not be aware some people moved computers or printers around to a new place without telling; It can also be useful to know where a device was last seen.
More importantly, do you know what is on your network? Check how many devices are unknown and not registered in GLPI.


Requirements

– Add network switches in GLPI making sure Name (DNS name), brand, location and type fields are filled in. You need managed switches to connect on to them.

– Generate an SSH key pair on the server from where you are going to run the script, install the public key on the switches so you can log on automatically on each one of them
Supported switches include Cisco Catalyst, HP Procurve* and 3com but could be ported easily to other brands.
Check Cisco, HP and 3com official documentation to install the public key on each device.

– Edit GLPI settings (in the script) and run the bash script
 



Features

– Gets the switch list from GLPI (registered as “switch” in network devices)

– Connects to the switches and gets a list of mac addresses

– If the mac is found in GLPI (within Computer, Printers or Network devices), updates Last modified date and location

– If not, gets the mac’s vendor from Internet. A cache makes it faster if the 6 digits were found before

– Tells percentage of known macs

– tells if duplicates are found in GLPI (mac found on the network matching multiple devices in GLPI)

– Works on Cisco, HP* and 3com switches and could be easily modified for other brands that support SSH auto-connect. Some gears like Cisco Small Business don’t support it.

% gets better as you add more and more known macs in GLPI
You have no idea how many devices connect to the network!

* in combination with rancid

Download for free



No responses yet

Trackback URI | Comments RSS

Leave a Reply