Getting Processor Name and NumberOfCores in PowerShell 2.0

This topic contains 5 replies, has 2 voices, and was last updated by  Olaf Soyk 3 months, 3 weeks ago.

  • Author
    Posts
  • #73754

    Chris Cass
    Participant

    Yes, I know we should upgrade... Unfortunately, I'm auditing a number of client servers that are in production and can't be taken down for the reboot to upgrade PowerShell. I'm trying to display just the name and number of cores for the Processor. I can see them both in the list when I run

    Get-WmiObject Win32_processor

    but when I run

    (Get-WmiObject Win32_processor).Name

    or

    (Get-WmiObject Win32_processor).NumberofCores

    I don't get any results. This works in other versions... What am I doing wrong in 2.0

  • #73759

    Olaf Soyk
    Participant
    Get-WmiObject Win32_processor | Select-Object -Property Name,NumberofCores

    ... client servers that are in production and can't be taken down for the reboot to upgrade PowerShell ...

    How do you install updates / patches??

    • #73762

      Chris Cass
      Participant

      We schedule times with the clients for this... This is for an internal audit that the client has nothing to do with. I just need to gather the information... I have hundreds of servers I need to get through right now and just trying to find a way to gather this info quickly. If they were all on the same network it would be easy and I could just use a test server that has a newer version of PS, but that's not an option right now.

    • #73763

      Olaf Soyk
      Participant

      OK ... did you try the code snippet I posted?

    • #73768

      Chris Cass
      Participant

      I did, and it worked, thank you!

  • #73771

    Olaf Soyk
    Participant
          _
         /(|
        (  :
       __\  \  _____
     (____)  `|
    (____)|   |
     (____).__|
      (___)__.|_____

You must be logged in to reply to this topic.