Jump to content
MSFN is made available via donations, subscriptions and advertising revenue. The use of ad-blocking software hurts the site. Please disable ad-blocking software or set an exception for MSFN. ×

Check physical memory or RAM inside WINPE 3.0


vishyc88
 Share

Recommended Posts

Hi Friends,

Is there a way to check RAM/physical memory size from within WINPE? The builtin windows diagnosys tools like systeminfo and wmic are missing. I tried running cpu-z standalone from a network share but fails, saying "Subsystem needed to support the image type is not present.". What i need is a simple standalone command line utility to check RAM size. Kindly help.

Thanks!

Link to comment
Share on other sites


The message you get from CPU-Z is because the architecture for the EXE does not match that of the PE you have built.

Here is one example of how to get it from AutoIT:

$mem = MemGetStats()$pmem = ( Round ($mem[1] / 1024000, 3) & " GB" )MsgBox (4096, "Memory Total", $pmem )
Link to comment
Share on other sites

The message you get from CPU-Z is because the architecture for the EXE does not match that of the PE you have built.

Which can be translated, more or less, into "you built a 64 bit PE without the 32 bit subsystem", right? :unsure:

If this is the case, won't CPU-Z 64 bit version work?

jaclaz

Link to comment
Share on other sites

The message you get from CPU-Z is because the architecture for the EXE does not match that of the PE you have built.

Here is one example of how to get it from AutoIT:

That was lovely Tripredacus. AutoIT solved the problem and your script worked like charm. I'll also attach a script for comprehensive information about your machine.

$objWMIService = objget("winmgmts:{impersonationLevel=impersonate}!\\.\root\cimv2")$colSettings = $objWMIService.ExecQuery("Select * from Win32_OperatingSystem")$colMemory = $objWMIService.ExecQuery("Select * from Win32_ComputerSystem")$colCPU = $objWMIService.ExecQuery("Select * from CIM_Processor")$colVideoinfo = $objWMIService.ExecQuery("Select * from Win32_VideoController")$colSound = $objWMIService.ExecQuery("Select * from Win32_SoundDevice")$colMouse = $objWMIService.ExecQuery("Select * from Win32_PointingDevice")$colMonitor = $objWMIService.ExecQuery("Select * from Win32_DesktopMonitor")$colNIC = $objWMIservice.ExecQuery("Select * from Win32_NetworkAdapter WHERE Netconnectionstatus = 2")Dim $pcinfoFor $object in $colCPU	$PcInfo = $pcinfo & StringStripWS($object.Name,1) & @CRLFNextFor $objOperatingSystem in $colSettings    $PcInfo = $PcInfo & $objOperatingSystem.Caption & " Build " & $objOperatingSystem.BuildNumber & " Servicepack " & $objOperatingSystem.ServicePackMajorVersion & "." & $objOperatingSystem.ServicePackMinorVersion & @CRLF    $PcInfo = $PcInfo & "Available Physical Memory: " & String(Int(Number($objOperatingSystem.FreePhysicalMemory) / 1024)) & " Mb" & @CRLFNextFor $object in $colMemory    $PcInfo = $PcInfo & "Total Physical Memory: " & String(Int(Number($object.TotalPhysicalMemory) / (1024 * 1024))) & " Mb" & @CRLFNext$objFSO = objCreate("Scripting.FileSystemObject")$colDrives = $objFSO.Drives$Opticaldrives = "Opticaldrives : "For $object in $colDrives	If ($object.DriveType == 2) then		$PcInfo = $PcInfo & "Total space on : " & $object.DriveLetter & ":\  (" & $object.VolumeName & ")  = " & String(Round((Number($object.TotalSize) / (1024 * 1024 * 1024)),2)) & " Gb" & @CRLF		$PcInfo = $PcInfo & "Free space on  : " & $object.DriveLetter & ":\  (" & $object.VolumeName & ")  = " & String(Round((Number($object.FreeSpace) / (1024 * 1024 * 1024)),2)) & " Gb" & @CRLF	Else		$Opticaldrives = $Opticaldrives & $object.DriveLetter & ":\ "	EndIfNext$PcInfo = $PcInfo & $Opticaldrives & @CRLFFor $object in $colVideoinfo	$PcInfo = $PcInfo & "Video card: " & $object.Description & @CRLFNextFor $object in $colSound	$PcInfo = $PcInfo & "Sound device: " & $object.Description & @CRLFNextFor $object in $colMouse	$PcInfo = $PcInfo & "Mouse : " & $object.Description & @CRLFNextFor $object in $colMonitor	$PcInfo = $PcInfo & "Monitor : " & $object.Description & @CRLFNextFor $object in $colNIC	$Pcinfo = $pcinfo & $object.name & @CRLFNextClipPut( $pcinfo )MsgBox(48,"PCinfo",$PcInfo)MsgBox( 48, "PCinfo", "Information was copied to clipboard", 5)

Regards,

Vishnu

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

  • Recently Browsing   0 members

    No registered users viewing this page.


×
×
  • Create New...