Repurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost Saving
PowerShell + SharePoint Online - An Admin's Guide
1. PowerShell + SharePoint Online
– An Admins Guide to
Administration in the O365 Cloud
Marrell Sanders – Sr. SharePoint Administrator
ShareCloud Summit Dallas, TX | May 2nd, 2018
2. Who Am I
Marrell Sanders, MCTS
Senior SharePoint Administrator
Love’s Travel Stops and Country Stores
MS Group IT
Contact
Email: techrevmarrell@outlook.com
Blog: www.techrevmarrell.com
Twitter: @TechRevMarrell
3. Key Takeaways
What’s new with PoSh for SPO
How to manage sites, users, groups with O365 PowerShell
Automate Business Scenarios with PowerShell
Scheduling Tasks using Azure
Security with Automated and Remote Scripting
The Top Ten cmdlets SP Admins will use
4. SharePoint Admin Role
What happened to it?
Remember the good old days of SharePoint Administration?
MOSS 2007
SharePoint 2010 or 2013?
Huge Server Farms
5. Todd Klindt and Shane Young predicted the collapse of
the “old ways” of the SharePoint Administrators.
“The Old Admin Ways Must End”
6. Microsoft said a long time ago, ya know
who can run a SharePoint farm better
than us?
9. Learn a new skill
Time to become a Developer….. Sort
of, but not really, but kinda.
10. What is PowerShell?
PowerShell is an object-oriented
programming language and
interactive command line shell for
Microsoft Windows.
#POSH
#PowerShell
13. What tools do we have?
Azure AD
SPO Service
MS Teams
14. What tools do we have?
Azure AD
install-module –Name AzureAD
SPO Service
Connect-SPOService –url https://tenant-admin.sharePoint.com
MS Teams
Connect-MicrosoftTeams –url https://tenant.sharePoint.com
19. What is CSOM
Client Side Object Model
We need to include the Client Object Model Libraries into our Scripts.
https://www.nuget.org/packages/Microsoft.SharePointOnline.CSOM
23. PnP PowerShell
SharePoint Patterns and Practices (PnP) contains a
library of PowerShell commands (PnP PowerShell)
that allows you to perform complex provisioning and
artifact management actions towards SharePoint.
The commands use CSOM and can work against both
SharePoint Online as SharePoint On-Premises.
https://docs.microsoft.com/en-
us/powershell/sharepoint/sharepoint-
pnp/sharepoint-pnp-cmdlets?view=sharepoint-ps
24. PnP PowerShell
Connect-PnPOnline –url -credentials (Get-Credential)
Get-Command -Module *PnP*
Get-PnPMasterPage
Set-PnPMasterPage
Check In File
Who’s a site collection admin on the site.
26. My Top 10
1. Get-SPOSite
2. New-SPOSite
3. Remove-SPOSite
4. Get-allsubsites in Sitecollection
5. Get-AllSubsites and Site Collections
in Farm
6. Everything in sharePont PnP
7. Scheduled Task from Azure
8. Import into List
9. Create Multiple Site Collections
10. Restore-SPODeletedSite
http://techrevmarrell.com/SPOTop10