Thursday, May 24, 2018

Connect Powershell Session - Exchange


Get-ExecutionPolicy

Set-ExecutionPolicy RemoteSigned

Set-ADServerSettings -ViewEntireForest $true

$UserCredential = Get-Credential

$Session = New-PSSession -ConfigurationName Microsoft.Exchange -ConnectionUri http://exchangeserver.domain.com/PowerShell/ -Authentication Kerberos -Credential $UserCredential

Import-PSSession $Session

Get-mailbox -identity Rakesh

No comments:

Post a Comment