IT Management Solutions

22 Jun

SolarWinds IP Address Manager module is a great tool to directly manage and monitor with rich visual presentation, the usage of IP addresses in a network. SolarWinds provides multiple options to populate subnet information in our network to IPAM. Subnet information can be added manually, a spreadsheet can be imported, DHCP integration can be used to continually pull directly from DHCP servers and for the more adventurous or needy out there, via the Orion API.

As we can run different SolarWinds modules in a single platform; when we populate our subnets to IPAM and start monitoring IP addresses in our network, that IPAM scope also includes management IP addresses of our nodes that are currently monitored or will be monitored using Network Performance Monitor Server & Application Monitor modules. This is the starting point for our blog post; we can use subnet data in IPAM to enrich node information.

Let’s look at a standard subnet definition in SolarWinds; we must have Subnet Address and CIDR information in our subnet definition but at the same time, we can also customise other fields; description, location, subnet name, etc.

IPAM Detail Properties

These fields can be used to enrich node custom properties and this approach can be automated using “Set Custom Property” action in alerts to update properties for newly populated nodes.

In order to demonstrate that feature, we have defined an alert to populate “Site” custom property of nodes based on “Location” attribute of IPAM subnets.

Requirements:

  • IPAM subnets were defined with “Location” attribute value:

  • Node custom property foCr “Site” was created:

Alert Definition:

We defined a new alert as shown below, it is important to use less frequent evaluation time as we don’t need to check new devices every minute. Severity of the alert should also be selected as “Notice” or “Informational” as we are defining this alert for automation rather than the normal monitoring data analysis.

In “Trigger Condition” tab, we should select “Custom SQL Alert” in order to define SQL condition to correlated IPAM subnet dat with node information:

 

SQL Condition:

INNER JOIN 

                SELECT DISTINCT ipaddress, 
                                subnetid 
                FROM            ipam_node) iplist ON nodes.ip_address=iplist.ipaddress INNER JOIN 

       SELECT groupid      AS subnetid, 
              friendlyname AS subnetname, 
              location 
       FROM   ipam_group 
       WHERE  grouptype=8) subnets ON iplist.subnetid=subnets.subnetid WHERE nodes.site IS NULL

“Reset Condition” and “Time of Day” tabs can be skipped with default settings, as these are not relevant for our function:

 

In “Trigger Action” tab, we should add the “Change Custom Property” action type and we will utilise the advance ability for using a custom SQL query for “Site” custom property value:

Custom Property Value:

${SQL: SELECT     subnets.location 
FROM       nodes 
INNER JOIN 
           ( 
                           SELECT DISTINCT ipaddress, 
                                           subnetid 
                           FROM            ipam_node) iplist 
ON         nodes.ip_address=iplist.ipaddress 
INNER JOIN 
           ( 
                  SELECT groupid      AS subnetid, 
                         friendlyname AS subnetname, 
                         location 
                  FROM   ipam_group 
                  WHERE  grouptype=8) subnets 
ON         iplist.subnetid=subnets.subnetid 
WHERE      nodes.site IS NULL 
AND        nodes.nodeid=$ 
{N=SwisEntity; M=NodeID}}

“Reset Actions” tab can be skipped without adding any action and alert should be saved using “Submit” button on the last “Summary” tab. Once submitted, the alert will do it’s thing, pulling data from IPAM and inserting into the Custom Property data fields where we should see updated “Site” custom property values for nodes.

This is an example of using the Alerting capabilities to update data, which I hope you find useful. Please feel free to download the created Alert definition for importing into you installation. You will need to create the Custom Property structure or update the alert if your ‘site’ field is named differently.

>>>DOWNLOAD EXPORTED ALERT - AUTO POPULATE SITE CUSTOM PROPERTY FROM SOLARWINDS IPAM<<<