Using PowerShell Magic to Manage Microsoft Office 365
Ben Fletcher
Mark Rhodes
OSP317
To kick things off.....a race!
The Challenge:

A “Real World” provisioning situation
Why PowerShell?
It just helps you to be more productive
You will also need it to implement Office 365 components like ADFS
Integrated Scripting Environment
Don’t use the traditional PowerShell windows, use ISE!
Windows Azure AD
PowerShell for Windows Azure AD
Basic operations for management of the Office 365 tenant, user management
Basic User Operations
Mark Rhodes
What have you just seen?
$msolcred = get-credential 
connect-msolservice -credential $msolcred

New-MsolUser

Set-MsolUserPassword
Basic Group Operations
Mark Rhodes
What have you just seen?
Get-MsolGroup

New-MsolGroup

Add-MsolGroupMember
Role Operations
Mark Rhodes
What have you just seen?
Get-MsolRole

Get-MsolRoleMember 

Add-MsolRoleMember
Managing Subscriptions
Mark Rhodes
What have you just seen?
Get-MsolSubscription 

Get-MsolAccountSku 

New-MsolLicenseOptions

Set-MsolUserLicense
Let’s get advanced
Mark Rhodes
What you have seen
Batch Import users from CSV
http://gallery.technet.microsoft.com/office/Bulk-import-the-user-568abc5f
How to use PowerShell to Automatically Assign Licenses to your Office365 Users
http://social.technet.microsoft.com/wiki/contents/articles/15905.how-to-use-powershell-to-automatically-assign-licenses-to-your-office365-users.aspx
Exchange Online
PowerShell for Exchange Online
Very rich and PowerFull set of commands
Almost all operations which are available for Exchange on premise are available for Exchange Online
Overview of all cmdlts: http://technet.microsoft.com/en-us/library/bb124413(v=exchg.150).aspx
Connecting to the service
Ben Fletcher
What have you just seen?
$Cred = Get-Credential
$Session = New-PSSession -ConfigurationName Microsoft.Exchange -ConnectionUri https://ps.outlook.com/powershell/ -Credential $Cred -Authentication Basic -AllowRedirection 
Import-PSSession $Session
Working with users
Ben Fletcher
What have you just seen?
Get-User -Filter "Department -eq 'Customer Service'" | Set-Mailbox -MaxSendSize 2097152 

Set-UserPhoto "MOD Administrator" -PictureData ([System.IO.File]::ReadAllBytes("C:\SAMOptimizationKit\marlies.jpg"))
Managing a security group
Ben Fletcher
What have you just seen?
Get-Group

new-distributiongroup -name "[Group's Name]" -alias "[Group's Alias]" -type "security" -primarysmtpaddress "[your_address@your_domain]“

get-distributiongroup -identity [Group's Name or Email Address] | format-list
Let’s get more advanced
Ben Fletcher
What have you just seen?
Convert User to a Shared Mailbox http://blogs.technet.com/b/kpalmvig/archive/2013/02/28/office-365-convert-user-mailbox-to-shared-mailbox.aspx
Setting up a Shared Mailbox
http://blogs.msdn.com/b/microsoft_cloud/archive/2011/11/18/set-up-shared-mailboxes-in-office-365.aspx
Export list of Exchange Permissions
http://gallery.technet.microsoft.com/scriptcenter/Export-mailbox-permissions-d12a1d28
SharePoint Online
PowerShell and SPO
About 30 cmdlts available (compared to hundreds in SharePoint On Premise)
NoWait parameter added
Basic operations
Mark Rhodes
What have you just seen?
Connect-SPOService

Get-SPOSite

Get-SPOWebTemplate
New-SPOSite

New-SPOSiteGroup

Add-SPOUser
More advanced operations
Mark Rhodes
Lync Online
Overview
Just released!
Only needed for specific scenario’s (Lync Room System, split domain, mass-operations)
Some settings are PowerShell only
Lync Operations
Ben Fletcher
What have you just seen?

$session = New-CsOnlineSession -Credential $cred
import-PSsession $session -AllowClobber 

Get-CsOnlineUser / Set-CsUser

Set-CsMeetingConfiguration -DesignateAsPresenter None

Get-CsExternalAccessPolicy

Get-CsPushNotificationConfiguration 

Get-CSClientPolicy
Related content
Breakout Sessions (session codes and titles)
OSP232 - Office 365 Security and Trust
OSP225 - Office 365 Identity Management
OSP233 - Office 365 Attractive and Easy to Use
OSP311 - Getting the Best of Both Worlds, Making the Most of SharePoint Hybrid Solutions
Find us tomorrow at the Microsoft Showcase
Track resources
Office 365 Blog: 
	http://blogs.office.com/b/microsoft_office_365_blog/
Twitter: 
	Follow @ https://twitter.com/Office365
Check out: 
	Garage Series for IT Pros: www.microsoft.com/garage
	Office 365 FastTrack: http://fasttrack.office.com//
Connect: 
	http://www.linkedin.com/groups/Microsoft-Office-365-3724282
Developer Network
Resources for Developers
http://msdn.microsoft.com/en-au/
Learning
TechNet
Resources
Sessions on Demand
http://channel9.msdn.com/Events/TechEd/Australia/2013
Keep Learning
Keep up to date with all the latest Office 365 information at http://ignite.office.com
Get on top of your pilot using the FastTrack deployment process http://fastTrack.office.com
Trial Office 365 http://office.microsoft.com
© 2013 Microsoft Corporation. All rights reserved. Microsoft, Windows and other product names are or may be registered trademarks and/or trademarks in the U.S. and/or other countries.
The information herein is for informational purposes only and represents the current view of Microsoft Corporation as of the date of this presentation.  Because Microsoft must respond to changing market conditions, it should not be interpreted to be a commitment on the part of Microsoft, and Microsoft cannot guarantee the accuracy of any information provided after the date of this presentation.  MICROSOFT MAKES NO WARRANTIES, EXPRESS, IMPLIED OR STATUTORY, AS TO THE INFORMATION IN THIS PRESENTATION.