Welcome to ThePowerShellGuy.com Sign in | Join | Help

Browse by Tags

move-blog

I've moved the blog to my own domain. No further content will be updated here. The articles will remain for reference until I get all of them reposted to the new site. Here's the new link: http://www.skyeagle.net/ Gaurhoth
Posted by Gaurhoth | (Comments Off)

Games 2008 Advanced Event 1 Solution

In next few posts, I'll be posting my solution for the Winter Scripting Games of 2008. Some I'll add comments. Some I won't :) I found using Regex patterns far easier than the brute force method used by the Scripting Guys. See the code below: $number

Scripting Games Calendar Sneak peak

My Calendar for Advanced Event 4
Posted by Gaurhoth | (Comments Off)

Attachment(s): cal.jpg

An example of how to use New-TaskPool

Those that have been reading my blog for awhile may remember the New-Taskpool script. Basically the script allows me to have multiple runspaces running simultaneously. If we give each runspace an object and a scriptblock... we can run through time consuming
Posted by Gaurhoth | (Comments Off)
Attachment(s): New-TaskPool.txt

Get-NBTHosts

I've been a long time user of a very useful cmd line utility called NBTScan . NBTScan is similar to the Windows builtin cmd line utility NBTSTAT, but can operate on a range of IP addresses instead of a single IP. Using NBTscan, you can get a list of Windows
Posted by Gaurhoth | (Comments Off)
Filed under: ,

New-HtmlHelp from VMWare modification

If you haven't already heard of New-HtmlHelp, you should visit http://blogs.vmware.com/vipowershell/2007/09/new-htmlhelp.html . One of their team members posted an nifty function to create a set of HTML pages from available Powershell Cmdlets documentation.

Using Powershell to Mail-Enable an AD User without CDOEXM

Over on microsoft.public.windows.powershell, it’s been asked how to mail-enable an AD user in an Exchange 2003 Environment. The MS supported way involves CDOEXM (part of Exchange System Manager) which seems to be rather difficult to use from powershell.

New-TaskPool v0.8 Bug Fix

It’s been a very long time since my last post. Excuses include an insane job situation involving a recent manager's departure as well as my recent purchase of a new home that has occupied most every free minute. So with that out of the way, here’s an
Posted by Gaurhoth | (Comments Off)
Attachment(s): New-TaskPool.txt

New-TaskPool.ps1 - Threading the Powershell way Pt 2

I’ve made a few modifications to New-TaskPool. My original script couldn’t easily be loaded into your profile. You had to specify the script file ( .\New-TaskPool.ps1 ). This quickly became a problem as I would invariably be in the wrong folder and typing
Posted by Gaurhoth | (Comments Off)
Attachment(s): New-TaskPool.txt

Finding a Range of IP addresses

A recent question in Microsoft.public.windows.powershell asked for ideas on working with a range of IP addresses expressed in CIDR notation (192.168.1.0/24). The intent is to get a list of IP addresses inside the range. I posted a small sample in the
Posted by Gaurhoth | (Comments Off)
Filed under: , ,

Comparing Win32_PingStatus vs [System.Net.NetworkInformation.Ping]

Back again with another comparison between .NET and WMI performance. While WMI can be very useful and often the only way to accomplish some remote oriented tasks, you will rarely hear anyone that has worked with WMI classes for long brag about its performance.
Posted by Gaurhoth | (Comments Off)
Filed under: , ,

New-TaskPool.ps1 - Threading the Powershell way

For a while now I've been trying to perfect a script that will let me simulate having multiple threads in powershell. Here's what I've come up with. The entire script is attached to the post. I'll only be discussing a few bits and pieces today. Feel free
Posted by Gaurhoth | (Comments Off)
Filed under: ,

Attachment(s): new-taskpool.txt

"Gaurhoth's Powershell Thoughts" | move-blog

I wanted to start with a thanks to /\/\o\/\/ for letting me invade his site and set up my own blog here. I've posted the occassional blog entry at http://gaurhothw.spaces.live.com/ but wasn't happy with the interface for a number of uninteresting reasons.
Posted by Gaurhoth | (Comments Off)

Querying date based Active Directory fields

Another “from usenet to blog” entry. Someone wanted to a list of all users in their Active Directory created after a specific day. Like most AD related tasks, this is fairly easy in Powershell, but you do have to be aware of one tricky piece. LDAP queries

Listing Remote Services without using WMI

WMI seems to get recommended for most "remote" queries in powershell. This is due in large part because the get-wmiobject cmdlet includes built in support for querying remote machines. However, I've found that WMI can be slow and whenever I find a dotnet
Posted by Gaurhoth | (Comments Off)
Filed under: , , ,
More Posts Next page »