SlideShare una empresa de Scribd logo
1 de 25
www.orbitone.com
Raas van Gaverestraat 83
B-9000 GENT, Belgium
E-mail info@orbitone.com
Website www.orbitone.com
Tel. +32 9 265 74 20
Fax +32 9 265 74 10
VAT BE 456.457.353
Bank 442-7059001-50 (KBC)
17 December, 2009 Windows PowerShell 2.0, By Tom Pester
17 December, 2009
Windows PowerShell 2.0, By Tom Pester
What is PowerShell ?
17 December, 2009
Windows PowerShell 2.0, By Tom Pester
17 December, 2009
Windows PowerShell 2.0, By Tom Pester
17 December, 2009
Windows PowerShell 2.0, By Tom Pester
17 December, 2009
Windows PowerShell 2.0, By Tom Pester
Why PowerShell?
 PowerShell was designed to do for Windows what the UNIX shells dooes for UNIX:
provide a powerful, well-integrated command-line experience for the operation system.
But better :)
 Unlike most scripting languages, the basic object model for PowerShell is .NET
 PowerShell has full access to all of the types in the .NET framework and not a few simple
objects
 Windows is mostly managed through objects comming from
MI (WINDOWS MANAGEMENT INFRASTRUCTURE)
COM (COMPONENT OBJECT MODEL)
and .NET
 As Windows moves from the desktop to server farms or application servers (like print,
DNS and LDAP services,etc.) command-line automation becomes a fundamental
requirement.
17 December, 2009
Windows PowerShell 2.0, By Tom Pester
Who has PowerShell?
 Its installed out of the box on Windows 7 and Windows Server 2008 R2.
 It has also been released for older platforms:
Windows XP SP3
Windows Server 2003 SP2
Windows Vista SP1
and Windows Server 2008
17 December, 2009
Windows PowerShell 2.0, By Tom Pester
PowerShell Concepts
 - Cmdlets
These are built-in commands written in a .NET language like C# or Visual Basic.
Typically Developers can extend the set of cmdlets by writing and loading PowerShell snap-ins.
 Functions
Functions are commands written in the PowerShell language.
These can be developed without an IDE like Visual Studio by sysadmins and devs
 Scripts
Scripts are textfiles on disk with a .ps1 extension
 Applications (aka native commands)
Applications are existing windows programs.
17 December, 2009
Windows PowerShell 2.0, By Tom Pester
Providers
 Most applications have some sort of "hierarchical" data store
 Example are Exchange, Active Directory, SharePoint, SQL Server
 for example in sql server multiple instances of sql server can be installed
 Once you are in an instance you can select jobs, roles, etc or databases
 In a specific database you can choose triggers, logfiles, etc and tables
 Providers in PowerShell allow data to be presented from different data stores in a
consistent fashion to existing cmdlets.
 There are 7 providers built into PowerShell (Alias, Environment, File System, Function,
Registry, Variable, and Certificate).
17 December, 2009
Windows PowerShell 2.0, By Tom Pester
Pipeline
 UNIX scripting shells also use the concept of a pipeline.
 This is extremely powerful, but suffers from the disadvantage that, in most cases, the
pipelined data is just raw text.
 This means prayer-based parsing. Rather than passing text, PowerShell passes .NET
