1.16k likes | 1.45k Views
PowerShell: Not just for Windows anymore Microsoft Tech Talks. Presenter: Mike O’Neill Title: Sr. Premier Field Engineer (PFE) WIFI Login: Password: Start: 2:00pm WELCOME AND PLEASE HELP YOURSELF TO FOOD / DRINKS!. Agenda:. 1:45 PM – Check-in / Food /Networking 2:00 PM – Welcome/Kickoff
E N D
PowerShell: Not just for Windows anymoreMicrosoft Tech Talks Presenter: Mike O’Neill Title: Sr. Premier Field Engineer (PFE) WIFI Login: Password: Start: 2:00pm WELCOME AND PLEASE HELP YOURSELF TO FOOD / DRINKS!
Agenda: • 1:45 PM – Check-in / Food /Networking • 2:00 PM – Welcome/Kickoff • 2:05 PM – Featured Speaker: Mike O’Neill
Facilities: • Restrooms • Down the hallway behind the reception desk • WiFi • Username: • Password:
What are Microsoft Tech Talks? • Microsoft Tech Talks is a Technical Community event, designed to bring IT leaders in the local area together at a Microsoft facility, for deep Microsoft-technology based discussions, and • An opportunity to network and share with local Microsoft Services Professionals and other IT professionals. • A Microsoft Services presenter delivers a technically-rich presentation covering a product, product feature, or service that Microsoft offers, • Our presenters are world-class Subject Matter Experts and trusted advisors to our highly-valued customers. • Our meetings are a great opportunity to 'ask the experts' questions about their given field of expertise. • Subjects vary from session to session and attempt to be at the leading edge, showcasing our latest features and products available. • These communities now collectively have over 2500 members that have joined one of the local meetup groups. • We are constantly expanding to a region near you, your friends / colleagues….. http://aka.ms/mtt
We are on meetup!!! http://meetup.com/mttdenver • Join Us • Join Other Groups • RSVP Closed does not mean Closed! Look for the Microsoft Events sign-up link! • We send details of other events out • Look out for polls • Tell all your friends / colleagues • Group Review!!
Meetups http://www.meetup.com https://aka.ms/MTTCommunity
Survey • Your feedback is appreciated! • Microsoft Tech Talks – Friday March 15th 2019 • https://aka.ms/denversurvey VERY Short 10 questions! Please be aware that your feedback is extremely valued and important to us, as in addition to improving the quality of our events, it helps us to justify the time, effort and money in hosting, funding and organizing these events.
Microsoft Premier Offerings Please contact your Microsoft Technical Account Manager if interested in any of the Offerings mentioned.
PowerShell Workshops WorkshopPLUS – Windows PowerShell: Foundation Skills WorkshopPLUS – PowerShell Core: Fundamentals WorkshopPLUS – Windows PowerShell: Administration Skills WorkshopPLUS – Windows PowerShell: Desired State Configuration WorkshopPLUS – Windows PowerShell: Developer Skills
Identity Workshops Windows_Server_2012-2012R2_Active_Directory_Domain_Services WorkshopPLUS Windows_Server_2012_Active_Directory_Domain_Services WorkshopPLUS Windows_Server_Active_Directory_Hands-On_Labs Workshop Windows_Server_2012-Managing_and_Supporting_Active_Directory_Certificate_Services_(ADCS) WorkshopPLUS- Windows Server 2008 R2 Managing and Supporting a Windows 2008 R2 Active Directory Certificate Services Workshop Windows_Server_Group_Policy_Administration_and_Troubleshooting WorkshopPLUS Windows_Server_2012_DirectAccess_Deployment_and_Troubleshooting Windows Server 2008 PKI (AD CS) Upgrade and Migration WorkshopPLUS Active_Directory_Upgrade_Assessment_(ADUA)_for_Windows_Server_2008_R2 Workshop Windows_Server_2003-2008R2_Active_Directory_Backup_And_Disaster_Recovery Workshop Active_Directory_Upgrading_AD_from_Server_2003_to_Server_2008_R2 Workshop
Networking Workshops Windows_Server_2012_Networking WorkshopPLUS Windows_Server_Networking_Understanding_IPv6 WorkshopPLUS
Security Workshops Windows_Server_2012-New_Security_Features WorkshopPLUS Windows_Server-Securing_Windows_Server_2012 WorkshopPLUS Defense_in_Depth_Securing_Windows_Server_2008_R2
http://aka.ms/MTTCommunity http://aka.ms/denversurvey
Edit Scenario overview • Your IT environment is comprised of heterogenous Operating Systems (OS’s). • You need to manage (efficiently and easily), all of the different OS’s in your environment using a common platform.
Edit Problem: Different Operating Systems • No common platform for management • IT staff has to be specialized in each OS • Too many different scripting/coding options, need single management tool • No easy way to use the same coding
Edit Value proposition Why should I use/learn PowerShell? Because PowerShell is a single point, ubiquitous platform that: • works with many products/vendors: SAN’s, Citrix, cisco, VMware, Windows, Exchange, Oracle, SQL, System Center, and O365 (Delve, Planner, StaffHub, Dynamics, Security and Compliance, Teams, etc.) • is a single administrative/development environment for heterogenous environments
Edit PowerShell Core overview • Task-based command-line shell and scripting language, built on the .NET framework • Designed especially for system administration • Helps IT professionals and power users control and automate the administration of several operating systems and applications that run on those operating systems • Visual Studio free PowerShell plug-in available
Edit Scripting language • Automation • Disaster Recovery • High Availability • Deployment • Auditing • Health Check • Monitoring • Reporting • GUI over PowerShell • And more…
Edit Semantics For clarification in this discussion: • Windows PowerShell will be referred to as ‘Windows PowerShell’ • PowerShell Core will be referred to as ‘PowerShell’
Edit Ubiquity – Windows, mac, and Linux • Common interface and cmdlets • Runs natively on: Windows, Linux, and macOS X • Open source on GitHub ♡ Existing PS Users Mgmt Products App Developers Linux Users Single stack to manage anything from anywhere Manage Linux and Windows systems from any computer Framework transforms a small amount of code into rich automation and configuration Another tool in your toolbox. Optimized for structured data, REST APIs, and object models
Edit Ubiquity - PowerShell everywhere • PowerShell and DSC play well with other configuration management solutions like Chef and Puppet • Windows PowerShell down level to Server 2008 R2 and Windows 7 • Open-source, cross-platform PowerShell Core 6.0 • Available on Windows, Nano, Mac, and Linux • Based on the .NET Core • PowerShell plugin for Visual Studio • Nearly at parity with the ISE • Integrated terminal • Debugging
Edit .NET framework • Software framework provides language interoperability • Available through download • This framework install requires a reboot
Edit .NET core • PowerShell Core requires .NET Core • Available through download • This framework install requires a reboot
Edit File extensions • PS1 – Windows PowerShell shell script • PSD1 – Windows PowerShell data file (for Version 2+) • PSM1 – Windows PowerShell module file (for Version 2+) • PS1XML – Windows PowerShell format and type definitions • CLIXML – Windows PowerShell serialized data • PSC1 – Windows PowerShell console file • PSSC – Windows PowerShell Session Configuration file
Edit Monad • August 2002: Monad Manifesto (Microsoft Shell) was published • April 25, 2006: MS renamed Monad to Windows PowerShell
Edit Open-source • Windows PowerShell was made open-source and cross-platform, August 18, 2016 • PowerShell Core 6.0 GA January, 2018 • PowerShell Core 6.1 GA September, 2018 • PowerShell Core 6.2 GA March, 2019 • Support for Windows, macOS, CentOS, and Ubuntu • GitHub was leveraged for distribution • Running on .NET Core
Edit PowerShell Core: Windows supported versions Complete list of OS’s: PowerShell Core Support Lifecycle page: https://docs.microsoft.com/en-us/powershell/scripting/powershell-core-support?view=powershell-6 Windows update installable: Windows Server 2008 R2 Windows 7 Windows Server 2012 Windows 8 Windows Server 2012 R2 Windows 8.1 Windows Server 2016 Windows 10
Edit PowerShell Core: other OS supported versions Complete list of OS’s: PowerShell Core Support Lifecycle page: https://docs.microsoft.com/en-us/powershell/scripting/powershell-core-support?view=powershell-6 Other OS’s: Ubuntu 14.04, 16.04 Debian 8.7+ and 9 CentOS7 Red Hat Enterprise Linux 7 OpenSUSE 42.3 Fedora 27 MacOS 10.12+
Edit PowerShell Core: community/experimental • PowerShell is agile • OS’s are available via ‘Community’ or ‘Experimental’ options for support Ubuntu 18.04 (Core 6.1) Raspbian AppImage Arch Kali
Edit PowerShell Core: out of support OS’s The lifecycle page will also post ‘out of support’ OS’s
Edit PS Core on GitHub
Edit What is a heterogeneous environment Using hardware and system software from different vendors Organizations often use computers, operating systems, and databases from a variety of vendors Require the participation of highly skilled professionals who are able to fluently manage multiple operating systems and hardware Can leverage on premises or cloud, including multi-cloud mixtures
Edit Simplify management of environment Leverage unified homogenous protocols Use united toolsets Minimize training and cross usage of multiple editors and tools
Edit PowerShell differences
Edit PowerShell Core limitations Some modules are incompatible with .NET Core A few “built-in” cmdlets are missing from PowerShell Core WMI v1 cmdlets, PerfCounter, EventLog, LocalAccounts On non-Windows platforms, these modules are missing: CimCmdlets Microsoft.WSMan.Management PSDiagnostics Removed snap-ins and workflow from PS Core (May be added in later)
Edit WMI v1 cmdlets Recommend to use: Get-CimAssociatedInstance Get-CimClass Get-CimInstance Get-CimSession Invoke-CimMethod New-CimInstance New-CimSession New-CimSessionOption Register-CimIndicationEvent Remove-CimInstance Remove-CimSession Set-CimInstance Removed: Get-WmiObject Invoke-WmiMethod Register-WmiEvent Set-WmiInstance
Edit *-Counter cmdlets Due to the use of unsupported APIs, the *-Counter has been removed from PowerShell Core until a better solution is found. Note: * is reference to: Get, Set, New, Remove, etc. verbs for cmdlets
Edit Module coverage for Windows WindowsCompatibility module Downloadable: https://github.com/PowerShell/WindowsCompatibility Module that allows Windows PowerShell Modules to be used from PS Core Transparent implicit remoting to local Windows PowerShell PowerShell Core 6.1 on Windows 10 version 1809 and Windows Server 2019 Compatibility with 1900+ existing cmdlets
Edit Scenario Overview • What coding application to use? • Is there a free version that is compatible with all OS’s? • Visual Studio Code is the answer
Edit Visual Studio Code (VS Code) • Development Tool (many languages) • Graphical Editor • Execution and Debugging • Source Control Integration
Edit VS Code features from ISE • Intellisense • Auto save and crash recovery • Syntax highlighting (themes) • Collapsible code • Brace matching • Code snippets (Start typing then press Tab Tab)
Edit Additional features • Browse work as projects in a workspace folder • Powerful search and replace • View function definitions and references inline • Code lens • Source control integration (Git) • Improved debugging experience • Community extensions • Testing integration
Edit VS Code vs. Windows Integrated Scripting Environment (ISE) This… not this…unless