Thursday, May 17, 2007

Windows Tricks and Tips (Set-1)

This is a carbon copy of the PDF files that I published on the net a couple of months back. I'll update the blog as soon as I get time to do that. Most of the tricks deals with editing of Windows registry which involves a lot of risk. Please take enough backup copies of your system/registry before you go ahead with the editing of registry/system settings

1. Customize Your Login prompt


So let us get into some serious business. We shall start with a tip to customize your log in
prompt. Open Registry editor by going to Start-->Run-->regedit and Navigate to the key:
HKEY_LOCAL_MACHINE\SOFTWARE\Micrsft\WindowsNT\CurrentVersion\Winlogon.
In right pane, do a right click to create a new string value and give its name LogonPrompt.
Set its value to whatever text you want to see displayed at login screen. Reboot the machine
and see the log-in prompt for the change. You can see the text you entered above the text
fields that ask for username and password.

2.Closing “about” Window:

Certain web sites force the opening of a popup window with an advertisement that can not be
minimized or maximized like the other ordinary windows. These windows are a headache as
they do not have any Minimizing or maximizing buttons on them. This happens in MicroSoft
Internet Explorer 4/5/6 (that comes bundled with 98/Me/2000/XP). They do this by using the
"about:" browser built-in command into their HTML/DHTML/XML code. If you want to get
rid of such troubling windows during your surfing, then follow me. I have the fix. As usual
open the registry editor and navigate to the following registry key:
HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\Internet
Settings\ZoneMap\ProtocolDefaults
Now right click on the right window pane. Create a new Dword entry and name it about. Set
it’s value to “00000004” (hex). Please note that they are zeros and not the letter ‘O’.
Once again right click on the right window pane. This time create another Dword entry and
name it about: (Note the : symbol introduced here). Set it’s value to “00000004” (hex).
Please note that they are all zeros and not letter ‘O’.
This will place all "about:" URLs into the MS IE Restricted Zone (the hex code 00000004
stands for Restricted Zone), and hence will not open anymore while surfing the net.

3. Type URL without a Mouse Click

In IE you can use Alt + D key combination to highlight the address bar. This allows you to
enter a URL without the mouse click. This will be helpful for the laptop users who find it
uneasy to use their touchpad every time they want to type a URL.

4 Improve DNS resolution.

If you would ask me how XP handles DNS resolution, I would have to admit that it is simply
great. But there is still a room for improvement. This can be done by increasing the DNS
Cache size. To do this you would have to add following entries in registry. Please navigate to:
HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\Dnscache\Parameters.
Create or modify (if already present) the following four DWORD keys to following values.
CacheHashTableBucketSize 00000001(hex)
CacheHashTableSize 00000180 (hex)
MaxCacheEntryTtlLimit 000fa00a(hex)
MaxSOACacheEntryTtlLimit 0000012d(hex)

5. Alignment of Start Menu panel

Start menu has all the entries aligned to left by default. But if you insist on aligning it to the
right, then here is the way to achieve it. The objective can be met by a registry tweak. Open
the registry editor and navigate to the following key:
HKEY_CURRENT_USER\Control Panel\Desktop and look for key MenuDropAlignment.
Set its value to 1 to align the menu entry to right. If you have any regrets in future, turn the
value back to 0.

6. Change the Default Search Engine from MSN to Any Search Engine of Your Choice ..

Microsoft has set the default search engine in Internet explorer as MSN. But here is your
chance to set the default according to your wish. The tip is from MS-KB. First close the
Internet Explorer and open the registry editor (StartRunRegedit). Then navigate to the
following registry key.
HKEY_CURRENT_USER\Software\Microsoft\Internet Explorer\SearchUrl. Change the
value of the string key named default to any one of the following values:
• To specify Metacrawler as the default search page, change the default value to
"http://www.metacrawler.com/crawler?general=%s" (without quotation marks).
• To specify AltaVista as the default search page, change the default value to
"http://www.altavista.com/cgi-bin/query?q=%s" (without quotation marks).
• To specify HotBot as the default search page, change the default value to
"http://hotbot.com/?MT=%s" (without quotation marks).
• To specify Google as the default search page, change the default value to
"http://www.google.com/keyword/%s" (without quotation marks).
• To specify Infoseek as the default search page, change the default value to
"http://www.infoseek.com/Titles?qt=%s" (without quotation marks).
• To specify Excite as the default search page, change the default value to
"http://search.excite.com/search.gw?search=%s" (without quotation marks).
• To specify Lycos as the default search page, change the default value to
"http://www.lycos.com/cgi-bin/pursuit?query=%s" (without quotation marks).
• To specify Magellan as the default search page, change the default value to
"http://www.mckinley.com/searcher.cgi?query=%s" (without quotation marks).
• To specify Ask Jeeves as the default search page, change the default value to
"http://askjeeves.com/AskJeeves.asp=%s" (without quotation marks).
• To specify Yahoo! as the default search page, change the default value to
"http://search.yahoo.com/bin/search?p=%s" (without quotation marks).
• To specify GOTO.Com as the default search page, change the default value to
"http://www.goto.com/d/search/?type=topbar&Keywords=%s" (without quotation marks).
Quit Registry Editor, and then start Internet Explorer.

