mstaint.com Less paint more taint!


19
Nov/09
0

Microsoft Kerberos Awesomeness!

So anybody that has worked on a large domain has probably run into this issue before.

When joining a machine to a windows domain, there is the possibility that the following error can occur:

Not enough storage is available to complete this operation.

Now now...I know what you may be thinking. "I have a 500Gb hard drive, what the hell is this talking about?" Unfortunately, it is not referring to the space on your machine, or the space on the server for that matter. This error message is referring to the amount of tokens or "group memberships" exceeds the default max bytes of data to be included in a kerberos packet. This size can vary depending on the operating system, but there is a way to fix this problem. Adding the following registry key will force the maximum size of the data to be set very large so we don't have this problem.


[HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\Lsa\Kerberos\Parameters]
"MaxTokenSize"=dword:0000ffff

In decimal, that value is 65,535 if you would like to do it that way. Once you set this value, restart your machine and you should be all set. No more errors.

1
Sep/09
0

Detect empty arrays in VBScript

So for those of you who have tried to determine the size of an array in VBScript and have failed this may be for you. I recently needed to be able to determine if an array was size 0 in VBscript and was running into some issues.

VBScript does not have a .SizeOf() function that you can execute on an array to determine it's size. Normally what I would do in most other languages is something like the following:


if sizeof(array) = 0
{
//do something here
}

To accomplish this in VBScript you need to do the following.


If IsNull(array) Then
//Do Something Here
End If

Why can't you do things like the rest of the world VBScript!!!!! That is all.

30
Jul/09
2

Windows Update monitoring with Xymon

Xymon is a pretty cool and free system and network monitoring solution. Some of you may know it as Hobbitmon as it recently was forced to change it's name because of some lawsuit I guess.

For those of you who haven't heard of it before check it out over at http://hobbitmon.sourceforge.net/. We use it currently at RIT to monitor a few hundred systems ranging from Windows to VMWare and Solaris. It basically does it all.

Using the BBWin client over at http://bbwin.sourceforge.net/ we are able to monitor anything and everything that you can script in Windows. Whether it be monitoring drive and memory usage right on down to parsing log files for specific events...if you can script it, it can be monitored.

What I ended up doing was writing a VBScript that would be executed by BBWin and would then use the Windows Update API built into windows to check and then create a report about critical patches not being installed or active (the patch installed but system not rebooted).

You can download the script on my Google Code at http://code.google.com/p/mstaint/. Installation instructions are included in the zip file download.

Drop me an email if you have a feature request for something you would like to see added to it.

Enjoy.