9.12.2006

Why Windows takes so long to shut down.

We all have been there. It is 4:55 and you want to get out of work...But you want to make sure your system is shutdown for the night. You dutifully close all of your applications and start shutting down 5 minutes later it *finally* powers off It happens to more machines that it should. I decided to see what the problem might be. I searched google, forums, and newsgroups for an answer. The biggest culprit is a problem unloading the current users profile. This can happen when third party, or even Microsoft applications have not properly cleaned up when exiting. Windows will keep trying to unload the profile until Windows finally decides that it can't and should shutdown. Even if you find the application causing the problem - it may be impossible to do anything about it. This is why Microsoft released the User Profile Hive Cleanup Service This free utility automatically cleans up user profiles and prevents you from playing the timeout wait game. Once you run the setup wizard it will look like the installer did nothing. If you open up your services list (Click start, then run and type services.msc now click ok), you will see that a new service is running in the background:The idea of this program is to reclaim resources when a task is finished (memory, handles, etc). It accomplishes this by monitoring for users to log off and verifying that unused resources are reclaimed. This approach is superior as it works for any known reason that profiles do not unload and also will keep working to address new unknown issues. Now when you go to shutdown, logoff or restart it will happen within seconds. Instead of minutes.

Why windows takes so long to start up.

Most of us have had a brand new computer at one time. It's a great feeling. You boot up windows and within 30 seconds you are surfing the net, checking your email, or playing your favorite game. 10 months down the road things aren't so nice anymore. You power up your computer and it seems to take forever to load. Even when you are careful about what you install it seems that each day it takes longer for it to boot. It's not your imagination - and there are a couple of good tips to keep your boot time short and sweet. As always - backup your system before you start any of this. If you make a mistake you might need to restore from backup 1. The prefetch cache The first tip I want to talk about is the windows prefetch. Windows XP has this feature that loads commonly used programs - at boot time. Here is how it works: Yesterday you used MS Word, and Duke Nukem 3D. Today you boot your system to check e-mail. It sees parts of these two programs in the prefetch folder and loads them into memory before windows completes the boot process. The benefit is faster application launch times. If you really wanted to use MS Word, it would pop up really quick when you double clicked on it. The problem is most people have been running windows for years, and the prefetch gets clogged with stuff that you almost never use. Windows takes forever to boot because it is prefetching a 1.0 copy of Napster, and you just want to check your email before you have to go to work. What can be done about it? Well there are a few things we can do to tweak the prefetch cache. One method is to disable it partially, and this can be done quite easily. Simply browse to the windows folder (Ex: C:\Windows) and under there you should see the prefetch folder. Go into the prefetch folder and delete all the files (Careful! It should look like this c:\windows\prefetch) And here is a screenshot of one if you still have questions The first thing to note is the next reboot will be slow. This is because windows needs to relearn the prefetch for system files. Subsequent boots will run much faster since the sludge of programs has been removed, and only new ones are in the cache. The trouble is that it will only help you for a while - until the prefetch gets clogged up again. We need to edit a registry key to tweak it. Open regedit and browse to this key: HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\Session Manager\Memory Management\PrefetchParameters Under this key you should see a value named: EnablePrefetcher It has 4 possible values: 0 - Disabled : The prefetch system is turned off. 1 - Application : The prefetch only caches applications. 2 - Boot : The prefetch only caches boot system files. 3 - All : The prefetch caches boot, and application files. We don't want to disable it entirely. This would actually make boot times *longer*. This is because this feature is also used to speed up the loading of boot files. That is why we are going to pick the number 2 option. It allows us to keep the advantage of caching system files, without continually clogging the system up with applications. Set the value to 2 and reboot. The 2nd time you boot it should boot much faster. Remember that the side effect is that launching individual applications once windows has loaded will now be slightly slower. 2. Hard drive fragmentation Over time your hard drive will become fragmented. An over simplified explanation of fragmentation is when your files and folders are not all stored in the same spot. For example lets say you had a large movie file. If it were fragmented the first 5 megabytes are at the beginning of the hard drive, and then next 5 are at the end. It takes longer for windows to read the file than it would if it were all in the same spot. The point is that if each file is stored in a linear fashion, and the drive does not have to move all over the place to read it - it will load faster. XP has a built-in defrag tool, and it is simple to run. Open "My Computer" right click on the boot drive, and go to properties. Now click on the tools tab. Click "Defragment Now" and the following window should appear: Before you click on the "Defragment" button you want to close all applications and be aware that it might take hours to complete. If you leave something running it might keep windows from completing the defragment operation. Click on the defragment button and you can walk away. Or you can watch it defrag your hard drive:3. Disconnected network drives I am using networked drives all the time. If you have ever put your machine on a network and connected to a shared drive, this can slow you down too. If you have a drive that is still mapped, but cannot be reached it will slow down windows during boot time. This is because windows will wait...wait...and wait some more for the remote server to respond. To clean these out open "My Computer" and go to the tools menu. Click on "Disconnect Network Drives" It will open a window that looks like this: 4. Spyware & Adware These can have a big impact on your start times. If your PC gets loaded with spyware, it spends a large portion of its boot time making sure those pesky programs are loaded and ready to throw popup adverts at you all day. To check and clean your system of spyware there are three free programs that I highly recommend: 1. Microsoft Windows Defender 2. Ad-Aware 3. SpyBot Search And destroy 5. File and Printer Sharing One other item that can significantly impact is the "File and Printer Sharing" feature within windows. Obviously, if you are sharing your printer, or folders you don't want to disable this - so this tip is not for you. If you never use it, then why waste your time waiting for it to load? Here is how to turn it off: Go into the control panel. Click on "Network Connections"Now right click on "Local Area Connection" and click on properties Uncheck the "File and Printer Sharing for Microsoft Networks"Click OK, and reboot. That wraps up our windows startup optimization.