7. Disable the Win Key in a Keyboard

If you do not have a windows enabled keyboard you can disable its use. Navigate to the key:
HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\KeyboardLayout. Look
for value of "Scancode Map". Its binary data. Set its value to "00 00 00 00 00 00 00 00 03 00
00 00 00 00 5B E0 00 00 5C E0 00 00 00 00" to disable the win key. Please be cautious while
entering this lengthy key.

8. Disable Automatic Modem Connections at Startup

The system may try to initiate an Internet connection at Windows startup or at the start of
many applications. This setting can be disabled by a small registry hack. Navigate to the key
HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Ole.
Create a new String value, or modify the existing value, called EnableRemoteConnect and
edit the value to “Yes” or “No” accordingly. Yes = enable automatic connections and No =
disabled.

9. Customize the HTML error pages

Some times, when you type a webpage address you might see an error page. A very common
error page that we come across is “Page not found” page. These error messages do not come
from any server. They are all stored in a DLL file in our system itself. The name of the dll file
is SHDOCLC.DLL file. If you don’t trust me then copy the following address and paste it in
your IE address bar and see for yourself.
res://c:\\Windows\\System32\\SHDOCLC.DLL/servbusy.htm
Now replace servbusy.htm with other html files given below .
http_400.htm, http_404.htm, http_406.htm, http_410.htm, http_500.htm, http_501.htm,
http_gen.htm, servbusy.htm, syntax.htm, navcancl.htm, offcancl.htm, policyerror.htm,
policylooking.htm, policynone.htm, policysyntaxerror.htm, privacypolicy.dlg, preview.dlg,
printerr.htm, printnf.htm, printnof.htm, printunk.htm, wcee.htm, ietext.bmp, ietext256.bmp,
world.bmp, world256.gif, ie.gif, ie256.gif, orgfav.dlg, about.dlg, analyze.dlg, bidifind.dlg,
docppg.ppg, error.dlg, find.dlg, findic.dlg, ieerror.dlg, imageppg.ppg, orgfav.dlg, and
pstemplate.dlg (Do you trust me now???)
If you need to customize these messages, write an error message and store it somewhere on
your hard disk. We can replace all these HTML error pages with our own. Navigate to
HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\InternetExplorer\AboutURLs. You
can change entries associated with various keys and provide complete path name to your own
custom html file.

10. Fifth zone in Internet Explorer 6.0…?

Is there a fith zone in Internet Explorer 6? I think so. It is called my computer and is diabled
by default. If you want to enable this, Open registry editor and then navigate to the key
HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\InternetSettings\
Zones\0 and look for the dword data value called "Flags". Its default value is
0x00000021(hex). Chage its value to 1 and reboot. Now you should see an option called my
computer in Internet Explorer 6 Zone settings.

11. Clean Prefetch Data

The prefetch directory can get full of junk and obsolete links which can slow down your
computer noticeably. I would suggest that you do this once a month or so to improve the
speed. Do not follow this on a daily basis as prefetching of most commonly used programs
will speed up the execution of those programs. To perform this trick go to
C(SystemDrive):/windows/prefetch, and delete everything and reboot.

12.Way to Skip the “Open With Web Service” Prompt

To do this open up the registry editor and navigate to the following registry key:
HKEY_LOCAL_MACHINE\Software\Microsoft\Windows\CurrentVersion\Explorer. Now
create or modify a dword key named InternetOpenWith. Give a value of 0 (zero) to hide the
web services or 1 to display web services.

14. Reduce Modem Timeout

