Missing commands in PowerShell 5.1

Welcome Forums General PowerShell Q&A Missing commands in PowerShell 5.1

This topic contains 3 replies, has 3 voices, and was last updated by

 
Participant
1 year ago.

  • Author
    Posts
  • #89330

    Participant
    Points: 1
    Rank: Member

    I am running PowerShell 5.1 on Server 2008. I'm writing a script where I would like to use Get-Volume and Get-Partition, but neither of these commands are available. I believe these commands were introduced in 3.0. Am I missing something here?

  • #89332

    Keymaster
    Points: 1,704
    Helping HandTeam Member
    Rank: Community Hero

    The commands were not introduced in PowerShell v3; they were introduced in Windows Server 2012. They're part of the OS, not part of the core PowerShell package. They're not available on older operating systems. See https://www.youtube.com/watch?v=mnMHPPhCa7c

  • #89342

    Participant
    Points: 1
    Rank: Member

    Thanks for the clarification Don.

  • #89378

    Participant
    Points: 0
    Rank: Member

    Specifically those cmdlets are based on new CIM (WMI) classes that are in Windows 8 / Server 2012 and later. The CIM classes weren't ported back to older versions of Windows

The topic ‘Missing commands in PowerShell 5.1’ is closed to new replies.