introduction to powershell
DESCRIPTION
Gave this presentation in May, 2010 at Wipro internal KM sessions. Was going through my blog and found this @ http://blog.ankitk.com/2010/05/my-powershell-presentation/ :)TRANSCRIPT
© 2009 Wipro Ltd - Confidential2 © 2009 Wipro Ltd - Confidential2
Before We BeginHow Many of you have seen the blockbuster “Karan-Arjun”?
How many of you believe in ‘Reincarnation’?
The Very basic difference between Unix and Windows…
TP 50TP 49
91% Market Share
© 2009 Wipro Ltd - Confidential3 © 2009 Wipro Ltd - Confidential3
GUI Rocks, Command Line is hell!
OS Got GUI, Now time for Apps!Why GUI Rocks? Easy Navigation Simpler depiction of System data, files, folders No need to memorize lengthy commands and their
bunch of parameters No significant competency required, even a layman
can work on it.
So is it a panacea?
© 2009 Wipro Ltd - Confidential4 © 2009 Wipro Ltd - Confidential4
GUI ≠ Panacea for allMy Bro IT Admin @ Wipro
Wanna Just GUI!!
“Mixed Approach”
MUSIC
SONGS
INTERNET
YouTube
Chatting
Twitter!!!
Scripts make Life
Easier!
GAMES
© 2009 Wipro Ltd - Confidential5 © 2009 Wipro Ltd - Confidential5
Scripting
Not this ScriptPHP
Perl VBScript
TCL -TKAwk
ShellJScri
pt
JavaScript
Sid
Is VBScript OK? Its COM based but softwares are .NET
based No OOPS!! MS Stopped its further development – No
new releases!!We need a new language!!
© 2009 Wipro Ltd - Confidential6 © 2009 Wipro Ltd - Confidential6
Need of the hour: PowerShellWorld needs a brand new scripting language:.NET based OOPS EnabledSimple to learn Complete language“Windows PowerShell is Exactly what we are looking for!”
• Already in-built in Windows 7 & Server
2K8 (its R2)
• Free download for XP, Vista and WS03
• PreReq for Downlevel OS: .NET 2.0 SP1
• Current Version: 2.0
© 2009 Wipro Ltd - Confidential7 © 2009 Wipro Ltd - Confidential7
PowerShell: Basics for Dummies
PowerShell Completely Based on .NET
What it means??
Based on .NET framework You can use a major portion
of .NET framework in PS. Not limited to cmd, even you
can develop a GUI based program too!!
Backward compatible with old cmd
(Reincarnation??)
© 2009 Wipro Ltd - Confidential8 © 2009 Wipro Ltd - Confidential8
PowerShell: Basics for Dummies
Don’t call Commands, Call them cmdlets
cmdlet
They are not .exe or .com based binaries, they
are .NET classes!!
They have unique naming convention
in verb-noun format! Easy to
remember
Set-date
Get-
Service
Get-ChildItemRemove-
item
© 2009 Wipro Ltd - Confidential9 © 2009 Wipro Ltd - Confidential9
PowerShell: Basics for Dummies
Supports Pipelining
dir c: | find “.exe”
Support Remote Execution
Has a Good GUI-EditorPowerShell ISE
Support a command line based Intelli-sense just like
Visual Studio
All the main programming features like Array, files, loops ,
logic operator etc
© 2009 Wipro Ltd - Confidential10 © 2009 Wipro Ltd - Confidential10
PowerShell: Is it just another Scripting language
Its different!!!
Just like traditional scripting languages, it does the basic scripting tasksSo is it just another Language??
Almost every latest version of server apps like Exchange server, SQL server, SharePoint have PS based management environment
Even 3rd party apps now a days are having their own PS cmdlets!!
It’s the future language for Server Admins & Power Users.
In the future, PowerShell become OmniPresent
© 2009 Wipro Ltd - Confidential12 © 2009 Wipro Ltd - Confidential12
• Microsoft Learning portal http://
www.microsoft.com/learning/en/us/course.aspx?ID=50025a
• PowerShell Script Center
http://technet.microsoft.com/en-us/scriptcenter/
• PowerShell Community
http://www.powershell.com/cs/
More about PowerShell
© 2009 Wipro Ltd - Confidential13
Queries
tweet me : @ankitwww
© 2009 Wipro Ltd - Confidential
ThanksClosing Line:PowerShell = emPOWERing the old cmd SHELL with the help of .NET for mainly Server Professionals