Re: Need to collect information about USB ports and connected devices
- From: Mark Withers <BSDjunkie@xxxxxxxxxxxxx>
- Date: Sun, 12 Nov 2006 13:38:30 -0600
I have found the information in WMI, but not in any of the areas
specified below as they only reflect the actual usb controller
information.
It seems that there is an object called Win32_PnPEntity whch actually
has the data, but I am not sure how to define that in a .MOF file yet.
I am confused as to what Provider to use for the data class.
If anyone can help me with the rest of this mystery, I'd sure appreciate
it!!!
Here's what I have in a VBScript:
strComputer = "."
Set objWMIService = GetObject("winmgmts:\\" & strComputer &
"\root\cimv2")
Set colDevices = objWMIService.ExecQuery _
("Select * From Win32_USBControllerDevice")
For Each objDevice in colDevices
strDeviceName = objDevice.Dependent
strQuotes = Chr(34)
strDeviceName = Replace(strDeviceName, strQuotes, "")
arrDeviceNames = Split(strDeviceName, "=")
strDeviceName = arrDeviceNames(1)
Set colUSBDevices = objWMIService.ExecQuery _
("Select * From Win32_PnPEntity Where DeviceID = '" &
strDeviceName & "'")
For Each objUSBDevice in colUSBDevices
Wscript.Echo objUSBDevice.Description
Wscript.Echo objUSBDevice.DeviceID
'Wscript.Echo objUSBDevice.Manufacturer
Next
Next
Mark
On 2006-03-31, garth <someone@xxxxxx> wrote:
The short answer is if the info is within WMI then you can collect the info.
with SMS.
I did a quick look and there are three USB WMI class. Does any of these
provide you with the info that you are lookign for?
http://msdn.microsoft.com/library/default.asp?url=/library/en-us/wmisdk/wmi/win32_usbcontroller.asp
http://msdn.microsoft.com/library/default.asp?url=/library/en-us/wmisdk/wmi/win32_usbcontrollerdevice.asp
http://msdn.microsoft.com/library/default.asp?url=/library/en-us/wmisdk/wmi/win32_usbhub.asp
"Taxviper" <Taxviper@xxxxxxxxxxxxxxxxxxxxxxxxx> wrote in message
news:EE5A859A-BEB5-4E7A-88B2-6138A824DAB5@xxxxxxxxxxxxxxxx
Hi,
I would like to ask if it's possible to get the SMS-server to collect
information about all the clients USB ports and the connected devices?
I need this information to analyze the use of USB-devices.
If it's possible, could what will this information show - the name of the
device, only connected devices or last connected device and how do I
compose
the search options?
Thanks,
Michael
- Prev by Date: Re: Files inventory
- Next by Date: Re: How many software metering rules equals "Excessive" ?
- Previous by thread: Files inventory
- Next by thread: Re: How many software metering rules equals "Excessive" ?
- Index(es):
Relevant Pages
|