Article Contents
Download Scriptomatic and locate the desired metric(s) Scriptomatic is a Microsoft utility that allows you to create scripts that access the WMI counters built into Windows. You can get Scriptomatic from the Microsoft Download Center. The following screenshot shows the main Scriptomatic interface:
After selecting a WMI Namespace and Class, Scriptomatic will automatically generate a script to retrieve the associated values. Review the list of namespaces and classes to locate the metric(s) that you are interested in. Note that you may need to contact Microsoft or your systems vendor to determine where the counters are located (Google also helps). An example of system memory information is provided below:
You can also test the script by clicking the Run button, which will bring up a command line window with the following output:
Once you have a script that successfully retrieves the required values, some changes will be needed to enable it to work with up.time. Allow Remote WMI Requests The initial script should work for the local system but it may not work when retrieving values for your remote servers. The script can be placed on all the remote systems but this complicates the installation and setup process and also presents scaling issues. Making the small modifications described below will allow the script to retrieve metrics from your remote servers with a properly authenticated method. More detailed information can be found in Connecting to WMI on a Remote Computer on the MSDN website. Example script from Scriptomatic: On Error Resume Next The green code in the above example is the WMI Namespace and Class. Replace the namespace and class in the next section with the original values from above. The red text in the above example should be replaced with the following section to enable remote WMI requests (remember to use the original WMI namespace and class from the original code): strComputer = WshSysEnv("UPTIME_HOSTNAME") Since one of the “for loops” was removed, the outer “Next” will also need to be removed at the bottom of the script. Confirm that the script works properly before continuing to the next step. For example: ... Output Format The up.time monitoring station expects to see data in the following format: variable1 value1 Clean up the script by removing the colon (:) from each of the variables that you want to report. For the list of metrics that aren't required, simply delete the lines in the script. For example, change the script from: WScript.Echo "AvailableBytes: " & objItem.AvailableBytes To: WScript.Echo "AvailableBytes " & objItem.AvailableBytes Create and import the monitor UI The monitor interface can be generated with the uptime Plug-In Monitor XML Generator. Please refer to Creating the XML definition for your plug-in service monitor for further assistance. The final monitor can be imported by placing the XML file in the up.time directory and running the following commands on the command line: > cd <uptime_dir> Additional Step for Windows Monitoring Stations If the up.time monitoring station is running on a Windows platform, the following steps will need to be implemented to allow the VB script to run properly. Create a Windows batch file that contains the following command: cscript "C:Program Files uptime softwareuptimescripts Edit the VBS script file created at the end of step 2 and change the following lines from: strComputer = WshSysEnv("UPTIME_HOSTNAME") To: strComputer = Wscript.Arguments.Item(0) Next, edit the 'Script Name' field of the plugin monitor to point to this batch script. For example: "C:\Program Files\uptime software\uptime\scripts\<plugin batch script name>.bat" After this step is completed, the plugin monitor should run the Wwindows batch script, which then runs cscript to execute the VB script. |
Creating Custom Service Monitors with Retained Data Collection | Rating | Views | |
---|---|---|---|
By: uptime Support | Date Created: 5-15-2006 | Last Modified: 12-16-2011 | Index: 067 |
11764 |
Creating Custom Service Monitors in up.time | Rating | Views | |
---|---|---|---|
By: uptime Support | Date Created: 5-15-2006 | Last Modified: 6-26-2013 | Index: 066 |
22874 |
Configuring daily, weekly and monthly monitoring | Rating | Views | |
---|---|---|---|
Use monitoring periods to monitor systems at user-defined intervals. By: uptime Support | Date Created: 12-1-2006 | Last Modified: 8-2-2011 | Index: 104 |
4369 |
Expanding up.time's Capabilities with Plug-in Monitors | Rating | Views | |
---|---|---|---|
Plug-in monitors allow up.time clients to expand their monitoring scope and functionality. This article lists some of the available plug-in monitors. By: uptime Support | Date Created: 9-18-2007 | Last Modified: 8-5-2013 | Index: 218 |
61535 |
Creating Custom Alert Scripts in up.time Alert Profiles | Rating | Views | |
---|---|---|---|
By: uptime Support | Date Created: 5-17-2006 | Last Modified: 8-9-2011 | Index: 065 |
11638 |