[mrtg] Re: Problem whit CPU monitoring on windows 2003 and windows 2000 server
Eric Brander
Eric_Mailing_List at rednarb.com
Mon Jan 5 22:07:21 MET 2004
Only works with single processor systems. :(
Eric Brander
Eric_Mailing_List at rednarb dot com
----- Original Message -----
From: "Sutton, Rob" <rsutton at centra.com>
To: <mrtg at list.ee.ethz.ch>
Sent: Monday, January 05, 2004 2:57 PM
Subject: [mrtg] Re: Problem whit CPU monitoring on windows 2003 and
windows 2000 server
I use WMI along with MRTG and VBScripts. Here is the VBScript I use
to call
with MRTG and the MRTG Config file...
VBScript call to WMI:
On Error Resume Next
Set objArgs = WScript.Arguments
strComputer = objArgs.item(0)
Set objWMIService = GetObject("winmgmts:\\" & strComputer &
"\root\cimv2")
Set colItems = objWMIService.ExecQuery("Select * from
Win32_Processor",,48)
For Each objItem in colItems
Wscript.Echo "" & objItem.LoadPercentage
Wscript.Echo "" & objItem.LoadPercentage
Next
MRTG cfg:
Target[SERVERNAME.processorLoad]: `cscript //nologo
D:\mrtg\bin\VB_Scripts\CPULoadSP.vbs SERVER NETBIOS NAME HERE`
I monitor just over 100 Windows 2000 and 2003 server this way. I had
tons of
issues with SNMP and Windows and found this to be the best way to
monitor
Windows servers. WMI RULES! Get Scriptomatic from Microsoft as well.
It's a
free WMI scripting tool. All of the counters you get in Performance
Monitor
are available through WMI. I monitor my MS SQL and IIS Counters
through WMI
as well.
Good Luck!
----->MRTG Knowledge Transfer (MRTGKT.COM) will be back online
shortly<----
--
Unsubscribe mailto:mrtg-request at list.ee.ethz.ch?subject=unsubscribe
Archive http://www.ee.ethz.ch/~slist/mrtg
FAQ http://faq.mrtg.org Homepage http://www.mrtg.org
WebAdmin http://www.ee.ethz.ch/~slist/lsg2.cgi
More information about the mrtg
mailing list