4

How would I remotely check the amount of RAM on a computer using command line? (Windows XP and/or windows server 2003)

Patrick
  • 401
  • 3
  • 5
  • 15

6 Answers6

6

Requires XP or later system: wmic memphysical list full, also wmic memorychip list full might provide you with some info you are looking for.

Tim
  • 3,017
  • 17
  • 15
6

systeminfo /s:hostname will give you some basic memory statics if WMI isn't available on a remote machine:

C:\>systeminfo /s:hostname

...

Total Physical Memory:     3,062 MB
Available Physical Memory: 2,116 MB
Virtual Memory: Max Size:  2,048 MB
Virtual Memory: Available: 1,996 MB
Virtual Memory: In Use:    52 MB
Page File Location(s):     C:\pagefile.sys
  • 1
    does this really work if wmi is non functional on the remote device? – tony roth Jan 11 '12 at 19:47
  • If I stop the Windows Management Instrumentation service on my Windows XP machine I can still run systeminfo against it successfully. Perhaps my test isn't good enough? –  Jan 12 '12 at 02:00
4

To limit it to the Total Physical Memory and Available memory, you may use:

systeminfo /s:hostname | findstr "Physical"
Scott Pack
  • 14,907
  • 10
  • 53
  • 83
Nathan
  • 41
  • 1
2

If you have access to PowerShell (it only needs to be installed on a single workstation to run this from) you can do something like:

$computer = ComputerNameGoesHere
get-wmiobject Win32_ComputerSystem -computer $computer | 
select @{name="TotalPhysicalMemory(MB)";expression={($_.TotalPhysicalMemory/1mb)}}

You would need to either run the script as someone that can run WMI queries on remote machines (usually administrator) or work Get-Credential and -credential in there.

MDMarra
  • 100,734
  • 32
  • 197
  • 329
2

Here's a simple one:

run command line as administrative account (if in a domain)

SYSTEMINFO /S computername

There's all kinds of info including "Total Physical Memory:"

If you need to specify the user:

SYSTEMINFO /S system /U user
MathewC
  • 6,957
  • 9
  • 39
  • 53
1

tasklist /s <system> /u <username> /p <password> for current usage systeminfo /s <system> /u <username> /p <password> for specs on system including ram.

Chad Harrison
  • 6,990
  • 10
  • 29
  • 41