Install PowerShell for Exchange on workstation

PowerShell plays a central role in managing Exchange, both for Office 365 and on-premise. Instead of executing commands and scripts on the server console, you can install the Exchange module on a workstation. The on-prem variant requires a little more effort.

Microsoft currently provides version 2 of the module for Exchange Online. The installation there is as follows.

First you have to check the basic authentication for Windows Remote Management (WinRM) via a command prompt with administrative rights and configure it if necessary. To display the current settings, enter this command:

winrm get winrm / config / client / auth

Show current settings for WinRM authentication

By default, the value for basic already on true ring. If this is not the case, you can use it

winrm set winrm / config / client / auth @ {Basic = "true"}

change accordingly. If this setting is not given, the error message appears when you try to connect to Exchange Online

The WinRM client cannot process the request. Basic authentication is currently disabled in the client configuration.

Install module for Exchange Online

The following commands are executed in a PowerShell console with administrative rights.

Install modules PowershellGet -Force

In order to be able to execute scripts, if you have not already done so, you have to relax the execution policy:

Set-ExecutionPolicy RemoteSigned

After this step, you close the PowerShell console and then open it again with elevated rights. Next I install the module ExchangeOnlineManagement:

Install-Module -Name ExchangeOnlineManagement

Install PowerShell module ExchangeOnlineManagement

Now you start with


connect to Office 365 to send commands.

Connect to Exchange Online using the Connect-ExchangeOnline cmdlet

After logging in, the command outputs a small table that shows which cmdlets have changed with the new module.

Install the Exchange Management Shell

In the on-prem version, the whole thing is a bit more complex, since PowerShell for Exchange is part of the management tools. These are on the installation media for Exchange.

First you create the prerequisites by activating some optional features:

Enable-WindowsOptionalFeature -Online -FeatureName IIS-ManagementScriptingTools, IIS-ManagementScriptingTools, IIS-IIS6ManagementCompatibility, IIS-LegacySnapIn, IIS-ManagementConsole, IIS-Metabase, IIS-WebServerManagementTools, IIS-WebServerRole

Enable optional features required by Exchange management tools

In addition, you have to make sure that the correct version of the .NET framework is installed.

Then Microsoft Visual C ++ 2012 Redistributable is required before you can start with the actual installation.

Microsoft Visual C ++ 2012 Redistributable is another prerequisite for the management tools.

The installation of the Exchange Management Tools can now begin with the command:

D: setup / mode: install / role: managementtools / IAcceptExchangeServerLicenseTerms

Run Setup for Exchange to install the management tools

After the setup, you either call the local Exchange PowerShell or the snap-in to administer Exchange with it.

Setup sets up an icon for the Exchange Management Shell in the Start menu.


From time to time, both the Exchange Online module and the management shell for an on-premises Exchange must be updated. In Exchange Online, you enter these commands for this purpose:

Update modules PowershellGet Update modules -Name ExchangeOnlineManagement

With Exchange on Prem, current versions of the cumulative updates come once a quarter.

You May Also Like

About the Author: Jan Gruber

Leave a Reply

Your email address will not be published. Required fields are marked *