SlightlyLoony
Tera Contributor
Options
- Subscribe to RSS Feed
- Mark as New
- Mark as Read
- Bookmark
- Subscribe
- Printer Friendly Page
- Report Inappropriate Content
12-15-2008
08:30 AM
If you're managing a bunch of switches and routers, there's a good chance that most of them are made by Cisco. In that case, one of the things you'll likely care about is the IOS version. Out-of-the-box, there's no place in the CMDB to hold the IOS version — but you may have noticed that it's visible in the Short Description field of a switch or router. Here's how you can snag that version information and use it to populate an IOS version field.
Suppose that you want to have an IOS version field for your switches, populated by analyzing the data in the Short Description field to find the version. The steps:
- Create a new field in the IP Switch (cmdb_ci_ip_switch) table. That procedure is documented on the wiki. For my example, I created a field named IOS Version, with a database name of...
Create a business rule on the IP Switch table. If you're not familiar with them, business rules are a powerful and simple tool for you to customize your Service-now instance. This business rule uses a simple regular expression to extract just the version number information from the short description, and then set the value of the IOS version with it. This business rule will run before any insert or update to the IP Switch table, so each time any switch's record is created or changed, the short description will be checked and the IOS version updated.
After running a discovery, go back and look at a switch. Voila! The IOS version number is there, just as we wanted it to be.
This same general procedure can be used to extract all sorts of information out of the short description field. Particularly for any device that Discovery explores with SNMP, there will be potentially useful and interesting information in that field. Often this information is specific to makes and models of equipment (as the IOS version is to Cisco), but that certainly doesn't mean it's not useful!
11 Comments
- « Previous
-
- 1
- 2
- Next »
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.