Quantcast
Channel: Exchange Server 2013 - General Discussion forum
Viewing all articles
Browse latest Browse all 4521

Powershell Remote note working correctly

$
0
0

I am running enable-mailbox script from Windows 10 with PSVersion 5.1.14393.3053 and nothing happens.  When I run the same script on Window Server 2012 R2 PSVersion 4.0 it works everytime.

Any idea why Enable-Mailbox is unpredictable?  I try to run powershell as admin on Windows 10 but with same result, nothing happens.

General commands are as follows in the script:

$exchangefqdn = "server1"

$ADuser = (Read-Host "`t1. Please enter the AD username (ex. tempuser)")

$Session = New-PSSession -ConfigurationName Microsoft.Exchange -ConnectionUri http://$exchangefqdn/PowerShell/ -Authentication Kerberos -Credential $exchangecreds -ErrorAction SilentlyContinue -WarningAction SilentlyContinue

Import-PSSession -Session $Session -Prefix AA -DisableNameChecking | out-null

Enable-AAMailbox -Identity $ADuser -WarningAction SilentlyContinue -Confirm:$false -ErrorAction SilentlyContinue | Out-Null


Viewing all articles
Browse latest Browse all 4521

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>