Sunday, May 31, 2009

SQL 2005 Install error

There was an unexpected failure during the setup wizard. You may review the setup logs and/or click the help button for more information.

This is caused when you downloaded your install files. After unzipping them you need to place the installation files in to the respective folders:
Servers
Tools

This allows the installation to find the needed files which are hard coded into the installation to look in ./Tools for the components.

http://support.microsoft.com/kb/916760

Wednesday, May 27, 2009

IE8 Enable Compatibility Mode

Recently I began testing out IE8 in our environment to ensure that everything would work properly on it. I quickly found that our Citrix Access Gateway didn't display properly. Not a big deal for most users, but... well you know.

http://support.microsoft.com/kb/956197/

Group Policy Under Computers
Administrative Templates/Windows Components/Internet Explorer/Compatibility View
* Use Policy List of Internet Explorer 7 sites *

Now it doesn't even matter. They'll never know the difference on corporate computers.

Sunday, May 24, 2009

Disable IE8 In-Private Feature

With the release of IE8 comes a new feature that allows a user to turn on "In-Private" browsing. This makes the following true:
1. The browsing history for the session is not stored.
2. Temp Internet Files / Cookies are removed.
3. Searches / Addresses are not saved
4. Passwords are deleted

This is great for that loved one that is getting the perfect gift and doesn't want their girl/guy to accidently get clues as to what the present might be.

BUT the likely use of this feature has coined it the term "Porn-Mode". There are very few reasons that a corporate network should have need of the In-Private feature and it should be locked down.

Install IE8 on a domain controller
In Group Policy make a setting that applies to all computers (ie Default Domain Policy).
Machine/Admin Templates/Windows Components/Internet Explorer/InPrivate/Turn off In-Private Browsing

For home users this can (and should) be disabled especially if you have kids.

Click Start then click Run. Type gpedit.msc and hit Enter
User Configuration > Administrative Templates > Windows Components > Internet Explorer > InPrivate
Here you will see the option "Turn off InPrivate Browsing"
Double click the policy and set to "Enabled" to disable InPrivate Browsing
Close the Group Policy window and open IE8 and ensure that it is disabled.

(Click to enlarge)


Or

via the registry: (Making changes to your computers registry can cause unrepairable damage if done incorrectly)
HKLM/Software/Policies/Microsoft/Internet Explorer/Privacy/EnableInPrivateBrowsing
You may have to create the keys "Internet Explorer", "Privacy", or the Dword "EnableInPrivateBrowsing" with a value of 0 to disable.

Thursday, May 21, 2009

Remote View Internet Explorer History

On several occasions I've found it necessary to view a users IE History. Sure I can login as the user and open IE and view the history, but I prefer the remote route.

I found this tool which allows you to view history folders of users. You can even use a UNC path to the users history folder. I've found it very useful for determing what site a user is on when they found spyware, viruses, etc.

http://www.cleanersoft.com/iehistory/iehistory.htm

Sunday, May 17, 2009

Block IE8

Here's the quick key to block IE 8 from installing before you are ready for it.

HKEY_LOCAL_MACHINE\Software\Microsoft\Internet Explorer\Setup\8.0

DWORD - DoNotAllowIE80 - set to 1 to prevent

Monday, May 11, 2009

NumLock

NumLock can be turned on by default several ways. This is normally done in the BIOS, but in some circumstances I've found that this isn't an option or doesn't work (usually on older systems).

Another method is the force it in the registry.

[HKEY_USERS\.Default\Control Panel\Keyboard]
"InitialKeyboardIndicators"="2"

Thursday, May 7, 2009

Registry Changes via Regedit or VBScript

Recently I decided to make a new batch file that would automate setting up a new workstation that is installed fresh from the disks to prep it for sysprep/imaging. During this process I found that I needed to make several Registry changes. I found 2 ways to do this easily.
1. use the regedit command (haven't tested)
regedit filename.reg
/S to suppress the message box (also see /E and /D for export and delete options)

Within the file the following are valid:
Windows Registry Editor Version 5.00
[HKEY_LOCAL_MACHINE\SOFTWARE\Key]
"name"="data"
To Clear
"name"=""
To remove
"name"=-
Remove entire key
[-HKEY_LOCAL_MACHINE\SOFTWARE\Key]

2. Using VBScript which I find easier
Pick one depending on the key(s) being modified
Const HKEY_CURRENT_USER = &H80000001
Const HKEY_LOCAL_MACHINE = &H80000002
Const HKEY_USERS = &H80000003

strComputer = "."
Set objReg = GetObject("winmgmts:\\" & strComputer & "\root\default:StdRegProv")

strKeyPath = "SOFTWARE\Path"
strValueName = "KeyName"
svalue = "Value"
objReg.SetStringValue HKEY_LOCAL_MACHINE, strKeyPath, strValueName, svalue
or
objReg.SetDWORDValue HKEY_LOCAL_MACHINE, strKeyPath, strValueName, svalue
(REG_SZ vs REG_DWORD)

Example:
Const HKEY_USERS = &H80000003
strComputer = "."
Set objReg = GetObject("winmgmts:\\" & strComputer & "\root\default:StdRegProv")
strKeyPath = ".DEFAULT\Control Panel\PowerCfg"
strValueName = "CurrentPowerPolicy"
svalue = "3"
objReg.SetStringValue HKEY_USERS, strKeyPath, strValueName, svalue

Monday, May 4, 2009

Remotely Add Scheduled Tasks (SCHTASKS)

echo off
SCHTASKS /Create /S MachineName /RU administrator /RP password /SC DAILY /MO 1 /TN TaskName /TR C:\batfileorapplocation\name.bat /ST 03:00:00 /SD 01/30/2009
pause

see SCHTASK /? for more information on other uses of SCHTASK

Friday, May 1, 2009

Clear Pagefile on Shutdown

Clear Pagefile on Shutdown can be toggled on and off to help speed shutdowns. By default it clears the pagefile on shutdown for security reasons.

[HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\Session Manager\Memory Management]
"ClearPageFileAtShutdown"=dword:00000000