Blog Post

PowerShell – Find OS architecture (32 bit or 64 bit) of local or remote machines Using Powershell

,

Method 1: Environment Variable

PS:\>$ENV:PROCESSOR_ARCHITECTURE

Method 2: Using Win32_OperatingSystem

ps:\>$computername=’abcd’

ps:\>(Get-WmiObject Win32_OperatingSystem -computername $computername).OSArchitecture

 Method 3: Using Win32_Processor

ps:\>$computername=’abcd’

ps:\>Get-WmiObject -Class Win32_Processor -ComputerName $ComputerName| Select-Object AddressWidth

Method 4:[IntPtr]::Size - Gets the size of this instance.  The value of this property is 4 in a 32-bit process, and 8 in a 64-bit process

ps:\>[IntPtr]::Size

 

 

Rate

You rated this post out of 5. Change rating

Share

Share

Rate

You rated this post out of 5. Change rating