Teched 2012 就是为了改变脚本世界

11
Powershell 3.0 就是为了改变脚本世界 张诚 微软数据中心TSP @MVP张诚

Transcript of Teched 2012 就是为了改变脚本世界

Page 1: Teched 2012 就是为了改变脚本世界

Powershell 3.0就是为了改变脚本世界

张诚微软数据中心TSP@MVP张诚

Page 2: Teched 2012 就是为了改变脚本世界

我与Powershell

Page 3: Teched 2012 就是为了改变脚本世界

主题

• 脚本解决的问题

• Powershell前世今生

• Powershell和自动化

Page 4: Teched 2012 就是为了改变脚本世界

• Windows PowerShell 1.0– 100+ cmdlets and a powerful scripting language– Access to WMI objects on remote computers– Extensible through PSSnapins and managed code

• Windows PowerShell 2.0– 200+ cmdlets– PowerShell remoting (implicit and explicit)– Extensible through modules and PowerShell script– Background jobs– Integrated scripting environment

Page 5: Teched 2012 就是为了改变脚本世界

Windows PowerShell 3.0 Themes

Page 6: Teched 2012 就是为了改变脚本世界

Powershell For Hyper-V

Page 7: Teched 2012 就是为了改变脚本世界

一鱼三吃

• $userName = Read-Host

• $pwd = Read-Host -AsSecureString

• Import-Module ActiveDirectory

• New-ADUser -Name $userName -AccountPassword $pwd

Page 8: Teched 2012 就是为了改变脚本世界

未来能力:批量自动化

• 脚本实现了批量操作

• Orchestrator实现了自动化

Page 9: Teched 2012 就是为了改变脚本世界
Page 10: Teched 2012 就是为了改变脚本世界
Page 11: Teched 2012 就是为了改变脚本世界