다음을 통해 공유


Query Registry for bulk servers

On Error Resume Next
Set objShell = CreateObject("Wscript.Shell")
Set oFso = CreateObject("Scripting.FileSystemObject")
sDesktop = objShell.SpecialFolders("Desktop")
spath = sDesktop & "\Dclist.txt"
Set oT = oFso.OpenTextFile(spath,1)
Do Until oT.AtEndofStream
temp= oT.ReadLine()
strComputer = Trim(temp)

Const HKEY_CURRENT_USER = &H80000001
Const HKEY_LOCAL_MACHINE = &H80000002

Set oReg=GetObject("winmgmts:{impersonationLevel=impersonate}!\" & _
strComputer & "\root\default:StdRegProv")

strKeyPath = "Hardware\DESCRIPTION\SYSTEM\BIOS\"
strValueName = "SystemManufacturer"
oReg.GetStringValue HKEY_LOCAL_MACHINE,strKeyPath,strValueName,strValue
Wscript.Echo "OS Architecture for" & " " & strComputer & " " & "is: " & strValue
Loop

____________________________________________________________________________________

You can change the bold area as per your requirement. Will update some necessary reg key for Server Inventory.