Podcast

Episode 134 – Trevor Sullivan on WMI Events in PowerShell

Jonathan Walz
3 min read
Share:

Listen to this Episode

Audio available

A Podcast about Windows PowerShell. Listen:

In This Episode {#tiap}

Tonight on the PowerScripting Podcast, we talk to Trevor Sullivan about working with WMI events in PowerShell

News

**

Interview **

This segment is brought to you by SAPIEN Technologies, makers of PrimalScript and PrimalForms.

Chatroom Buzz:

  • so can we set up events on things like usb pen plugged in ?

  • Can I use ActiveScript consumer to wrap PowerShell in VBScript? Is that impelemented..?

  • can we reuse filters? i mean, can we use the same filter for multiple bindings?

  • when can we see a functional command-line consumer?

  • new subject. ASk him about his guest blog for HSg next week. something about dynamic method invocation

When are you going to integrate the module with PowerGUI?

  • or may be a nice GUI to list and bind filters/consumers..!

  • ##When a mount point suddenly disconnects without warning?

Hero/Ability: Shoot lightning from hands

** Resources **
This segment brought to you by [ServerFault.com][10]{#u8o0}

  • [Ravi explores WMI Timer Events][11]{#ku5l}
  • [Brandon recommends task-based cmdlets over methods][12]{#xx.b}
  • System Center Tech Blog - [Get Nested Group Members][13]{#v-in}
  • Greg Milner sent us this: [Create an EverNote export file with PowerShell][14]{#ts_e}
  • [PowerChumby!][15]{#t..2}
  • From LucD: [Hitchhiker’s Guide to Get-EsxTop][16]{#vqat}
  • From the PowerCLI  blog: [Managing vSphere Alarms with PowerCLI][17]{#pi6f}

 

Tips

  • Tome sent us a tip about [preventing user profile creation in a remote PSSession][18]{#zv1.}
  • from PowerShell.com: [Use powershell jobs to ping an entire subnet in seconds][19]{#zr6a}!

** Feedback **

From time to time I pick up new small but powerful features in PowerShell, here is a handy one:

Did you know you can use wildcards in combination with tab-completion? Both with verbs and nouns? A few examples:

rec-j* resolves to Receive-Job*

set-quick resolves to Set-WSManQuickConfig

*-computer resolves to Add-Computer. Cycle through several times and you can see all cmdlets with “computer” in it`s noun.

*Handy when you remember just parts of the cmdlet-name, typing a hard-to-spell cmdlet name"¦or even just being lazy *

_ _

Best Regards

**

*Jan *

**

[5]: http://concentratedtech.com/training/public-powershell.php “5-day “PowerShell Retreat” class” [6]: http://blog.sapien.com/index.php/2010/12/09/ipowershell-2-1-107-released-into-the-wild/?utm_source=feedburner&utm_medium=feed&utm_campaign=Feed:+SapienBlog+(SAPIEN+Technologies+Blog) “released a new version of iPowerShell” [7]: http://blogs.technet.com/b/heyscriptingguy/archive/2010/12/08/use-a-powershell-module-to-work-with-wmi-permanent-events.aspx “Use a PowerShell Module to Work with WMI Permanent Events” [8]: http://blogs.technet.com/b/heyscriptingguy/archive/2010/12/09/use-the-powershell-wmi-event-module-to-quickly-monitor-events.aspx “Use the PowerShell WMI Event Module to Quickly Monitor Events” [9]: http://www.primaltools.com/downloads/communitytools/ “Sapien WMI Explorer” [10]: http://serverfault.com/ “ServerFault.com” [11]: http://www.ravichaganti.com/blog/?p=1751 “Ravi explores WMI Timer Events” [12]: http://searchwindowsserver.techtarget.com/tip/A-task-based-approach-to-PowerShell-cmdlet-design “Brandon recommends task-based cmdlets over methods” [13]: http://www.myitforum.com/myITToolbar/frame-click.asp?url=http://michielw.blogspot.com/2010/12/scom-get-nested-group-members.html “Get Nested Group Members” [14]: http://forum.evernote.com/phpbb/viewtopic.php?f=53&t=20645 “Create an EverNote export file with PowerShell” [15]: http://powertoe.wordpress.com/2010/12/06/powerchumby-1-0-released/ “PowerChumby!” [16]: http://www.lucd.info/2010/12/03/hitchhikers-guide-to-get-esxtop-part-1/ “Hitchhiker’s Guide to Get-EsxTop” [17]: http://blogs.vmware.com/vipowershell/2010/12/managing-vsphere-alarms-with-powercli.html “Managing vSphere Alarms with PowerCLI” [18]: http://social.technet.microsoft.com/Forums/en-US/winserverpowershell/thread/51d54fa4-4e6e-4f3a-bb41-710d87bf5e58 “preventing user profile creation in a remote PSSession” [19]: http://powershell.com/cs/blogs/tips/archive/2010/12/07/finding-systems-online-fast.aspx “Use powershell jobs to ping an entire subnet in seconds”