objects. That means a cmdlet can use .NET reflection to look inside what is getting passed,
and know what's being passed
17 December, 2009
Windows PowerShell 2.0, By Tom Pester
The pipeline
17 December, 2009
Windows PowerShell 2.0, By Tom Pester
DEMO
============================================================
==== DEMO START based on video 1 (http://www.idera.com/Promo/Practical-PowerShell/)
============================================================
*. To see everything PS can do run
> get-command
*. to get all the manuals
> help
*. get a list of all process :
> get-process
*. Piping |
Default there is "Out-Default" , per defalt it outputs everything as text
> get-process | out-default
*. Cleaning the scree
> cls
*. Lets get the top 10 memory consuming processess
> get-process | sort vm -descending | select -first 10
*. How did I know that vm was a property of a Service Object
Get-Service | get-member
* Comments in Powershell, block
<#
Now
is
the
time
to
use
PowerShell
#>
* Comments in Powershell, line
# Now
# is
# the
* Lets tweak the output
get-process | format-table name,id,responding,path
=> some columns are cut
* show help for format-table
* lets do something about the cut columns
get-process | format-table name,id,responding,path -autosize -wrap
* to learn about autosize and wrap
For more information, type:
> get-help Format-Table -detailed
* Focused help
> get-help Format-Table -examples
* lets write the report to a textfile
> Get-Process | Format-table name,id | Out-File c:temptest.txt
=> Not that we still use the pipe symbol and not > as we would do in good old dos
* Lets peek inside the event log
> Get-EventLog security -newest 50
* And take a look at it in Excel
> Get-EventLog security -newest 50 | Export-Csv c:temptest.csv
17 December, 2009
Windows PowerShell 2.0, By Tom Pester
Runspaces: Windows PowerShell hosting mechanism
 The Windows PowerShell runtime can be embedded inside other applications (jargon: in a
PowerShell "runspace").
 These applications then leverage Windows PowerShell functionality to implement certain
operations
 This capability has been utilized by Microsoft Exchange Server 2007 :
As for Exchange Server 2007, the entire server was built with Windows PowerShell in mind. In fact,
the Exchange Management Interface was designed in such a way that all the mouse-clicks and
menu-clicks are actually calls to Exchange-PowerShell cmdlets.
 This is Microsoft's direction by defining this in their common engineering criteria
 In the future all Microsoft Applications running on the Windows platform are to be
PowerShell aware.
 3th Party providers bundle PowerShell Support with their products as PS Snap-ins
17 December, 2009
Windows PowerShell 2.0, By Tom Pester
PowerShell enabled applications
17 December, 2009
Windows PowerShell 2.0, By Tom Pester
PowerShell enabled applications
Application Version Cmdlets Provider Management GUI
Exchange Server 2007 402 Yes Yes
Windows Server 2008 Yes Yes No
Microsoft SQL Server 2008 Yes Yes No
System Center Operations Manager 2007 74 Yes No
System Center Virtual Machine Manager 2007 Yes Yes Yes
System Center Data Protection Manager 2007 Yes No No
Windows Compute Cluster Server 2007 Yes Yes No
Microsoft Transporter Suite for Lotus Domino[37] 08.02.0012 47 No No
Microsoft PowerTools for Open XML[38] 1.0 33 No No
IBM WebSphere MQ[39] 6.0.2.2 44 No No
Quest Management Shell for Active Directory[40] 1.1 40 No No
Special Operations Software Specops Command[41] 1.0 Yes No Yes
VMware Infrastructure Toolkit[42] 1.5 157 No No
Internet Information Services[43] 7.0 54 Yes No
Ensim Unify Enterprise Edition[44] 1.6 Yes No Yes
Windows 7 Troubleshooting Center[45] 6.1 Yes No Yes
Microsoft Deployment Toolkit 2010 Yes No No
[edit] SnapIns and hosts
17 December, 2009
Windows PowerShell 2.0, By Tom Pester
A top overview of the features introduced in PowerShell 2
 PowerShell Remoting: Using WS-Management, PowerShell 2.0 allows scripts and cmdlets
to be invoked on a remote machine or a large set of remote machines.
 Background Jobs: Also called a PSJob, it allows a command sequence (script) or pipeline to
be invoked asynchronously. Jobs can be run on the local machine or on multiple remote
machines.
 Transactions: Enable cmdlet and provider developers to perform transacted operations.
 Script Debugging: It allows breakpoints to be set in a PowerShell script or function.
 Eventing: This feature allows listening, forwarding, and acting on management and system
events.
 Network File Transfer: Native support for prioritized, throttled, and asynchronous transfer
of files between machines using the Background Intelligent Transfer Service (BITS).
17 December, 2009
Windows PowerShell 2.0, By Tom Pester
Consistency and Discoverablity
 One of the great things of PS is the consistency and discoverablity.
 If you switch from one domain to another, lets say SQL Server to Active Directory, you can
predict what you can ask PowerShell of AD beceause you are used to SQL Server
17 December, 2009
Windows PowerShell 2.0, By Tom Pester
Save Tasks and Schedule
 A task can be saved as a script and reused at a later time or even scheduled.
For example, if you are responsible for a server park of 10 (or 1000) servers and you are interested in
the temperature you can write out the script once, save it as a script and give it a list of the servers
you are interested in.
When new servers are added you just update this list and it will give you brief report of the data you
are interested in.
IMO graphical user interfaces have their place but the power you get if you can do everying from 1
central place is not to be underestimated.
17 December, 2009
Windows PowerShell 2.0, By Tom Pester
Why PowerShell? Why not C#?
 First of all C# is not a scripting language. YOu need a compiler to make use of C#.
 If you consider a system administrator managing 10+ web servers, he/she will never install
2 gigabytes of Visual Studio on every server to edit his C# utility.
 If you have any utility that you are running on production system and want to make some
minor changes then you need to go back to your desktop where you have your source
code preferably Visual Studio installed, edit your C# program, recompile it and copy it back
to production system.
 If you really want to write actual code in C#, you need to have some knowledge of OOPs
(object oriented programming) concept (how to define class? what are static methods?)
 Even if you are writing a simple program you need to write at least main method? What
are class access rules, why to make this function public, or static etc?
17 December, 2009
Windows PowerShell 2.0, By Tom Pester
Sysadmin Challenges
 To manage a network today, Administrators face a range of challenges with respect to
tools:
Wide range: Admins are required to be experts in a huge range of tools and scripts. That’s because,
thus far, no one tool, does everything.
GUI Scalability: a GUI is a great tool for performing a single operation on just one computer, but it
can be slow and tedious if you need to perform that same operation on 1,000 systems.
17 December, 2009
Windows PowerShell 2.0, By Tom Pester
Starting up PowerShell from SQL Server 2008
This is a locked down version of PowerShell so it exposes reproducible behavior.
17 December, 2009
Windows PowerShell 2.0, By Tom Pester
* the "whatif" feature : PS> get-process p* | stop-process -
whatif
17 December, 2009
Windows PowerShell 2.0, By Tom Pester
SharePoint 2010
 STSADM is legacy, PowerShell is the replacement:
http://dmitrysotnikov.wordpress.com/2009/10/19/sharepoint-2010-cmdlet-reference/
17 December, 2009
Windows PowerShell 2.0, By Tom Pester
Recommended books & resources
 Publicly available : http://powershell.com/cs/blogs/ebook/
 Publically available : free : http://www.idera.com/Promo/Practical-PowerShell/
 Nice video on Powershell in SharePoint 2010 http://technet.microsoft.com/en-
us/sharepoint/ee518673.aspx
 MSDN http://msdn.microsoft.com/en-us/library/cc281954.aspx
 Start with http://www.amazon.com/Microsoft-PowerShell-Programming-Absolute-
Beginner/dp/1598638998/ref=sr_1_2?ie=UTF8&s=books&qid=1258411028&sr=8-2
 Become an expert with http://www.amazon.com/Windows-Powershell-Action-Bruce-
Payette/dp/1932394907/ref=sr_1_3?ie=UTF8&s=books&qid=1258411028&sr=8-3
 Microsoft SQL Server 2008 Administration with Windows PowerShell
http://www.amazon.com/Microsoft-Administration-Windows-Power-
ShellProgrammer/dp/0470477288/ref=sr_1_14?ie=UTF8&s=books&qid=1258411028&sr=8-14
 Managing VMware Infrastructure with Windows PowerShell TFM
http://www.amazon.com/Managing-VMware-Infrastructure-Windows-
PowerShell/dp/0982131402/ref=sr_1_1?ie=UTF8&s=books&qid=1258411111&sr=8-1
www.orbitone.com
Windows PowerShell 2.0, By Tom Pester
17 December, 2009

Más contenido relacionado

La actualidad más candente

Game server development in node.js
Game server development in node.jsGame server development in node.js
Game server development in node.jsXie ChengChao
 
MSMDC_CLI363
MSMDC_CLI363MSMDC_CLI363
MSMDC_CLI363mokacao
 
Game server development in node.js in jsconf eu
Game server development in node.js in jsconf euGame server development in node.js in jsconf eu
Game server development in node.js in jsconf euXie ChengChao
 
C++ Restrictions for Game Programming.
C++ Restrictions for Game Programming.C++ Restrictions for Game Programming.
C++ Restrictions for Game Programming.Richard Taylor
 
Linux Desktop Automation
Linux Desktop AutomationLinux Desktop Automation
Linux Desktop AutomationRui Lapa
 
Centralized Fog Server with OpenLDAP
Centralized Fog Server with OpenLDAP Centralized Fog Server with OpenLDAP
Centralized Fog Server with OpenLDAP tare
 
Step by step_linux_guide
Step by step_linux_guideStep by step_linux_guide
Step by step_linux_guidevinod31dec
 
Infrastructure as Code in your CD pipelines - London Microsoft DevOps 0423
Infrastructure as Code in your CD pipelines - London Microsoft DevOps 0423Infrastructure as Code in your CD pipelines - London Microsoft DevOps 0423
Infrastructure as Code in your CD pipelines - London Microsoft DevOps 0423Giulio Vian
 
Drupal, Memcache and Solr on Windows
Drupal, Memcache and Solr on WindowsDrupal, Memcache and Solr on Windows
Drupal, Memcache and Solr on WindowsAlessandro Pilotti
 
Linux Shortcuts and Commands:
Linux Shortcuts and Commands:Linux Shortcuts and Commands:
Linux Shortcuts and Commands:wensheng wei
 
Bypassing anti virus scanners
Bypassing anti virus scannersBypassing anti virus scanners
Bypassing anti virus scannersmartacax
 
Linux Based Network Proposal
Linux Based Network ProposalLinux Based Network Proposal
Linux Based Network ProposalChris Riccio
 
Linux questions
Linux questionsLinux questions
Linux questions1gman68
 
Bewährte Praktiken für HCL Notes/Domino-Sicherheit. Teil 2: Der Domino-Server
Bewährte Praktiken für HCL Notes/Domino-Sicherheit. Teil 2: Der Domino-ServerBewährte Praktiken für HCL Notes/Domino-Sicherheit. Teil 2: Der Domino-Server
Bewährte Praktiken für HCL Notes/Domino-Sicherheit. Teil 2: Der Domino-Serverpanagenda
 
Prizm Installation Guide
Prizm Installation GuidePrizm Installation Guide
Prizm Installation Guidevjvarenya
 

La actualidad más candente (20)

PowerShell 2.0 remoting
PowerShell 2.0 remotingPowerShell 2.0 remoting
PowerShell 2.0 remoting
 
Game server development in node.js
Game server development in node.jsGame server development in node.js
Game server development in node.js
 
MSMDC_CLI363
MSMDC_CLI363MSMDC_CLI363
MSMDC_CLI363
 
Game server development in node.js in jsconf eu
Game server development in node.js in jsconf euGame server development in node.js in jsconf eu
Game server development in node.js in jsconf eu
 
C++ Restrictions for Game Programming.
C++ Restrictions for Game Programming.C++ Restrictions for Game Programming.
C++ Restrictions for Game Programming.
 
Linux Desktop Automation
Linux Desktop AutomationLinux Desktop Automation
Linux Desktop Automation
 
Centralized Fog Server with OpenLDAP
Centralized Fog Server with OpenLDAP Centralized Fog Server with OpenLDAP
Centralized Fog Server with OpenLDAP
 
Step by step_linux_guide
Step by step_linux_guideStep by step_linux_guide
Step by step_linux_guide
 
Infrastructure as Code in your CD pipelines - London Microsoft DevOps 0423
Infrastructure as Code in your CD pipelines - London Microsoft DevOps 0423Infrastructure as Code in your CD pipelines - London Microsoft DevOps 0423
Infrastructure as Code in your CD pipelines - London Microsoft DevOps 0423
 
Drupal, Memcache and Solr on Windows
Drupal, Memcache and Solr on WindowsDrupal, Memcache and Solr on Windows
Drupal, Memcache and Solr on Windows
 
Linux Shortcuts and Commands:
Linux Shortcuts and Commands:Linux Shortcuts and Commands:
Linux Shortcuts and Commands:
 
Bypassing anti virus scanners
Bypassing anti virus scannersBypassing anti virus scanners
Bypassing anti virus scanners
 
Linux Based Network Proposal
Linux Based Network ProposalLinux Based Network Proposal
Linux Based Network Proposal
 
Linux questions
Linux questionsLinux questions
Linux questions
 
Users guide
Users guideUsers guide
Users guide
 
Ww
WwWw
Ww
 
Bewährte Praktiken für HCL Notes/Domino-Sicherheit. Teil 2: Der Domino-Server
Bewährte Praktiken für HCL Notes/Domino-Sicherheit. Teil 2: Der Domino-ServerBewährte Praktiken für HCL Notes/Domino-Sicherheit. Teil 2: Der Domino-Server
Bewährte Praktiken für HCL Notes/Domino-Sicherheit. Teil 2: Der Domino-Server
 
PowerShell-2
PowerShell-2PowerShell-2
PowerShell-2
 
Handout2o
Handout2oHandout2o
Handout2o
 
Prizm Installation Guide
Prizm Installation GuidePrizm Installation Guide
Prizm Installation Guide
 

Destacado

Unit 8a Taxation introduction
Unit 8a Taxation introductionUnit 8a Taxation introduction
Unit 8a Taxation introductionAndrew Hingston
 
Transport Issues in Adelaide | Biocity Studio
Transport Issues in Adelaide | Biocity StudioTransport Issues in Adelaide | Biocity Studio
Transport Issues in Adelaide | Biocity StudioBiocity Studio
 
Unit 18c Retirement dwellings
Unit 18c Retirement dwellingsUnit 18c Retirement dwellings
Unit 18c Retirement dwellingsAndrew Hingston
 
Artikel I Maintain Juni 2011
Artikel I Maintain Juni 2011Artikel I Maintain Juni 2011
Artikel I Maintain Juni 2011AlexSport
 
Trend: Customized
Trend: CustomizedTrend: Customized
Trend: CustomizedNisha Gill
 
Academic Impropriety Vs academic impoverishment
Academic Impropriety Vs academic impoverishmentAcademic Impropriety Vs academic impoverishment
Academic Impropriety Vs academic impoverishmentOrna Farrell
 
Unit 4b Creative ways to own a home
Unit 4b Creative ways to own a homeUnit 4b Creative ways to own a home
Unit 4b Creative ways to own a homeAndrew Hingston
 
Altunizade Kültür Merkezi 18 Nisan 2014 Müzikli Maarif Takvimi gecesi
Altunizade Kültür Merkezi 18 Nisan 2014 Müzikli Maarif Takvimi gecesiAltunizade Kültür Merkezi 18 Nisan 2014 Müzikli Maarif Takvimi gecesi
Altunizade Kültür Merkezi 18 Nisan 2014 Müzikli Maarif Takvimi gecesiaokutur
 
Bahcelievler kültür merkezi 12 _04_2014 resimler
Bahcelievler kültür merkezi 12 _04_2014 resimlerBahcelievler kültür merkezi 12 _04_2014 resimler
Bahcelievler kültür merkezi 12 _04_2014 resimleraokutur
 
Reprioritising our values to recognise culture for its true value | Biocity S...
Reprioritising our values to recognise culture for its true value | Biocity S...Reprioritising our values to recognise culture for its true value | Biocity S...
Reprioritising our values to recognise culture for its true value | Biocity S...Biocity Studio
 
Navat Company
Navat CompanyNavat Company
Navat Companybeerguy
 
The Importance of Social and Mobile in Year-End Campaigns
The Importance of Social and Mobile in Year-End CampaignsThe Importance of Social and Mobile in Year-End Campaigns
The Importance of Social and Mobile in Year-End CampaignsCharity Dynamics
 
Participant Support Webinar
Participant Support Webinar Participant Support Webinar
Participant Support Webinar Charity Dynamics
 
Кризис роста в ИТ-компании Иоря Ашманова
Кризис роста в ИТ-компании Иоря АшмановаКризис роста в ИТ-компании Иоря Ашманова
Кризис роста в ИТ-компании Иоря АшмановаIngria. Technopark St. Petersburg
 

Destacado (20)

Unit 8a Taxation introduction
Unit 8a Taxation introductionUnit 8a Taxation introduction
Unit 8a Taxation introduction
 
Transport Issues in Adelaide | Biocity Studio
Transport Issues in Adelaide | Biocity StudioTransport Issues in Adelaide | Biocity Studio
Transport Issues in Adelaide | Biocity Studio
 
Escuelas 469 Y 2098 Ciudad De Florencia
Escuelas 469 Y 2098 Ciudad De FlorenciaEscuelas 469 Y 2098 Ciudad De Florencia
Escuelas 469 Y 2098 Ciudad De Florencia
 
Unit 3e Final tips
Unit 3e Final tipsUnit 3e Final tips
Unit 3e Final tips
 
Unit 18c Retirement dwellings
Unit 18c Retirement dwellingsUnit 18c Retirement dwellings
Unit 18c Retirement dwellings
 
Artikel I Maintain Juni 2011
Artikel I Maintain Juni 2011Artikel I Maintain Juni 2011
Artikel I Maintain Juni 2011
 
Trend: Customized
Trend: CustomizedTrend: Customized
Trend: Customized
 
Academic Impropriety Vs academic impoverishment
Academic Impropriety Vs academic impoverishmentAcademic Impropriety Vs academic impoverishment
Academic Impropriety Vs academic impoverishment
 
Unit 4b Creative ways to own a home
Unit 4b Creative ways to own a homeUnit 4b Creative ways to own a home
Unit 4b Creative ways to own a home
 
Altunizade Kültür Merkezi 18 Nisan 2014 Müzikli Maarif Takvimi gecesi
Altunizade Kültür Merkezi 18 Nisan 2014 Müzikli Maarif Takvimi gecesiAltunizade Kültür Merkezi 18 Nisan 2014 Müzikli Maarif Takvimi gecesi
Altunizade Kültür Merkezi 18 Nisan 2014 Müzikli Maarif Takvimi gecesi
 
Bahcelievler kültür merkezi 12 _04_2014 resimler
Bahcelievler kültür merkezi 12 _04_2014 resimlerBahcelievler kültür merkezi 12 _04_2014 resimler
Bahcelievler kültür merkezi 12 _04_2014 resimler
 
Reprioritising our values to recognise culture for its true value | Biocity S...
Reprioritising our values to recognise culture for its true value | Biocity S...Reprioritising our values to recognise culture for its true value | Biocity S...
Reprioritising our values to recognise culture for its true value | Biocity S...
 
Carioc Studio
Carioc StudioCarioc Studio
Carioc Studio
 
Navat Company
Navat CompanyNavat Company
Navat Company
 
Halle Berry
Halle BerryHalle Berry
Halle Berry
 
The Importance of Social and Mobile in Year-End Campaigns
The Importance of Social and Mobile in Year-End CampaignsThe Importance of Social and Mobile in Year-End Campaigns
The Importance of Social and Mobile in Year-End Campaigns
 
Participant Support Webinar
Participant Support Webinar Participant Support Webinar
Participant Support Webinar
 
NB - дайджест новостей
NB - дайджест новостей NB - дайджест новостей
NB - дайджест новостей
 
Кризис роста в ИТ-компании Иоря Ашманова
Кризис роста в ИТ-компании Иоря АшмановаКризис роста в ИТ-компании Иоря Ашманова
Кризис роста в ИТ-компании Иоря Ашманова
 
The elephant
The elephantThe elephant
The elephant
 

Similar a Windows PowerShell

Powershell Seminar @ ITWorx CuttingEdge Club
Powershell Seminar @ ITWorx CuttingEdge ClubPowershell Seminar @ ITWorx CuttingEdge Club
Powershell Seminar @ ITWorx CuttingEdge ClubEssam Salah
 
Sql Server & PowerShell
Sql Server & PowerShellSql Server & PowerShell
Sql Server & PowerShellAaron Shilo
 
PowerShell Technical Overview
PowerShell Technical OverviewPowerShell Technical Overview
PowerShell Technical Overviewallandcp
 
Wsv406 Advanced Automation Using Windows Power Shell2.0
Wsv406 Advanced Automation Using Windows Power Shell2.0Wsv406 Advanced Automation Using Windows Power Shell2.0
Wsv406 Advanced Automation Using Windows Power Shell2.0jsnover1
 
PowerShell for SharePoint Developers
PowerShell for SharePoint DevelopersPowerShell for SharePoint Developers
PowerShell for SharePoint DevelopersBoulos Dib
 
Brian Jackett: Managing SharePoint 2010 Farms with Powershell
Brian Jackett: Managing SharePoint 2010 Farms with PowershellBrian Jackett: Managing SharePoint 2010 Farms with Powershell
Brian Jackett: Managing SharePoint 2010 Farms with PowershellSharePoint Saturday NY
 
Brian Jackett: Managing SharePoint 2010 Farms with Powershell
Brian Jackett: Managing SharePoint 2010 Farms with PowershellBrian Jackett: Managing SharePoint 2010 Farms with Powershell
Brian Jackett: Managing SharePoint 2010 Farms with PowershellSharePoint Saturday NY
 
Windows Server 2008 Management
Windows Server 2008 ManagementWindows Server 2008 Management
Windows Server 2008 ManagementHi-Techpoint
 
Windows Server 2008 Management
Windows Server 2008 ManagementWindows Server 2008 Management
Windows Server 2008 ManagementHi-Techpoint
 
Power shell training
Power shell trainingPower shell training
Power shell trainingDavid Brabant
 
Inventory your network and clients with PowerShell
Inventory your network and clients with PowerShellInventory your network and clients with PowerShell
Inventory your network and clients with PowerShellConcentrated Technology
 
Introducing PowerShell 3.0
Introducing PowerShell 3.0Introducing PowerShell 3.0
Introducing PowerShell 3.0Jan Egil Ring
 
Automating Desktop Management with Windows Powershell V2.0 and Group Policy M...
Automating Desktop Management with Windows Powershell V2.0 and Group Policy M...Automating Desktop Management with Windows Powershell V2.0 and Group Policy M...
Automating Desktop Management with Windows Powershell V2.0 and Group Policy M...Microsoft TechNet
 
Learn Powershell Scripting Tutorial Full Course 1dollarcart.com.pdf
Learn Powershell Scripting Tutorial Full Course 1dollarcart.com.pdfLearn Powershell Scripting Tutorial Full Course 1dollarcart.com.pdf
Learn Powershell Scripting Tutorial Full Course 1dollarcart.com.pdfClapperboardCinemaPV
 
Windows PowerShell - Billings .NET User Group - August 2009
Windows PowerShell - Billings .NET User Group - August 2009Windows PowerShell - Billings .NET User Group - August 2009
Windows PowerShell - Billings .NET User Group - August 2009John Clayton
 

Similar a Windows PowerShell (20)

Powershell Seminar @ ITWorx CuttingEdge Club
Powershell Seminar @ ITWorx CuttingEdge ClubPowershell Seminar @ ITWorx CuttingEdge Club
Powershell Seminar @ ITWorx CuttingEdge Club
 
Sql Server & PowerShell
Sql Server & PowerShellSql Server & PowerShell
Sql Server & PowerShell
 
Activity 5
Activity 5Activity 5
Activity 5
 
PowerShell Technical Overview
PowerShell Technical OverviewPowerShell Technical Overview
PowerShell Technical Overview
 
Wsv406 Advanced Automation Using Windows Power Shell2.0
Wsv406 Advanced Automation Using Windows Power Shell2.0Wsv406 Advanced Automation Using Windows Power Shell2.0
Wsv406 Advanced Automation Using Windows Power Shell2.0
 
Server Core2
Server Core2Server Core2
Server Core2
 
PowerShell for SharePoint Developers
PowerShell for SharePoint DevelopersPowerShell for SharePoint Developers
PowerShell for SharePoint Developers
 
No-script PowerShell v2
No-script PowerShell v2No-script PowerShell v2
No-script PowerShell v2
 
Brian Jackett: Managing SharePoint 2010 Farms with Powershell
Brian Jackett: Managing SharePoint 2010 Farms with PowershellBrian Jackett: Managing SharePoint 2010 Farms with Powershell
Brian Jackett: Managing SharePoint 2010 Farms with Powershell
 
Brian Jackett: Managing SharePoint 2010 Farms with Powershell
Brian Jackett: Managing SharePoint 2010 Farms with PowershellBrian Jackett: Managing SharePoint 2010 Farms with Powershell
Brian Jackett: Managing SharePoint 2010 Farms with Powershell
 
Windows Server 2008 Management
Windows Server 2008 ManagementWindows Server 2008 Management
Windows Server 2008 Management
 
Windows Server 2008 Management
Windows Server 2008 ManagementWindows Server 2008 Management
Windows Server 2008 Management
 
Power shell training
Power shell trainingPower shell training
Power shell training
 
PowerShell-1
PowerShell-1PowerShell-1
PowerShell-1
 
Inventory your network and clients with PowerShell
Inventory your network and clients with PowerShellInventory your network and clients with PowerShell
Inventory your network and clients with PowerShell
 
Introducing PowerShell 3.0
Introducing PowerShell 3.0Introducing PowerShell 3.0
Introducing PowerShell 3.0
 
Automating Desktop Management with Windows Powershell V2.0 and Group Policy M...
Automating Desktop Management with Windows Powershell V2.0 and Group Policy M...Automating Desktop Management with Windows Powershell V2.0 and Group Policy M...
Automating Desktop Management with Windows Powershell V2.0 and Group Policy M...
 
PowerShell Remoting
PowerShell RemotingPowerShell Remoting
PowerShell Remoting
 
Learn Powershell Scripting Tutorial Full Course 1dollarcart.com.pdf
Learn Powershell Scripting Tutorial Full Course 1dollarcart.com.pdfLearn Powershell Scripting Tutorial Full Course 1dollarcart.com.pdf
Learn Powershell Scripting Tutorial Full Course 1dollarcart.com.pdf
 
Windows PowerShell - Billings .NET User Group - August 2009
Windows PowerShell - Billings .NET User Group - August 2009Windows PowerShell - Billings .NET User Group - August 2009
Windows PowerShell - Billings .NET User Group - August 2009
 

Más de Orbit One - We create coherence

ShareCafé: SharePoint - Een doos vol documenten of dé tool om efficiënt samen...
ShareCafé: SharePoint - Een doos vol documenten of dé tool om efficiënt samen...ShareCafé: SharePoint - Een doos vol documenten of dé tool om efficiënt samen...
ShareCafé: SharePoint - Een doos vol documenten of dé tool om efficiënt samen...Orbit One - We create coherence
 
ShareCafé: Office365 - Efficiënt samenwerken met minimum aan kosten en comple...
ShareCafé: Office365 - Efficiënt samenwerken met minimum aan kosten en comple...ShareCafé: Office365 - Efficiënt samenwerken met minimum aan kosten en comple...
ShareCafé: Office365 - Efficiënt samenwerken met minimum aan kosten en comple...Orbit One - We create coherence
 
ShareCafé 3 - Geef je samenwerking een technologische upgrade
ShareCafé 3 - Geef je samenwerking een technologische upgradeShareCafé 3 - Geef je samenwerking een technologische upgrade
ShareCafé 3 - Geef je samenwerking een technologische upgradeOrbit One - We create coherence
 
OneCafé: De toekomst van ledenorganisaties met behulp van CRM en informatie-u...
OneCafé: De toekomst van ledenorganisaties met behulp van CRM en informatie-u...OneCafé: De toekomst van ledenorganisaties met behulp van CRM en informatie-u...
OneCafé: De toekomst van ledenorganisaties met behulp van CRM en informatie-u...Orbit One - We create coherence
 
OneCafé: The future of membership organizations facilitated by CRM and collab...
OneCafé: The future of membership organizations facilitated by CRM and collab...OneCafé: The future of membership organizations facilitated by CRM and collab...
OneCafé: The future of membership organizations facilitated by CRM and collab...Orbit One - We create coherence
 
Social Computing in your organization using SharePoint: challenges and benefits
Social Computing in your organization using SharePoint: challenges and benefitsSocial Computing in your organization using SharePoint: challenges and benefits
Social Computing in your organization using SharePoint: challenges and benefitsOrbit One - We create coherence
 
Marketing Automation in Dynamics CRM with ClickDimensions
Marketing Automation in Dynamics CRM with ClickDimensionsMarketing Automation in Dynamics CRM with ClickDimensions
Marketing Automation in Dynamics CRM with ClickDimensionsOrbit One - We create coherence
 

Más de Orbit One - We create coherence (20)

ShareCafé: SharePoint - Een doos vol documenten of dé tool om efficiënt samen...
ShareCafé: SharePoint - Een doos vol documenten of dé tool om efficiënt samen...ShareCafé: SharePoint - Een doos vol documenten of dé tool om efficiënt samen...
ShareCafé: SharePoint - Een doos vol documenten of dé tool om efficiënt samen...
 
HoGent tips and tricks van een self-made ondernemer
HoGent tips and tricks van een self-made ondernemer HoGent tips and tricks van een self-made ondernemer
HoGent tips and tricks van een self-made ondernemer
 
Het Nieuwe Werken in de praktijk
Het Nieuwe Werkenin de praktijkHet Nieuwe Werkenin de praktijk
Het Nieuwe Werken in de praktijk
 
ShareCafé: Office365 - Efficiënt samenwerken met minimum aan kosten en comple...
ShareCafé: Office365 - Efficiënt samenwerken met minimum aan kosten en comple...ShareCafé: Office365 - Efficiënt samenwerken met minimum aan kosten en comple...
ShareCafé: Office365 - Efficiënt samenwerken met minimum aan kosten en comple...
 
ShareCafé 3 - Geef je samenwerking een technologische upgrade
ShareCafé 3 - Geef je samenwerking een technologische upgradeShareCafé 3 - Geef je samenwerking een technologische upgrade
ShareCafé 3 - Geef je samenwerking een technologische upgrade
 
ShareCafé 2 - Werk slimmer door geïntegreerde tools
ShareCafé 2 - Werk slimmer door geïntegreerde toolsShareCafé 2 - Werk slimmer door geïntegreerde tools
ShareCafé 2 - Werk slimmer door geïntegreerde tools
 
ShareCafé 1: Hou de Nieuwe Werker gemotiveerd
ShareCafé 1: Hou de Nieuwe Werker gemotiveerdShareCafé 1: Hou de Nieuwe Werker gemotiveerd
ShareCafé 1: Hou de Nieuwe Werker gemotiveerd
 
Business value of Lync integrations
Business value of Lync integrationsBusiness value of Lync integrations
Business value of Lync integrations
 
OneCafé: De toekomst van ledenorganisaties met behulp van CRM en informatie-u...
OneCafé: De toekomst van ledenorganisaties met behulp van CRM en informatie-u...OneCafé: De toekomst van ledenorganisaties met behulp van CRM en informatie-u...
OneCafé: De toekomst van ledenorganisaties met behulp van CRM en informatie-u...
 
Identity in the cloud using Microsoft
Identity in the cloud using MicrosoftIdentity in the cloud using Microsoft
Identity in the cloud using Microsoft
 
OneCafé: The future of membership organizations facilitated by CRM and collab...
OneCafé: The future of membership organizations facilitated by CRM and collab...OneCafé: The future of membership organizations facilitated by CRM and collab...
OneCafé: The future of membership organizations facilitated by CRM and collab...
 
OneCafé: The new world of work and your organisation
OneCafé: The new world of work and your organisationOneCafé: The new world of work and your organisation
OneCafé: The new world of work and your organisation
 
Social Computing in your organization using SharePoint: challenges and benefits
Social Computing in your organization using SharePoint: challenges and benefitsSocial Computing in your organization using SharePoint: challenges and benefits
Social Computing in your organization using SharePoint: challenges and benefits
 
Windows Communication Foundation (WCF) Best Practices
Windows Communication Foundation (WCF) Best PracticesWindows Communication Foundation (WCF) Best Practices
Windows Communication Foundation (WCF) Best Practices
 
Wie is Orbit One Internet Solutions
Wie is Orbit One Internet SolutionsWie is Orbit One Internet Solutions
Wie is Orbit One Internet Solutions
 
Azure Umbraco workshop
Azure Umbraco workshopAzure Umbraco workshop
Azure Umbraco workshop
 
Marketing Automation in Dynamics CRM with ClickDimensions
Marketing Automation in Dynamics CRM with ClickDimensionsMarketing Automation in Dynamics CRM with ClickDimensions
Marketing Automation in Dynamics CRM with ClickDimensions
 
Office 365, is cloud right for your company?
Office 365, is cloud right for your company?Office 365, is cloud right for your company?
Office 365, is cloud right for your company?
 
Who is Orbit One internet solutions?
Who is Orbit One internet solutions?Who is Orbit One internet solutions?
Who is Orbit One internet solutions?
 
Azure and Umbraco CMS
Azure and Umbraco CMSAzure and Umbraco CMS
Azure and Umbraco CMS
 

Último

Benefits Of Flutter Compared To Other Frameworks
Benefits Of Flutter Compared To Other FrameworksBenefits Of Flutter Compared To Other Frameworks
Benefits Of Flutter Compared To Other FrameworksSoftradix Technologies
 
My Hashitalk Indonesia April 2024 Presentation
My Hashitalk Indonesia April 2024 PresentationMy Hashitalk Indonesia April 2024 Presentation
My Hashitalk Indonesia April 2024 PresentationRidwan Fadjar
 
Maximizing Board Effectiveness 2024 Webinar.pptx
Maximizing Board Effectiveness 2024 Webinar.pptxMaximizing Board Effectiveness 2024 Webinar.pptx
Maximizing Board Effectiveness 2024 Webinar.pptxOnBoard
 
08448380779 Call Girls In Diplomatic Enclave Women Seeking Men
08448380779 Call Girls In Diplomatic Enclave Women Seeking Men08448380779 Call Girls In Diplomatic Enclave Women Seeking Men
08448380779 Call Girls In Diplomatic Enclave Women Seeking MenDelhi Call girls
 
From Event to Action: Accelerate Your Decision Making with Real-Time Automation
From Event to Action: Accelerate Your Decision Making with Real-Time AutomationFrom Event to Action: Accelerate Your Decision Making with Real-Time Automation
From Event to Action: Accelerate Your Decision Making with Real-Time AutomationSafe Software
 
Kotlin Multiplatform & Compose Multiplatform - Starter kit for pragmatics
Kotlin Multiplatform & Compose Multiplatform - Starter kit for pragmaticsKotlin Multiplatform & Compose Multiplatform - Starter kit for pragmatics
Kotlin Multiplatform & Compose Multiplatform - Starter kit for pragmaticscarlostorres15106
 
How to Remove Document Management Hurdles with X-Docs?
How to Remove Document Management Hurdles with X-Docs?How to Remove Document Management Hurdles with X-Docs?
How to Remove Document Management Hurdles with X-Docs?XfilesPro
 
Swan(sea) Song – personal research during my six years at Swansea ... and bey...
Swan(sea) Song – personal research during my six years at Swansea ... and bey...Swan(sea) Song – personal research during my six years at Swansea ... and bey...
Swan(sea) Song – personal research during my six years at Swansea ... and bey...Alan Dix
 
08448380779 Call Girls In Civil Lines Women Seeking Men
08448380779 Call Girls In Civil Lines Women Seeking Men08448380779 Call Girls In Civil Lines Women Seeking Men
08448380779 Call Girls In Civil Lines Women Seeking MenDelhi Call girls
 
Unblocking The Main Thread Solving ANRs and Frozen Frames
Unblocking The Main Thread Solving ANRs and Frozen FramesUnblocking The Main Thread Solving ANRs and Frozen Frames
Unblocking The Main Thread Solving ANRs and Frozen FramesSinan KOZAK
 
Transforming Data Streams with Kafka Connect: An Introduction to Single Messa...
Transforming Data Streams with Kafka Connect: An Introduction to Single Messa...Transforming Data Streams with Kafka Connect: An Introduction to Single Messa...
Transforming Data Streams with Kafka Connect: An Introduction to Single Messa...HostedbyConfluent
 
Handwritten Text Recognition for manuscripts and early printed texts
Handwritten Text Recognition for manuscripts and early printed textsHandwritten Text Recognition for manuscripts and early printed texts
Handwritten Text Recognition for manuscripts and early printed textsMaria Levchenko
 
Enhancing Worker Digital Experience: A Hands-on Workshop for Partners
Enhancing Worker Digital Experience: A Hands-on Workshop for PartnersEnhancing Worker Digital Experience: A Hands-on Workshop for Partners
Enhancing Worker Digital Experience: A Hands-on Workshop for PartnersThousandEyes
 
Factors to Consider When Choosing Accounts Payable Services Providers.pptx
Factors to Consider When Choosing Accounts Payable Services Providers.pptxFactors to Consider When Choosing Accounts Payable Services Providers.pptx
Factors to Consider When Choosing Accounts Payable Services Providers.pptxKatpro Technologies
 
Salesforce Community Group Quito, Salesforce 101
Salesforce Community Group Quito, Salesforce 101Salesforce Community Group Quito, Salesforce 101
Salesforce Community Group Quito, Salesforce 101Paola De la Torre
 
Breaking the Kubernetes Kill Chain: Host Path Mount
Breaking the Kubernetes Kill Chain: Host Path MountBreaking the Kubernetes Kill Chain: Host Path Mount
Breaking the Kubernetes Kill Chain: Host Path MountPuma Security, LLC
 
SQL Database Design For Developers at php[tek] 2024
SQL Database Design For Developers at php[tek] 2024SQL Database Design For Developers at php[tek] 2024
SQL Database Design For Developers at php[tek] 2024Scott Keck-Warren
 
Key Features Of Token Development (1).pptx
Key  Features Of Token  Development (1).pptxKey  Features Of Token  Development (1).pptx
Key Features Of Token Development (1).pptxLBM Solutions
 
GenCyber Cyber Security Day Presentation
GenCyber Cyber Security Day PresentationGenCyber Cyber Security Day Presentation
GenCyber Cyber Security Day PresentationMichael W. Hawkins
 
Transcript: #StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
Transcript: #StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024Transcript: #StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
Transcript: #StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024BookNet Canada
 

Último (20)

Benefits Of Flutter Compared To Other Frameworks
Benefits Of Flutter Compared To Other FrameworksBenefits Of Flutter Compared To Other Frameworks
Benefits Of Flutter Compared To Other Frameworks
 
My Hashitalk Indonesia April 2024 Presentation
My Hashitalk Indonesia April 2024 PresentationMy Hashitalk Indonesia April 2024 Presentation
My Hashitalk Indonesia April 2024 Presentation
 
Maximizing Board Effectiveness 2024 Webinar.pptx
Maximizing Board Effectiveness 2024 Webinar.pptxMaximizing Board Effectiveness 2024 Webinar.pptx
Maximizing Board Effectiveness 2024 Webinar.pptx
 
08448380779 Call Girls In Diplomatic Enclave Women Seeking Men
08448380779 Call Girls In Diplomatic Enclave Women Seeking Men08448380779 Call Girls In Diplomatic Enclave Women Seeking Men
08448380779 Call Girls In Diplomatic Enclave Women Seeking Men
 
From Event to Action: Accelerate Your Decision Making with Real-Time Automation
From Event to Action: Accelerate Your Decision Making with Real-Time AutomationFrom Event to Action: Accelerate Your Decision Making with Real-Time Automation
From Event to Action: Accelerate Your Decision Making with Real-Time Automation
 
Kotlin Multiplatform & Compose Multiplatform - Starter kit for pragmatics
Kotlin Multiplatform & Compose Multiplatform - Starter kit for pragmaticsKotlin Multiplatform & Compose Multiplatform - Starter kit for pragmatics
Kotlin Multiplatform & Compose Multiplatform - Starter kit for pragmatics
 
How to Remove Document Management Hurdles with X-Docs?
How to Remove Document Management Hurdles with X-Docs?How to Remove Document Management Hurdles with X-Docs?
How to Remove Document Management Hurdles with X-Docs?
 
Swan(sea) Song – personal research during my six years at Swansea ... and bey...
Swan(sea) Song – personal research during my six years at Swansea ... and bey...Swan(sea) Song – personal research during my six years at Swansea ... and bey...
Swan(sea) Song – personal research during my six years at Swansea ... and bey...
 
08448380779 Call Girls In Civil Lines Women Seeking Men
08448380779 Call Girls In Civil Lines Women Seeking Men08448380779 Call Girls In Civil Lines Women Seeking Men
08448380779 Call Girls In Civil Lines Women Seeking Men
 
Unblocking The Main Thread Solving ANRs and Frozen Frames
Unblocking The Main Thread Solving ANRs and Frozen FramesUnblocking The Main Thread Solving ANRs and Frozen Frames
Unblocking The Main Thread Solving ANRs and Frozen Frames
 
Transforming Data Streams with Kafka Connect: An Introduction to Single Messa...
Transforming Data Streams with Kafka Connect: An Introduction to Single Messa...Transforming Data Streams with Kafka Connect: An Introduction to Single Messa...
Transforming Data Streams with Kafka Connect: An Introduction to Single Messa...
 
Handwritten Text Recognition for manuscripts and early printed texts
Handwritten Text Recognition for manuscripts and early printed textsHandwritten Text Recognition for manuscripts and early printed texts
Handwritten Text Recognition for manuscripts and early printed texts
 
Enhancing Worker Digital Experience: A Hands-on Workshop for Partners
Enhancing Worker Digital Experience: A Hands-on Workshop for PartnersEnhancing Worker Digital Experience: A Hands-on Workshop for Partners
Enhancing Worker Digital Experience: A Hands-on Workshop for Partners
 
Factors to Consider When Choosing Accounts Payable Services Providers.pptx
Factors to Consider When Choosing Accounts Payable Services Providers.pptxFactors to Consider When Choosing Accounts Payable Services Providers.pptx
Factors to Consider When Choosing Accounts Payable Services Providers.pptx
 
Salesforce Community Group Quito, Salesforce 101
Salesforce Community Group Quito, Salesforce 101Salesforce Community Group Quito, Salesforce 101
Salesforce Community Group Quito, Salesforce 101
 
Breaking the Kubernetes Kill Chain: Host Path Mount
Breaking the Kubernetes Kill Chain: Host Path MountBreaking the Kubernetes Kill Chain: Host Path Mount
Breaking the Kubernetes Kill Chain: Host Path Mount
 
SQL Database Design For Developers at php[tek] 2024
SQL Database Design For Developers at php[tek] 2024SQL Database Design For Developers at php[tek] 2024
SQL Database Design For Developers at php[tek] 2024
 
Key Features Of Token Development (1).pptx
Key  Features Of Token  Development (1).pptxKey  Features Of Token  Development (1).pptx
Key Features Of Token Development (1).pptx
 
GenCyber Cyber Security Day Presentation
GenCyber Cyber Security Day PresentationGenCyber Cyber Security Day Presentation
GenCyber Cyber Security Day Presentation
 
Transcript: #StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
Transcript: #StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024Transcript: #StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
Transcript: #StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
 

Windows PowerShell

  • 1. www.orbitone.com Raas van Gaverestraat 83 B-9000 GENT, Belgium E-mail info@orbitone.com Website www.orbitone.com Tel. +32 9 265 74 20 Fax +32 9 265 74 10 VAT BE 456.457.353 Bank 442-7059001-50 (KBC) 17 December, 2009 Windows PowerShell 2.0, By Tom Pester
  • 2. 17 December, 2009 Windows PowerShell 2.0, By Tom Pester What is PowerShell ?
  • 3. 17 December, 2009 Windows PowerShell 2.0, By Tom Pester
  • 4. 17 December, 2009 Windows PowerShell 2.0, By Tom Pester
  • 5. 17 December, 2009 Windows PowerShell 2.0, By Tom Pester
  • 6. 17 December, 2009 Windows PowerShell 2.0, By Tom Pester Why PowerShell?  PowerShell was designed to do for Windows what the UNIX shells dooes for UNIX: provide a powerful, well-integrated command-line experience for the operation system. But better :)  Unlike most scripting languages, the basic object model for PowerShell is .NET  PowerShell has full access to all of the types in the .NET framework and not a few simple objects  Windows is mostly managed through objects comming from MI (WINDOWS MANAGEMENT INFRASTRUCTURE) COM (COMPONENT OBJECT MODEL) and .NET  As Windows moves from the desktop to server farms or application servers (like print, DNS and LDAP services,etc.) command-line automation becomes a fundamental requirement.
  • 7. 17 December, 2009 Windows PowerShell 2.0, By Tom Pester Who has PowerShell?  Its installed out of the box on Windows 7 and Windows Server 2008 R2.  It has also been released for older platforms: Windows XP SP3 Windows Server 2003 SP2 Windows Vista SP1 and Windows Server 2008
  • 8. 17 December, 2009 Windows PowerShell 2.0, By Tom Pester PowerShell Concepts  - Cmdlets These are built-in commands written in a .NET language like C# or Visual Basic. Typically Developers can extend the set of cmdlets by writing and loading PowerShell snap-ins.  Functions Functions are commands written in the PowerShell language. These can be developed without an IDE like Visual Studio by sysadmins and devs  Scripts Scripts are textfiles on disk with a .ps1 extension  Applications (aka native commands) Applications are existing windows programs.
  • 9. 17 December, 2009 Windows PowerShell 2.0, By Tom Pester Providers  Most applications have some sort of "hierarchical" data store  Example are Exchange, Active Directory, SharePoint, SQL Server  for example in sql server multiple instances of sql server can be installed  Once you are in an instance you can select jobs, roles, etc or databases  In a specific database you can choose triggers, logfiles, etc and tables  Providers in PowerShell allow data to be presented from different data stores in a consistent fashion to existing cmdlets.  There are 7 providers built into PowerShell (Alias, Environment, File System, Function, Registry, Variable, and Certificate).
  • 10. 17 December, 2009 Windows PowerShell 2.0, By Tom Pester Pipeline  UNIX scripting shells also use the concept of a pipeline.  This is extremely powerful, but suffers from the disadvantage that, in most cases, the pipelined data is just raw text.  This means prayer-based parsing. Rather than passing text, PowerShell passes .NET objects. That means a cmdlet can use .NET reflection to look inside what is getting passed, and know what's being passed
  • 11. 17 December, 2009 Windows PowerShell 2.0, By Tom Pester The pipeline
  • 12. 17 December, 2009 Windows PowerShell 2.0, By Tom Pester DEMO ============================================================ ==== DEMO START based on video 1 (http://www.idera.com/Promo/Practical-PowerShell/) ============================================================ *. To see everything PS can do run > get-command *. to get all the manuals > help *. get a list of all process : > get-process *. Piping | Default there is "Out-Default" , per defalt it outputs everything as text > get-process | out-default *. Cleaning the scree > cls *. Lets get the top 10 memory consuming processess > get-process | sort vm -descending | select -first 10 *. How did I know that vm was a property of a Service Object Get-Service | get-member * Comments in Powershell, block <# Now is the time to use PowerShell #> * Comments in Powershell, line # Now # is # the * Lets tweak the output get-process | format-table name,id,responding,path => some columns are cut * show help for format-table * lets do something about the cut columns get-process | format-table name,id,responding,path -autosize -wrap * to learn about autosize and wrap For more information, type: > get-help Format-Table -detailed * Focused help > get-help Format-Table -examples * lets write the report to a textfile > Get-Process | Format-table name,id | Out-File c:temptest.txt => Not that we still use the pipe symbol and not > as we would do in good old dos * Lets peek inside the event log > Get-EventLog security -newest 50 * And take a look at it in Excel > Get-EventLog security -newest 50 | Export-Csv c:temptest.csv
  • 13. 17 December, 2009 Windows PowerShell 2.0, By Tom Pester Runspaces: Windows PowerShell hosting mechanism  The Windows PowerShell runtime can be embedded inside other applications (jargon: in a PowerShell "runspace").  These applications then leverage Windows PowerShell functionality to implement certain operations  This capability has been utilized by Microsoft Exchange Server 2007 : As for Exchange Server 2007, the entire server was built with Windows PowerShell in mind. In fact, the Exchange Management Interface was designed in such a way that all the mouse-clicks and menu-clicks are actually calls to Exchange-PowerShell cmdlets.  This is Microsoft's direction by defining this in their common engineering criteria  In the future all Microsoft Applications running on the Windows platform are to be PowerShell aware.  3th Party providers bundle PowerShell Support with their products as PS Snap-ins
  • 14. 17 December, 2009 Windows PowerShell 2.0, By Tom Pester PowerShell enabled applications
  • 15. 17 December, 2009 Windows PowerShell 2.0, By Tom Pester PowerShell enabled applications Application Version Cmdlets Provider Management GUI Exchange Server 2007 402 Yes Yes Windows Server 2008 Yes Yes No Microsoft SQL Server 2008 Yes Yes No System Center Operations Manager 2007 74 Yes No System Center Virtual Machine Manager 2007 Yes Yes Yes System Center Data Protection Manager 2007 Yes No No Windows Compute Cluster Server 2007 Yes Yes No Microsoft Transporter Suite for Lotus Domino[37] 08.02.0012 47 No No Microsoft PowerTools for Open XML[38] 1.0 33 No No IBM WebSphere MQ[39] 6.0.2.2 44 No No Quest Management Shell for Active Directory[40] 1.1 40 No No Special Operations Software Specops Command[41] 1.0 Yes No Yes VMware Infrastructure Toolkit[42] 1.5 157 No No Internet Information Services[43] 7.0 54 Yes No Ensim Unify Enterprise Edition[44] 1.6 Yes No Yes Windows 7 Troubleshooting Center[45] 6.1 Yes No Yes Microsoft Deployment Toolkit 2010 Yes No No [edit] SnapIns and hosts
  • 16. 17 December, 2009 Windows PowerShell 2.0, By Tom Pester A top overview of the features introduced in PowerShell 2  PowerShell Remoting: Using WS-Management, PowerShell 2.0 allows scripts and cmdlets to be invoked on a remote machine or a large set of remote machines.  Background Jobs: Also called a PSJob, it allows a command sequence (script) or pipeline to be invoked asynchronously. Jobs can be run on the local machine or on multiple remote machines.  Transactions: Enable cmdlet and provider developers to perform transacted operations.  Script Debugging: It allows breakpoints to be set in a PowerShell script or function.  Eventing: This feature allows listening, forwarding, and acting on management and system events.  Network File Transfer: Native support for prioritized, throttled, and asynchronous transfer of files between machines using the Background Intelligent Transfer Service (BITS).
  • 17. 17 December, 2009 Windows PowerShell 2.0, By Tom Pester Consistency and Discoverablity  One of the great things of PS is the consistency and discoverablity.  If you switch from one domain to another, lets say SQL Server to Active Directory, you can predict what you can ask PowerShell of AD beceause you are used to SQL Server
  • 18. 17 December, 2009 Windows PowerShell 2.0, By Tom Pester Save Tasks and Schedule  A task can be saved as a script and reused at a later time or even scheduled. For example, if you are responsible for a server park of 10 (or 1000) servers and you are interested in the temperature you can write out the script once, save it as a script and give it a list of the servers you are interested in. When new servers are added you just update this list and it will give you brief report of the data you are interested in. IMO graphical user interfaces have their place but the power you get if you can do everying from 1 central place is not to be underestimated.
  • 19. 17 December, 2009 Windows PowerShell 2.0, By Tom Pester Why PowerShell? Why not C#?  First of all C# is not a scripting language. YOu need a compiler to make use of C#.  If you consider a system administrator managing 10+ web servers, he/she will never install 2 gigabytes of Visual Studio on every server to edit his C# utility.  If you have any utility that you are running on production system and want to make some minor changes then you need to go back to your desktop where you have your source code preferably Visual Studio installed, edit your C# program, recompile it and copy it back to production system.  If you really want to write actual code in C#, you need to have some knowledge of OOPs (object oriented programming) concept (how to define class? what are static methods?)  Even if you are writing a simple program you need to write at least main method? What are class access rules, why to make this function public, or static etc?
  • 20. 17 December, 2009 Windows PowerShell 2.0, By Tom Pester Sysadmin Challenges  To manage a network today, Administrators face a range of challenges with respect to tools: Wide range: Admins are required to be experts in a huge range of tools and scripts. That’s because, thus far, no one tool, does everything. GUI Scalability: a GUI is a great tool for performing a single operation on just one computer, but it can be slow and tedious if you need to perform that same operation on 1,000 systems.
  • 21. 17 December, 2009 Windows PowerShell 2.0, By Tom Pester Starting up PowerShell from SQL Server 2008 This is a locked down version of PowerShell so it exposes reproducible behavior.
  • 22. 17 December, 2009 Windows PowerShell 2.0, By Tom Pester * the "whatif" feature : PS> get-process p* | stop-process - whatif
  • 23. 17 December, 2009 Windows PowerShell 2.0, By Tom Pester SharePoint 2010  STSADM is legacy, PowerShell is the replacement: http://dmitrysotnikov.wordpress.com/2009/10/19/sharepoint-2010-cmdlet-reference/
  • 24. 17 December, 2009 Windows PowerShell 2.0, By Tom Pester Recommended books & resources  Publicly available : http://powershell.com/cs/blogs/ebook/  Publically available : free : http://www.idera.com/Promo/Practical-PowerShell/  Nice video on Powershell in SharePoint 2010 http://technet.microsoft.com/en- us/sharepoint/ee518673.aspx  MSDN http://msdn.microsoft.com/en-us/library/cc281954.aspx  Start with http://www.amazon.com/Microsoft-PowerShell-Programming-Absolute- Beginner/dp/1598638998/ref=sr_1_2?ie=UTF8&s=books&qid=1258411028&sr=8-2  Become an expert with http://www.amazon.com/Windows-Powershell-Action-Bruce- Payette/dp/1932394907/ref=sr_1_3?ie=UTF8&s=books&qid=1258411028&sr=8-3  Microsoft SQL Server 2008 Administration with Windows PowerShell http://www.amazon.com/Microsoft-Administration-Windows-Power- ShellProgrammer/dp/0470477288/ref=sr_1_14?ie=UTF8&s=books&qid=1258411028&sr=8-14  Managing VMware Infrastructure with Windows PowerShell TFM http://www.amazon.com/Managing-VMware-Infrastructure-Windows- PowerShell/dp/0982131402/ref=sr_1_1?ie=UTF8&s=books&qid=1258411111&sr=8-1
  • 25. www.orbitone.com Windows PowerShell 2.0, By Tom Pester 17 December, 2009