header1   header
header
header Register : : Login header
header
connector   connector
menuleft menuright
submenu   submenu
left
Win32_Processor Xeon
Last Post 01 Aug 2010 10:10 AM by JKav. 9 Replies.
Printer Friendly
  •  
  •  
  •  
  •  
  •  
Sort:
PrevPrev NextNext
You are not authorized to post a reply.
Author Messages
JKavUser is Offline
New Member
New Member
Posts:70
Avatar

--
27 Jul 2010 07:59 AM
    I was tasked with writing a script to produce a report for a Windows 2008 upgrade project.  Pretty simple, query all servers not running windows server 2008 and  then get some basic information.  While the report worked well, there is a major flaw in  my data gathering.  One of the items of information was wheter the server had 64bit processor(s).  Now the flaw seems specific to a certain manufacturer (IBM  Blades) but in general the data couldn't be trusted. Using gwmi win32_processor I looked at Architecture which returns 0 for x86, DataWidth returns 32, Family returns 2.  I know the processor I am looking at is a Xeon 5160 which supports 64bit via  IA64  (which is why it might not read x64  architecture).  The server I am testing against is running Windows Server 2003 SP2, and I  even tried to run WMIC locally on the server to see if the results would be different.  Then the SCCM admin overheard me discussing the data and produced a report that indicated the servers (and more specifically my test case) had a 64bit processor. 

    This might not be powershell related at all, but I have seen many inventory scripts and wondering if anyone else has seen this and if there might be an alternative logic (i.e. if win32_Processor.name -like "*Xeon*5160*"){"This is a 64bit processor box"} but that  could lead to a lengthy reference loop for processor  names.  I know SP2  fixed the data returned my win32_processor.family but SP2 is installed.

    Thanks
    JKavUser is Offline
    New Member
    New Member
    Posts:70
    Avatar

    --
    27 Jul 2010 08:22 AM
    and just FYI, below is the data I get with gwmi win32_processor | select *



    __GENUS : 2
    __CLASS : Win32_Processor
    __SUPERCLASS : CIM_Processor
    __DYNASTY : CIM_ManagedSystemElement
    __RELPATH : Win32_Processor.DeviceID="CPU0"
    __PROPERTY_COUNT : 44
    __DERIVATION : {CIM_Processor, CIM_LogicalDevice, CIM_LogicalElement, CIM_ManagedSystemElement}
    __SERVER : COR02DW01
    __NAMESPACE : root\cimv2
    __PATH : \\server\root\cimv2:Win32_Processor.DeviceID="CPU0"
    AddressWidth : 32
    Architecture : 0
    Availability : 3
    Caption : x86 Family 6 Model 15 Stepping 6
    ConfigManagerErrorCode :
    ConfigManagerUserConfig :
    CpuStatus : 1
    CreationClassName : Win32_Processor
    CurrentClockSpeed : 2992
    CurrentVoltage : 12
    DataWidth : 32
    Description : x86 Family 6 Model 15 Stepping 6
    DeviceID : CPU0
    ErrorCleared :
    ErrorDescription :
    ExtClock : 266
    Family : 2
    InstallDate :
    L2CacheSize : 4096
    L2CacheSpeed :
    LastErrorCode :
    Level : 6
    LoadPercentage : 1
    Manufacturer : GenuineIntel
    MaxClockSpeed : 2992
    Name : Intel(R) Xeon(R) CPU 5160 @ 3.00GHz
    OtherFamilyDescription :
    PNPDeviceID :
    PowerManagementCapabilities :
    PowerManagementSupported : False
    ProcessorId : 00000301000006F6
    ProcessorType : 3
    Revision : 3846
    Role : CPU
    SocketDesignation : CPU 1
    Status : OK
    StatusInfo : 3
    Stepping : 6
    SystemCreationClassName : Win32_ComputerSystem
    SystemName : server
    UniqueId :
    UpgradeMethod : 4
    Version : Model 15, Stepping 6
    VoltageCaps :
    Scope : System.Management.ManagementScope
    Path : \\server\root\cimv2:Win32_Processor.DeviceID="CPU0"
    Options : System.Management.ObjectGetOptions
    ClassPath : \\server\root\cimv2:Win32_Processor
    Properties : {AddressWidth, Architecture, Availability, Caption...}
    SystemProperties : {__GENUS, __CLASS, __SUPERCLASS, __DYNASTY...}
    Qualifiers : {dynamic, Locale, provider, UUID}
    Site :
    Container :

    __GENUS : 2
    __CLASS : Win32_Processor
    __SUPERCLASS : CIM_Processor
    __DYNASTY : CIM_ManagedSystemElement
    __RELPATH : Win32_Processor.DeviceID="CPU1"
    __PROPERTY_COUNT : 44
    __DERIVATION : {CIM_Processor, CIM_LogicalDevice, CIM_LogicalElement, CIM_ManagedSystemElement}
    __SERVER : COR02DW01
    __NAMESPACE : root\cimv2
    __PATH : \\server\root\cimv2:Win32_Processor.DeviceID="CPU1"
    AddressWidth : 32
    Architecture : 0
    Availability : 3
    Caption : x86 Family 6 Model 15 Stepping 6
    ConfigManagerErrorCode :
    ConfigManagerUserConfig :
    CpuStatus : 0
    CreationClassName : Win32_Processor
    CurrentClockSpeed : 2992
    CurrentVoltage : 12
    DataWidth : 32
    Description : x86 Family 6 Model 15 Stepping 6
    DeviceID : CPU1
    ErrorCleared :
    ErrorDescription :
    ExtClock : 266
    Family : 2
    InstallDate :
    L2CacheSize : 0
    L2CacheSpeed :
    LastErrorCode :
    Level : 6
    LoadPercentage : 1
    Manufacturer : GenuineIntel
    MaxClockSpeed : 2992
    Name : Intel(R) Xeon(R) CPU 5160 @ 3.00GHz
    OtherFamilyDescription :
    PNPDeviceID :
    PowerManagementCapabilities :
    PowerManagementSupported : False
    ProcessorId : 0000000000000000
    ProcessorType : 2
    Revision : 3846
    Role : CPU
    SocketDesignation : CPU 2
    Status : OK
    StatusInfo : 3
    Stepping : 6
    SystemCreationClassName : Win32_ComputerSystem
    SystemName : server
    UniqueId :
    UpgradeMethod : 4
    Version : Model 15, Stepping 6
    VoltageCaps :
    Scope : System.Management.ManagementScope
    Path : \\server\root\cimv2:Win32_Processor.DeviceID="CPU1"
    Options : System.Management.ObjectGetOptions
    ClassPath : \\server\root\cimv2:Win32_Processor
    Properties : {AddressWidth, Architecture, Availability, Caption...}
    SystemProperties : {__GENUS, __CLASS, __SUPERCLASS, __DYNASTY...}
    Qualifiers : {dynamic, Locale, provider, UUID}
    Site :
    Container :




    PoSherLifeUser is Offline
    Basic Member
    Basic Member
    Posts:364
    Avatar

    --
    27 Jul 2010 08:43 AM
    One thing worthy to note is that just because the processor is capable of 64-bit processing doesn't mean the motherboard/bios is. Depending on the BIOS settings x64 could be turned off or a bios update may be needed to ready the CPU correctly. If the mobo is not configured to allow x64, then WMI will not show the CPU as being x64 capable.
    When at first you don't succeed Step-Into

    http://theposherlife.blogspot.com
    http://www.jandctravels.com

    JKavUser is Offline
    New Member
    New Member
    Posts:70
    Avatar

    --
    27 Jul 2010 08:45 AM
    I agree this could be something in BIOS/firmware, but when SCCM reported different results I had to be missing something.
    George HowarthUser is Offline
    Basic Member
    Basic Member
    Posts:360
    Avatar

    --
    27 Jul 2010 11:08 AM
    What does this give you?

    [Environment]::GetEnvironmentVariable("PROCESSOR_ARCHITECTURE",  [EnvironmentVariableTarget]::Machine)
    JKavUser is Offline
    New Member
    New Member
    Posts:70
    Avatar

    --
    27 Jul 2010 12:33 PM

    Since we do not have remoting enabled and/or Powershell is not installed on the remote computers I am not sure how well using environment variables will work but gives me some ideas.

    JKavUser is Offline
    New Member
    New Member
    Posts:70
    Avatar

    --
    28 Jul 2010 10:37 AM
    Posted By GWHowarth88 on 27 Jul 2010 11:08 AM
    What does this give you?

    [Environment]::GetEnvironmentVariable("PROCESSOR_ARCHITECTURE",  [EnvironmentVariableTarget]::Machine)

    I checked the registry "...Session Manager\Environment" ARCHITECURE_PROCESSOR and it too is showing x86.
    JKavUser is Offline
    New Member
    New Member
    Posts:70
    Avatar

    --
    28 Jul 2010 10:38 AM
    Posted By GWHowarth88 on 27 Jul 2010 11:08 AM
    What does this give you?

    [Environment]::GetEnvironmentVariable("PROCESSOR_ARCHITECTURE",  [EnvironmentVariableTarget]::Machine)


    0ptikGhostUser is Offline
    Basic Member
    Basic Member
    Posts:296
    Avatar

    --
    01 Aug 2010 10:08 AM
    Posted By jkavanagh58 on 28 Jul 2010 10:37 AM
    Posted By GWHowarth88 on 27 Jul 2010 11:08 AM
    What does this give you?

    [Environment]::GetEnvironmentVariable("PROCESSOR_ARCHITECTURE",  [EnvironmentVariableTarget]::Machine)

    I checked the registry "...Session Manager\Environment" ARCHITECURE_PROCESSOR and it too is showing x86.


    This makes sense as the OS running on the CPU is 32-bit. It will never know that the CPU underneath it is 64-bit.

    You are trying to reimplement SCCM's algorithm for detecting CPU architectures. You should start your search there. Clearly they are using some heuristic to fix up the data they are getting. Perhaps it is table driven... *shrug*
    JKavUser is Offline
    New Member
    New Member
    Posts:70
    Avatar

    --
    01 Aug 2010 10:10 AM
    Posted By 0ptikGhost on 01 Aug 2010 10:08 AM
    Posted By jkavanagh58 on 28 Jul 2010 10:37 AM
    Posted By GWHowarth88 on 27 Jul 2010 11:08 AM
    What does this give you?

    [Environment]::GetEnvironmentVariable("PROCESSOR_ARCHITECTURE",  [EnvironmentVariableTarget]::Machine)

    I checked the registry "...Session Manager\Environment" ARCHITECURE_PROCESSOR and it too is showing x86.


    This makes sense as the OS running on the CPU is 32-bit. It will never know that the CPU underneath it is 64-bit.

    You are trying to reimplement SCCM's algorithm for detecting CPU architectures. You should start your search there. Clearly they are using some heuristic to fix up the data they are getting. Perhaps it is table driven... *shrug*


    Well I don't have access to SCCM and was not aware it had the data.  I was just tasked to provide a list of hardware so I set out using WMI.  Once the SCCM report was provided the script was obviously scrapped but I am just curious how SCCM ascertained the data because it seems a little important.
    You are not authorized to post a reply.


    Active Forums 4.3
    right
    footer   footer
    footer Sponsored by Quest Software • SAPIEN Technologies • Compellent • Microsoft Windows Server 2008 R2 footer
    footer   footer