Query physical memory on domain computers using powershell v3.0 -
i have been beating head against can find query simple wmiobject; physicalmemory; however, need @ root level in domain.
since trying @ root level, can suggest weather or not idea (is pinging going issue?). additionally,
1) can query client machine (my laptop w7 x64)? 2) can please provide me easy way query physical memory on domain computer accounts?
to this, need network access machines, permission access wmi , patience. if domain 3 10 machines, should ok. if need more, suggest looking jobs
get-help about_jobs
this short script creates list of computers in domain physical memory in gb
import-module activedirectory $computers = get-adcomputer -filter * | select dnshostname,name,distinguishedname foreach ($computer in $computers){ $w32system = get-wmiobject win32_computersystem -computer $computer.dnshostname $computer | add-member -name "physicalmemory" -value ($w32system.totalphysicalmemory/1gb) -membertype noteproperty } $computers
Comments
Post a Comment