Skip to content
This repository was archived by the owner on Jun 12, 2023. It is now read-only.
This repository was archived by the owner on Jun 12, 2023. It is now read-only.

Enable-WindowsOptionalFeature does not work with PowerShell 7.2.1 #24

@nbros

Description

@nbros

Steps to reproduce

Open a Windows Terminal as admin with PowerShell 7.2.1, then:

Enable-WindowsOptionalFeature -Online -FeatureName Microsoft-Hyper-V -All

Expected behavior

Hyper-V is enabled

Actual behavior

The command seems to start:

Enable-WindowsOptionalFeature: Microsoft-Hyper-V [Running                                                            ]

But then it freezes indefinitely.
The same command successfully runs in a few seconds with Windows Powershell (5.1.19041.1320).

Environment data

> $PSVersionTable

Name                           Value
----                           -----
PSVersion                      7.2.1
PSEdition                      Core
GitCommitId                    7.2.1
OS                             Microsoft Windows 10.0.19044
Platform                       Win32NT
PSCompatibleVersions           {1.0, 2.0, 3.0, 4.0, 5.0, 5.1.10032.0, 6.0.0, 6.1.0, 6.2.0, 7.0.0, 7.1.0, 7.2.1}
PSRemotingProtocolVersion      2.3
SerializationVersion           1.1.0.1
WSManStackVersion              3.0

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions