3. Agenda Our main goal is to explore what’s possible in SharePoint using Windows PowerShell… …and to start looking at the major command sets that accomplish administrative tasks We’ll spend a lot of time examining the Help files as part of this
5. SP Management Shell Not really an independent shell… …just a “preloaded” Windows PowerShell Loads a specific module/snapin at startup so that SP commands are available You could also manually load these into a “normal” shell (or 3rd-party host) Let’s see
6. Shell Admin Permissions Need to grant admins the right to use the management shell Get-SPShellAdmin Add-SPShellAdmin –username DOMAINser-database (Get-SPContentDatabase-Identity database_name) Remove-SPShellAdmin
7. Cmdlet Naming Notice the SP prefix on the noun of all SharePoint cmdlets? Get-Command –noun SP* Or… Get-Command limited to the SharePoint module/snapin (let’s see)
8. START THINKING… What SP admin tasks would YOU want to automate within the shell? Your ideas will drive our discovery of commands and capabilities… so start coming up with ideas!
9. Starting Commands Get-SPSite (get site collections) Get-SPWeb (get Webs) Try this:Get-SPSite –limit All |Get-SPWeb –limit All |Where { -not $_.RequestAccessEnabled }
10. Limits Most Get-SP* commands limit to 20 objects Use –Limit to change that; either numeric or “All.” Be aware of potential performance issues with large result sets – avoid doing so on production servers unless necessary
11. Filters Most Get-SP* commands also include a –filter parameter Limits the results to just those that meet the filter criteria Best way to filter – as opposed to using Where – if the property you want to filter on is supported
18. NOW… let’s do some Q&A I’ve got more demos to show you, but want to make sure I address your questions Ask ‘em now! The remainder of the session will be additional demos
19. Final Q&A Text DONJ to 50500 for contact info See me for add’l resources Books Workshop recordings Demo videos Etc Slide decks posted to ConcentratedTech.com by next week
20. Final Notes… Please be sure to submit a session evaluation form! Download slides & materials from www.ConcentratedTech.com within one week! Blog, URLs, and other information is also available at www.ConcentratedTech.com for your reference More resources at www.ShellHub.com Thank you very much!
21. Your Feedback is Important Please fill out a session evaluation form. Thank you!