2011-08-26

On why accurate testing conditions are vital

So, I was just reading an article detailing the account of how Osama bin Laden was killed. You can read it for yourself here. What struck me in reading it was when they explained why the helicopter crashed into the courtyard on initial entry. To make a long story short, when they set up a simulation for the Navy SEALs to practice on, the fence was chain link. The actual compound had solid walls. The problem is that the former allows the rotor wash to dissipate. The latter doesn't, and it causes interference with the helicopter. So, the testing conditions and the actual conditions were not the same. As a result, the live run didn't go like the tests had. Fortunately, the pilot was quick on his feet and was able to salvage the mission.

We as IT professionals can learn from this. When you test something, try your best to make the testing environment as much like the production environment as possible. OS patch level, size, quality of data, etc can all affect performance in one way or another. You can try to predict how, but often times it's just easier to simulate your situation as accurately as possible. Because if you don't, you may find yourself crashing into a wall. Will you be able to recover?

2011-08-12

Converting between SID and account name

In a previous post, I mentioned the need to convert between Windows SID and the account name. A little Google-ing helped me create the following little powershell script arose

param(
    [string] $sid
)
$objSID = New-Object System.Security.Principal.SecurityIdentifier ( $sid )
$User = $objSID.Translate( [System.Security.Principal.NTAccount] )
$User.Value


Save that in a file (I called mine "account_from_sid.ps1"). Now, you can say "account_from_sid " and get an account name back. Handy!

I ♥ WinDirStat

So, part of my duties as an administrator entail being a janitor. Specifically, cleaning up files when a disk fills up. In the interest of working smarter and not harder, I like to use WinDirStat to find me the heavy hitters quickly. I especially like that it shows me what's in people's recycle bin (which, can we disable that universally on servers please?). The problem is that it gives the recycle bin's owner by SID. That's less than helpful when you need to find someone to put the hurt on have a conversation with. In a future post, I'll show you the powershell script that I came up with to do the conversion.