12 tips for managing Hyper-V with PowerShell and Windows Admin Center
Table of Contents
- Installing Hyper-V from PowerShell and display cmdlets
- Installing Hyper-V management tools
- Display all available cmdlets
- Use PowerShell Direct
- Run cmdlets from the host on VMs
- Copy files from host to VMs
- Working with PowerShell in Windows Admin Center
- Adjusting Hyper-V settings in the Windows Admin Center
- Enable Switch Embedded Teaming
- Displaying the network adapters for connecting to a virtual switch
- Viewing Virtual Switches Information in PowerShell
- Related links

The virtualization technology Microsoft Hyper-V can be managed with different tools. Microsoft itself offers numerous options for performing all relevant tasks for managing Hyper-V and controlling VMs.
Managing Hyper-V does not always require complex tools such as System Center Virtual Machine Manager, PowerShell offers numerous possibilities without the need for additional tools.
Of course, the Hyper-V Manager is available as a standard tool, and the new Windows Admin Center also offers numerous functions. In the following, we show 12 interesting tips for controlling Hyper-V with the focus on PowerShell.
Installing Hyper-V from PowerShell and display cmdlets
These include the PowerShell module and Hyper-V Manager. If the server is to restart automatically, the parameter -restart is added.
Installing Hyper-V management tools
Display all available cmdlets
Use PowerShell Direct
Enter-PSSession -VMName
Run cmdlets from the host on VMs
Invoke-Command -VMName -ScriptBlock { Commands }
Copy files from host to VMs
$PSSession = New-PSSession -VMName -Credential (Get-Credential)
Copy-Item -ToSession $PSSession -Path C:\data.bar -Destination C:\
Managing Virtual Machines and Virtual Switches with Windows Admin Center
This allows you to manage the VMs and virtual switches on Hyper-V hosts through your web browser. You can additonaly create and edit virtual servers. You can also control VMs in this way, as well as view the console from your web browser.
Working with PowerShell in Windows Admin Center
Adjusting Hyper-V settings in the Windows Admin Center
Enable Switch Embedded Teaming
New-VMSwitch -name SETswitch -Netadaptername „team1“, „team2“, „team3“ -AllowManagementOS $True -EnableEmbeddedTeaming $true
Displaying the network adapters for connecting to a virtual switch
Get-NetAdapter [[-Name] <string[]>] [-IncludeHidden] [-Physical] [-CimSession <cimsession[]>] [-ThrottleLimit ] [-AsJob] []</cimsession[]></string[]>
Viewing Virtual Switches Information in PowerShell
Get-VMSwitch [[-Name] ] [[-ResourcePoolName] <string[]>] [-SwitchType <vmswitchtype[]>] [-CimSession <cimsession[]>] [-ComputerName <string[]>] [-Credential <pscredential[]>] []</pscredential[]></string[]></cimsession[]></vmswitchtype[]></string[]>
For more detailed information about the team, use the Get-VMSwitchTeam cmdlet.
To delete such switches, use the Remove-VMSwitch cmdlet.
Related posts
11 min read
How to connect to Exchange Online with certificate based authentication (CBA)
Jul 25, 2023 by Damian Scoles
About the author:
Thomas Joos is a freelance IT consultant and has been working in IT since 1992. He has published more than 90 practical reference books and writes for numerous IT publications such as c’t, PC Magazin, PC Welt, IT Administrator, Computerwoche and Heise Security.
Latest posts:
- Licensing with Microsoft Graph PowerShell
- ScriptRunner Ultimate Edition 6 – AI‑powered scripting
- How to connect to Exchange Online with certificate based authentication (CBA)
- Get-View in PowerCLI – How to manage your VMware infrastructure more efficiently (part 3)
- Automate snapshots and templates with PowerCLI – Part 2