If you are experiencing a lot of modem timeout with you system, you can change the slownet
value in the Registry. Navigate to HKEY_LOCAL_MACHINE\System\CurrentControlSet
\Services \Class\Net\0000 (0001 etc) Change the slownet value from 01 to 00.

15. Where is the Conformation Message?

When you first choose to download a file in Internet Explorer, you receive a Confirm File
Open dialog box. The "Always ask before opening this type of file" check box in this dialog
box is selected by default. But if you clear that check box, the registry entry for this setting
is changed and you do not see the Confirm File Open dialog box in subsequent download
sessions. Instead, Internet Explorer automatically opens files instead of downloading them.
If you regret the action and you want the message box back, here is a way: go to
HKEY_CLASSES_ROOT\exefile and modify the third octet for the EditFlags value in the
value from 01 to 00.

16. Remove “Log Off” from the Start Menu

To remove the Log Off line on your Start menu do the following registry hack. Navigate to
HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Policies\Explorer
Create a new DWORD value and name it NoLogOff. Now add the value 1 to the key. You
need to logoff or reboot for the settings to take effect.

17. Modify the Internet Auto-Dial Settings

In Windows there is an option to automatically dial your Internet Service Provider (ISP) to
establish an Internet connection. This option can be controlled using this tweak. Navigate to:
HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\InternetSettings
Create a new binary value named EnableAutodial, and set the new value to equal 01 00 00
00 to enable autodial or 00 00 00 00 to disable it. Please take care while giving the values.
This restriction can be used on a computer wide basis by adding it to keys corresponding to
HKEY_LOCAL_MACHINE\Software\Micrsoft\Windows\CurrentVersion\InternetSettings.

18. Clear Most Recently Used (MRU) List From MS Word

When you try to save a document in MS Word; Save as window open, and on the file name
text field, if you click the arrow down, you will see the history of saved
documents. Don’t like this idea? You wish to clear that? Ok. Here we go. First open the
registry editor and navigate to the following key and delete accordingly:
HKEY_CURRENT_USER\Software\Microsoft\Office\10.0\Common\OpenFind\Microsoft
Word\Settings\Save As\File Name MRU.

19. Change the Default Download Directory in Internet Explorer

If you have created a directory and you want all the downloads to happen to that directory
instead of the default IE download directory, do this. Start Run  Regedit and navigate to
HKEY_CURRENT_USER\Software\Microsoft\Internet Explorer.
Change the value of the string "Download Directory" to the new path you want to assign as
IE's Default Download directory. I use C:\Sandy\Downloads.

20. Auto Disconnect Creating Problems?

If you are having problem setting the auto disconnect feature in Internet explorer 6 , here is a
tip. Open registry editor and enter the following area:
HKY_LOCAL_MACHINE\System\CurrentControlSet\Services\LanmanServer\Parameters
Llook for AutoDisconnect parameter. Change its value to whatever you want. Note that the
value mentioned here are in minutes.

21. Tuning MTU to Boost Internet Speed

Value of MTU decides the size of Internet data packet. Bigger the size, more is the time take
to transmit the packet over the internet. The maximum that you can put as the value of MTU
is 1500. Note that it may not make sense making it smaller than 68. It is therefore wise to use
a value between 1000 and 1500. Again this is a registry tweak and I STRONGLY recommend
the use of a tweaking utility that can do it for you. If you do not have any utility as such at
least make a system restore point so that in case you have some trouble you can roll back to
the previous system settings through the system restore facility provided by the Microsoft.
Open registry editor and Navigate to:
HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\Tcpip\Parameters\Inter
faces\ID_for_the_Adapter.
For this right click on right pane and add a DWORD key by the name MTU. Use a value
from 1000 to 1500. Higher values are recommended.

22. Automatic MTU Size Detection

If MTU size is not optimized, this job has to be done by a router which would mean a
significant waste of time resulting in poor throughout. We have a solution to this issue. All
you have to do is to enable a key called EnablePMTUDiscovery in the following area.
KEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\Tcpip\Parameters\Interfaces\
ID_for_the_Adapter. Right click on right pane and add a DWORD key by the name
EnablePMTUDiscovery. A value of 1 will enable the TCP to attempt to discover the MTU
size over the specific path to host.

23. Disable Automatic Private IP Addressing

This registry hack will disable Automatic Private IP Addressing, but not DHCP. If you want
the APIPA feature to be disabled, then navigate to: HKEY_LOCAL_MACHINE\System\
CurrentControlSet\Services\VxD\DHCP. Add a new DWORD entry with the name
IPAutoconfigurationEnabled and give it a value of 0 (zero). Now restart the computer.

