' Run this script at the command prompt by typing ' cscript disk_queue.vbs Set objArgs = wscript.Arguments strComputer = objArgs.item(0) set oSvc = GetObject("winmgmts:{impersonationLevel=impersonate}!\\" & strComputer & "\root\cimv2") wqlQuery = "select * from Win32_PerfRawData_PerfDisk_PhysicalDisk where Name = '_Total'" for each oData in oSvc.ExecQuery(wqlQuery) for each oProperty in oData.Properties_ if oProperty.Name = "CurrentDiskQueueLength" then intQueue = oProperty.Value end if next next wscript.echo intQueue wscript.echo intQueue wscript.echo Date() & " " & Time() wscript.echo "Total Current Disk Queue Length"