Blog
By Tommy Gunn on 6/3/2009 5:48:06 AM • Rank (2408) • Views 2671
0

0

Q: Is there an Operations Manager 2007 equivalent of the ResponseTest Resource Kit utility?

A: According to the OpsMgr 2007 SDK, all you need to do is copy the MOMScriptAPI.dll from any management server to your workstation. Then use regsvr32 to register the dll, and you are ready to go! You can then write, run and debug Operations Manager runtime scripts on your XP or Vista workstation - no console required. XML Script output is echoed to the command window on your screen. This allows you to check the data being returned by your script before you go to the work

The problem: However, when I tried this, registering the dll failed with a "Loadlibrary (MOMScriptAPI.dll) failed" error.

The fix: A little work with Process Monitor revealed that the HealthServiceRuntime.dll was being called, but was absent. Simply copying HealthServiceRuntime.dll to the same directory as the MOMScriptAPI.dll and then running regsvr32 MOMScriptAPI.dll again solved the problem.

The real fix is to simply load an OpsMgr agent on the workstation where you will develop your scripts. This will allow logging events to the Operations Manager Event log through the MOMScriptAPI

To Test: Perform the above steps and then run this simple ping script from a command line (which pings localhost). Propertybag data will be returned in your console. Have fun!

Comments - Comment RSS


Who Viewed
Who Reviewed
Categories
Related Pages
Shortened URL
http://tinyurl.com/y9wn3r6

Top Contributors
Featured Members
Pete Zerger
Points: 65502
Level: System Center Expert
Tommy Gunn
Points: 42718
Level: System Center Expert
Simon Skinner
Points: 40744
Level: System Center Expert
Stefan Koell
Points: 28999
Level: System Center Expert
Andreas Zuckerhut
Points: 27584
Level: System Center Expert