24. Disabling Last Access feature

NTFS file system in XP maintains a list of access/update details for each file and directory.
This information is useful but for an average user. To do the tweaking navigate to:
HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\FileSystem and look
for the key NtfsDisableLastAccessUpdate and set its value to 1.

25. Automatic Window Refresh

Whenever you make a change to your windows you have to press F5 or do a manual refresh.
With this tweak you can tell windows to increase the rate at which it does the refreshing.
Navigate to the key:
HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\Update. Create a new
DWORD value, or modify the existing value, named UpdateMode and set it to equal "0" for
faster updates. Restart Windows for the change to take effect.

26. Enhance Network Throughput? Try This Out

Network throughput depends on a variety of factors and as such you never no what could be
the bottleneck. One of things that we can try out is the network redirector reserves.Open
registry editor and navigate to the key
HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\LanmanWorkstation\P
arameters. Click on right window pane and add the following Dwords. Valid values should
be between 0-255. Keep both values same.
MaxCmds 00000068 (hex)
MaxThreads 00000068(hex)

27. Delete Addresses Stored by AutoDial

AutoDial recordes a list of names and addresses. To see the list , type the following command
at a command prompt: rasautou -s
Now to delete a name or address entry from the list, open the registry editor and navigate to:
HKEY_CURRENT_USER\Software\Microsoft\RAS Autodial\Addresses. Delete whatever
you want.

28. Restrict Certain Users From Running An Application

You can selectively restrict access to few apps and file names. To do this, open registry and
navigate to:
HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Policies\Explorer
Now look for a subkey by the name DisallowRun. Within this key, add many string keys you
like each mapped to an application or file that you want to be restricted.

29. Enable Fast Shutdown

To enable fast shutdown open the registry editor. (StartRunRegedit) and go to the key:
HKEY_LOCAL_MACHINE\ System\CurrentControlSet\Control\Shutdown. Create a string
key called FastReboot and give it a value of 1.

30. Make XP Remember the Folder Settings

Sometimes you'll customize a folder and upon restarting you will be shocked to see that the
changes haven't been saved. In some cases the settings work for few days and then XP forgets
it. Ever wondered why this happens? Well, This is due to that fact that Windows XP
remembers the settings for only 400 folders, by default. When you customize more folders
the old settings are lost. To prevent Windows XP forgetting the folder customization, we can
increase the limit till 8000 (which is the upper limit).
Set the BagMRU Size to 6000 (Decimal) in the following registry keys:
HKEY_CURRENT_USER\Software\Microsoft\Windows\Shell
HKEY_CURRENT_USER\Software\Microsoft\Windows\ShellNoRoam
Let me remind you that the value that we set is in Decimal and not hex.

1 comment:

Andrew K said...

The tweak 11. Clean Prefetch Data is incorrect.

Cleaning the Prefetch folder in Windows XP/Vista is a Myth and will reduce performance. The Prefetch folder is self cleaning at 128 entries by Windows. When the 128 limit is reached Windows will keep the 32 most used prefetch files. Cleaning the folder before this will cripple Windows load and all application load times. The Prefetch folder is not a cache. Prefetch files are NOT loaded at Windows startup and unused files do absolutely nothing but take up a ridiculously small amount of disk space. The folder is rarely over 5 MB. Prefetch (.pf) files are merely REFERENCED when an Application loads so Windows can optimally load the application to RAM. There is NO negative performance hit from Prefetching. All recommendations to clean the folder or tweak Windows Prefetching in ANY way are Myths and spread by those who do not understand how Windows Prefetching works.

"XP Myths"
http://mywebpages.comcast.net/SupportCD/XPMyths.html

Mark Russinovich - Microsoft Technical Fellow
"Windows XP: Kernel Improvements Create a More Robust, Powerful, and Scalable OS"
http://msdn.microsoft.com/msdnmag/issues/01/12/XPKernel/default.aspx

Ryan Myers - Microsoft Windows Client Performance Team
"Misinformation and the The Prefetch Flag"
http://blogs.msdn.com/ryanmy/archive/2005/05/25/421882.aspx

Ed Bott - Author Windows Inside Out
"One more time: do not clean out your Prefetch folder!"
http://www.edbott.com/weblog/archives/000743.html