Home
  • RapidOSS
  • Support
  • About Us
Home » Blogs » iFountain's blog

Smarts Dynamic Model: Lets Start Simple

Posted October 18th, 2006 by iFountain
in
  • EMC Smarts
  • How to
  • Integration
  • ITManagementTools
  • RapidConnector

As mentioned on the previous post, Smarts dynamic model is a powerful functionality added to Smarts. It allows extend the ICIM model in the field using the MODEL language. To be sure, adding sophisticated capabilties requires mastering the MODEL language and available information (documentation, example code, etc.) is scarce, yet there are many uses of dynamic model that does not require in depth knowledge. In a series of posts, I'll give some examples to demonstrate these simple uses.

Adding new properties to existing classes
The simples use of dynamic model is adding attributes to existing classes. This is as straight forward as it gets, yet can be quite useful. For example, we can extend the UnitaryComputerSystem (Hosts, Routers, Switches, etc.) to add business related information. Let's assume we want to store SLALevel, AssetNumber, and CustomerName as properties for each device on our network. We may later want to use these properties for number of reasons such as filtering or prioritizing notifications, etc. First we need to create an .mdl file where we define the new properties. It would be something like this (i.e. deviceinfo.mdl) :

refine interface UnitaryComputerSystem
{
stored attribute string CustomerName
"The name of the customer"
= "";

stored attribute string AssetNumber
"The asset number used to identify the device in the asset management system"
= "";

stored attribute string SLALevel
"The Service Level associated with the device"
= "";
}

Simple, no?

refine keyword specifies that we are modifying an existing class. interface means class in the MODEL language. Then we define new properties with their types and specify a default value. That's it for the definition.
Next, compile the code using the dynmodel executable. Compilation creates a .ldm file (i.e. deviceinfo.ldm). Copy the files into the smarts/local/model directory. We are done with the development of the model, now we need to do couple of things to prepare the Smarts servers:

  • Good news is that dynamic model feature is available for free from EMC/Smarts (more precisely, it's available for $0) . Bad news is that it requires a separate license. You need to get a new license that includes dynamic model support from your EMC contacts.
  • a new parameter "--dynamic" needs to be added to the server startup commands.
  • restart the Smarts servers

The new properties are exactly same as other properties for all intends and purposes. You can see the new properties from the Smarts Global Console, dmctl utility. You can set their values etc. from asl/perl script, dmctl,, java API, etc.

<Product pitch>
Another option available is our RapidConnector product which allows working with Smarts servers without requiring indepth knowledge of the APIs. Let's assume the data we want is available in a relational database, such as asset management database. Populating and keeping these properties synchronized would be straight forward. We can configure a RapidConnector adapter through the graphical development tool. RapidConnector provides ready to use components, we need the database reader component to read the data from the database, assignment component to manipulate the data and topology writer component to update the Smarts server(s).

Database reader executes the SQL query we specify, and creates variables we can use using the field names. We can then define an action to update the properties in Smarts.

In short, you can add new properties to your devices and store additional information (from files, database,etc.) in couple of hours.

</Product pitch>

In the next post, we'll see how we can extend ICIM model to monitor applications (a database) using dynamic model together with RapidWatcher.

  • Login or register to post comments

 Social Bookmark

  • Smarts Dynamic Model: RapidConnector to the rescue!
  • Event management patterns: Information at your finger tips :)
  • Smarts Dynamic Model: Is it the application or the host that is down?
  • Smarts Dynamic Model: Instrumentation voodoo
  • Smarts Dynamic Model: Let's monitor applications

  • Create new account
  • Request new password