How to Remove Windows Genuine Advantage Notifications

Windows genuine advantage notifications occur when your computer hasn't passed the validation test. The validation test can be failed due to being sold a pirated (non-genuine) copy of XP, or because you have changed your XP product key to a software-generated key. The failed validation installs three types of notifications on your computer: one on the log in screen, one log in timer, and one balloon. It also stops updates from Microsoft and disables your ability to install IE7 and Windows Media Player 11. This solution can get rid of all three notifications, even though you will still not be able to update. Unfortunately, you can only update if you buy a valid Microsoft product key again.

Steps

  1. If you have only just installed Windows Genuine Advantage notifications, simply using the system restore function will remove the program. Then refuse to accept the GWA update next time Windows updates... otherwise, proceeed as detailed below.
  2. Open System32 by either A or B of the following methods: a) Click "Start", "Run", then type-in "System32". Click "Okay" b) Find System32 manually by clicking "Start" > "My Computer" > "(X:)" (Replacing "X" with the drive letter of the host of Windows) > "Windows" > "System32".
  3. In "System32", go to "Tools" > "Folder options" > click on the tab, "View" > Uncheck "Hide extensions for known file types". Now you can begin...
  4. Check to make sure the window that comes up has a full screen of various files. The files are in alphabetical order, which makes it easier to locate the specific file.
  5. Find "WgaLogon.dll" and rename it "WgaLogon.dll.bak".create an empty copy of WgaLogon.dll:
  • Right click on a blank space in System32 and select "New" > "Text Document".
  • Leave the text document empty and label it "WgaLogon.dll". Press Enter (on your keyboard).
  • You may get a warning from the above step that says, "If you change a file name extension, the file may become unusable. Are you sure you want to change it?". Click "Yes" on this warning.
7. Be ready to complete the next two steps very quickly! Find "WgaTray.exe" in "System32" and delete it. You will then have 5 seconds to find "WgaTray.exe" in the Task Manager (the next step). 8. Immediately open Task Manager. You can do this by pressing the Ctrl, Shift, and Esc keys simultaneously or right clicking the Taskbar and selecting "Task Manager". Click on the process tab and end "WgaTray.exe". 9. Restart your computer once you have finished. All the notification messages should be gone.