I was setting up a laptop to use a script to get into a Powershell CLI and wanted to document what I used to get in.
You'll need to download two items to enable PowerShell:
1) Microsoft Online Services Sign-in Assistant
2) Azure AD Module for Windows PowerShell
from here:
https://technet.microsoft.com/library/dn975125.aspx
You may need to install .net 3.5 from turn windows features on/off.
Then I created a folder on the root C called scripts. In there, I created a file called office365.ps1 with these contents:
---
Import-Module MSOnline
$O365Cred = Get-Credential
$O365Session = New-PSSession –ConfigurationName Microsoft.Exchange -ConnectionUri https://ps.outlook.com/powershell -Credential $O365Cred -Authentication Basic -AllowRedirection
Import-PSSession $O365Session
Connect-MsolService –Credential $O365Cred
---
Then I make edits by opening powershell. Navigate to c:\scripts and run office365.ps1. Of note, you might also need to enable remote execution (Set-ExecutionPolicy RemoteSigned) like this:
From there, I use the commands I described in this post:
http://t-solve.blogspot.com/2013/01/office365-shell-commands-for-reference.html
When I need to run a Powershell script, I open powershell, navigate to c:\scripts, and I run office365.ps1 like this:
Showing posts with label script. Show all posts
Showing posts with label script. Show all posts
Wednesday, November 20, 2013
Saturday, August 28, 2010
script to move Exchange servers in Outlook profiles
I haven't tested this yet, but I found what looks to be a very useful script for adjusting Outlook profiles when you need to alter the Exchange server if the change wasn't made automatically during a typical Exchange mailbox move.
An example is when I did my SBS 2008 migration from SBS 2003. I found that my Outlook profiles did not update automatically. The script from this blog post would have been immensely helpful:
http://davedolan.com/blog/?p=83&cpage=1#comment-121612
An example is when I did my SBS 2008 migration from SBS 2003. I found that my Outlook profiles did not update automatically. The script from this blog post would have been immensely helpful:
http://davedolan.com/blog/?p=83&cpage=1#comment-121612
Subscribe to:
Posts (Atom)