Overclock.net › Forums › Components › Hard Drives & Storage › SSD › Tutorials: Real world Windows 7 SSD tweaks and optimization
New Posts  All Forums:Forum Nav:

Tutorials: Real world Windows 7 SSD tweaks and optimization

post #1 of 637
Thread Starter 
Hello to all my fellow and future users of SSD drives and Windows 7.
I wanted to set up an area with real-world tips on getting the most out of your SSD and the Windows 7 operating system. I will separate each type of tip to its own message to keep things easier to read and to follow.

All of this has been tested on my laptop system, configured as follows:
HP DV2270us, Core 2 qual 2ghz, 4 Gig RAM.
Disk 0: OCZ Vertex LE 100 Gig (Boot drive), Disk 1: Seagate ST9500420AS 500 Gig 100MBs second drive.
Windows 7 ultimate 64-bit.
Machine is used all day every day at work and home, lots of virtual machines running.

These suggestions are just the way I choose to set things up and get GREAT performance and utilize the SSD to its fullest potential. Your mileage may and probably vary. The tutorials and suggestions are not meant to be debated, its all up to you to decide if you want to try them or not.
All standard disclaimers apply... I am not responsible for breaking your stuff, only mine.
With all that said, on with the tutorials...
(And for the record, I am Magic-Man here and Lightningltd on other boards)...
Edited by magic-man - 12/27/10 at 6:04pm
HP DV7-2270US
(13 items)
 
  
CPUGraphicsRAMHard Drive
Core 2 Quad HD 4650 8 Gigs 100 Gig Vertex LE SSD + 500 Gig Seagate 
OS
Windows 7 64-Bit 
  hide details  
Reply
HP DV7-2270US
(13 items)
 
  
CPUGraphicsRAMHard Drive
Core 2 Quad HD 4650 8 Gigs 100 Gig Vertex LE SSD + 500 Gig Seagate 
OS
Windows 7 64-Bit 
  hide details  
Reply

Gear mentioned in this thread:

post #2 of 637
Thread Starter 
This tutorial is for those who are already running Windows 7 on their SSD as a boot drive. If like me, you first installed to hard drive then used an image backup program to put the OS on the SSD, then this step is necessary to allow Windows 7 to set the proper settings for SSD use and set things up for optimizing the OS after burning the firmware and/or cleaning the drive to factory specs. If you installed directly to the your SSD, you don't need to follow this step, but it can be helpful if you followed the XP and vista SSD guides and things just aren't up to snuff.

*** read all the steps first so you can create the images and boot USB and CD/DVD and print the instructions before you start***

FIRST.... MAKE A BACKUP IMAGE just in case!!!!!!!!!!!!!!!!!!! Be sure to create the restore disk, too.

Basically, you need to do a repair install of Windows 7 so Windows can set itself up properly for SSD use. The following link will step you through this step:
http://www.sevenforums.com/tutorials...r-install.html

When done, we need to verify that TRIM is active. At a command prompt (start/run/cmd), type the following: fsutil.exe behavior query DisableDeleteNotify

It should respond back with DisableDeleteNotify=0 if trim support is ready and active. If it is not, type fsutil.exe behavior set DisableDeleteNotify 0

This will set Windows 7 to use TRIM when the drive and drivers are ready to do so.

Next, we need to make sure our ATA/ATAPI ACHI controller is set to use trim.
The new INTEL chipset drivers 9.6.0.1014 support TRIM! Use these instead of the MS AHCI ones for Intel Chipsets.
http://downloadcenter.intel.com/deta...&DwnldID=15251

If your controller chipset does not support trim then use the MS driver.

To see/change it, go to device manager and select IDE ATA/ATAPI controllers. If it says "Standard AHCI 1.0 Serial ATA Controller", you are good to go. If not, double click it and select the driver tab. Click update driver. Select browse. Select let me pick. select Standard AHCI 1.0 Serial ATA Controller.

Once it has reboot and all is fine, then U can go on to the next step (after making an IMAGE backup of the whole SSD with the new changes (I use Windows backup)).
HP DV7-2270US
(13 items)
 
  
CPUGraphicsRAMHard Drive
Core 2 Quad HD 4650 8 Gigs 100 Gig Vertex LE SSD + 500 Gig Seagate 
OS
Windows 7 64-Bit 
  hide details  
Reply
HP DV7-2270US
(13 items)
 
  
CPUGraphicsRAMHard Drive
Core 2 Quad HD 4650 8 Gigs 100 Gig Vertex LE SSD + 500 Gig Seagate 
OS
Windows 7 64-Bit 
  hide details  
Reply
post #3 of 637
Thread Starter 
This step is necessary IF you have been using the SSD for a while before updating the firmware and/or want to return performance back to factory fresh (this will fix isues created if you ran 'tony-trim' method on another site). I did it right after the firmware update since it will ERASE the entire SSD, losing all data. It is called an ATA secure erase for a reason.
some of the firmware update tools do not issue the proper ATA secure erase command when they are done (Like the samsung), so the SSD will 'inherit' any performance issues it had before. Using this method resets all the memory cells to factory values.

IF you just pulled the SSD out of the box and updated it, or have never used it, then this step is NOT NEEDED.
Remember! Make sure U have that image backup I keep yelling about, you WILL lose everything on the SSD if you haven't already!

Download and print the instructions from http://ata.wiki.kernel.org/index.php/ATA_Secure_Erase
Get the lin*x boot image from http://partedmagic.com/ and burn it to a CD/DVD.
Boot to the CD/DVD and click the bottom where it looks like a black window (prompt).
Follow the instructions you just printed. On my laptop, I had to unplug the SSD while the OS was running and plug it back in real quick to make it not be frozen as in the instructions.

When all done, you have a nice empty clean SSD to restore your image to!
Restore the image to the drive and boot up.

See U at the next part... Optimizing Windows 7 for the SSD!
HP DV7-2270US
(13 items)
 
  
CPUGraphicsRAMHard Drive
Core 2 Quad HD 4650 8 Gigs 100 Gig Vertex LE SSD + 500 Gig Seagate 
OS
Windows 7 64-Bit 
  hide details  
Reply
HP DV7-2270US
(13 items)
 
  
CPUGraphicsRAMHard Drive
Core 2 Quad HD 4650 8 Gigs 100 Gig Vertex LE SSD + 500 Gig Seagate 
OS
Windows 7 64-Bit 
  hide details  
Reply
post #4 of 637
Thread Starter 
Now that you have gotten everything done as far as firmware, and image restored and have a working Windows 7, we can do some things to make Windows 7 a bit 'friendlier' to your SSD and make things faster to boot.

FWIW, Microsoft did a great job in pre-optimizing Windows 7 for SSD use. Except for installation, over 95% of Windows 7 operations are READS, perfect for your SSD. You COULD just use it as is and things would be fantastic. BUT, there are some things to verify first.....

1: Verify that TRIM is enabled as in the prior messages.
2: Make sure your AHCI controller is using a TRIM compliant driver as in the prior messages.
3: Make sure the defrag program is disabled for the SSD... Admin tools/Services set Disk Defragmenter to disabled. I use auslogics disk defrag (free) for my other drives manually. U almost never have to defrag an SSD. It can lower its life expectancy.
4: Page File. There has been much debate about this. The idea that no one needs a page file is a bunch of crap. I have tried it both ways, moitoring writes and reads, and YES, it IS used even with 8 Gigs of RAM. I left mine at 2 Gigs, but it is just fine at 1 Gig. Writes to the page file are sequential now. Page file is also read at boot time to speed things. Keep it on your SSD where it belongs.
5: Superfetch/prefetch/bootfetch: Windows 7 does not always turn it all off as it should. The purpose of these things are to pre-load the programs you load from slow hard drive to fast memory (cache) in case you want to run them. With your SSD, there is no need. We will disable them and free up some memory and resources and stop a LOT of writes to the SSD.
To disable Superfetch, etc: Admin tools/Services. Select superfetch and set to disabled.
Run regedit and change the following values: HKLM/System/CurrentControlset/Control/Session Manager/Memory Management/Prefetch Parameters and change the key valus of Enableboottrace, enableprefetcher, enablesuperfetch all to 0 and exit regedit.

This will disable MOST of the superfetch/prefetch stuff... The boot prefetch will get disabled in the next part along with some un-necessary logging that is done (and writes a lot).
HP DV7-2270US
(13 items)
 
  
CPUGraphicsRAMHard Drive
Core 2 Quad HD 4650 8 Gigs 100 Gig Vertex LE SSD + 500 Gig Seagate 
OS
Windows 7 64-Bit 
  hide details  
Reply
HP DV7-2270US
(13 items)
 
  
CPUGraphicsRAMHard Drive
Core 2 Quad HD 4650 8 Gigs 100 Gig Vertex LE SSD + 500 Gig Seagate 
OS
Windows 7 64-Bit 
  hide details  
Reply
post #5 of 637
Thread Starter 
Now on to some things we can do to reduce some on the unnecessary writes to the SSD. Windows 7 has the most event logs that I have seen of any OS. If you are having issues, then I would not change the logging options. If not, then we can stop a lot of writes that frankly, only an engineer would need (we leave the basic event logs alone).
Go to start/admin tools and select performance monitor. Expand data collector sets. Click on Startup Event Trace Sessions.
With the exception of the following NECESSARY logs (Application, Security, System, Security Essentials) we can stop them from starting. To do so, right click on each one that has a status of Enabled (except the ones mentioned above) and select Properties. Click the Trace Session tab. Unselect Enabled. Click Ok. Repeat for the others (including readyboot).
After your next boot, you will have a lot less writes going to the SSD that are not needed.

Write caching... Enable on the SSD: http://www.sevenforums.com/tutorials...e-disable.html

IF and only IF you are low on space (will lower performance some): TEMP FILES... IF you have another NON SSD drive installed, I would move the TEMP and temporary internet files to them.

Since I have Windows 7 make an image backup of the SSD to my other drive every day (only takes a few minutes and very little resources), I completely turn off system protection (system restore).

You can also turn off Windows reliability monitor. I will post a short tutorial if you want. It does quite a bit of writing too, but only every few hours.

There are some other more advanced things I do, but to be honest, they result in very little speed increase (less than 1%).
Edited by magic-man - 3/21/11 at 4:35pm
HP DV7-2270US
(13 items)
 
  
CPUGraphicsRAMHard Drive
Core 2 Quad HD 4650 8 Gigs 100 Gig Vertex LE SSD + 500 Gig Seagate 
OS
Windows 7 64-Bit 
  hide details  
Reply
HP DV7-2270US
(13 items)
 
  
CPUGraphicsRAMHard Drive
Core 2 Quad HD 4650 8 Gigs 100 Gig Vertex LE SSD + 500 Gig Seagate 
OS
Windows 7 64-Bit 
  hide details  
Reply
post #6 of 637
Thread Starter 
Quote:
how do you "TEMP FILES... IF you have another NON SSD drive installed, I would move the TEMP and temporary internet files to them."
another question: doesn't superfetch run in the ram?
one more question: what do you find you need the paging file for with 8 gb ram? i have found ive never needed it for anything just curious why you think this or what you have found that needs it
Changing location of temp files: http://ask-leo.com/how_do_i_change_t...ary_files.html

Changing location of IE temp files: http://malektips.com/internet-explor...net-files.html

Superfetch does run in Ram, but it also does a lot of reading and writing. Remember, the object of superfetch is to copy program stubs from SLOW hard disk to fast RAM. With an SSD, this is not needed, since the SSD reads so fast. I recommend you try it with it on, then try it with the service disabled. You likely will not see any slow down, actually a speed up since more RAM is available for other things and there will be a marked decrease in disk writes/accesses.

Windows 7 does use the page file IF PRESENT to keep things effecient. Several programs use it like VMWARE, some games, graphics software, MS office, etc... It will only use it when it is effecient to do so. With 8 Gigs of RAM a 1 GIG page file is plenty. Remember: the page file in Windows 7 is more sequential now, and therefore much more efficient. One of my MS sources also told me that there is some cached boot code in it to speed up boot, but to be honest, I haven't seen a difference. I can tell you that it IS smoother with even a 512 Meg page file on the SSD.
Try it both ways with your read-world load and decide for yourself. There is no bench-mark for it other than your gut. That is why it is so debated.

EDIT: 10/12/2010: I am no longer recommending that you move your temp files or internet files off the SSD. It does not increase performance, but decreases it a bit.
The original reason I recommended it was to save space if it gets tight.
Edited by magic-man - 10/12/10 at 7:54pm
HP DV7-2270US
(13 items)
 
  
CPUGraphicsRAMHard Drive
Core 2 Quad HD 4650 8 Gigs 100 Gig Vertex LE SSD + 500 Gig Seagate 
OS
Windows 7 64-Bit 
  hide details  
Reply
HP DV7-2270US
(13 items)
 
  
CPUGraphicsRAMHard Drive
Core 2 Quad HD 4650 8 Gigs 100 Gig Vertex LE SSD + 500 Gig Seagate 
OS
Windows 7 64-Bit 
  hide details  
Reply
post #7 of 637
Thread Starter 
Quote:
could you also explain: You can also turn off Windows reliability monitor
Admin tools, open task scheduler. expand task scheduler library, then Microsoft, then Windows. Scroll down and click on RAC. Go to the top and select View then show hidden tasks IF RACTASK is not showing. Right click on RacTask and select disable. To re-enable it, you right click it and select enable.
Here is the good part.... disabling it stops it from PROCESSING reliability data and errors for reliability viewer. The data is still collected in the logs, just stored effeciently. You can re-enable it and see the reliability stuff when U wish. Disabling it saved RAM and some drive churning until U need to look at it.
HP DV7-2270US
(13 items)
 
  
CPUGraphicsRAMHard Drive
Core 2 Quad HD 4650 8 Gigs 100 Gig Vertex LE SSD + 500 Gig Seagate 
OS
Windows 7 64-Bit 
  hide details  
Reply
HP DV7-2270US
(13 items)
 
  
CPUGraphicsRAMHard Drive
Core 2 Quad HD 4650 8 Gigs 100 Gig Vertex LE SSD + 500 Gig Seagate 
OS
Windows 7 64-Bit 
  hide details  
Reply
post #8 of 637
Thread Starter 
Some of what I do is not limited to SSD, but overall OS optimization...
Services... I used the black viper guide and got mine trimmed down some without losing functionality of Win 7... I like it the way it is (almost). U can read up on what each service does and decide for yourself...
http://www.blackviper.com/Windows_7/servicecfg.htm

However, here are the services on my machine (laptop):

Attachment 148326
Tab separated file with MY service config...
HP DV7-2270US
(13 items)
 
  
CPUGraphicsRAMHard Drive
Core 2 Quad HD 4650 8 Gigs 100 Gig Vertex LE SSD + 500 Gig Seagate 
OS
Windows 7 64-Bit 
  hide details  
Reply
HP DV7-2270US
(13 items)
 
  
CPUGraphicsRAMHard Drive
Core 2 Quad HD 4650 8 Gigs 100 Gig Vertex LE SSD + 500 Gig Seagate 
OS
Windows 7 64-Bit 
  hide details  
Reply
post #9 of 637
Thread Starter 
It has been asked what other little things can be done to squeeze a litle more performance from Windows 7 on our SSD drives... One thing that helps maintain performance on an SSD is the percentage of free space available to the SSD controller to execute 'wear leveling'. Basically, spreading out the load to the least used empty memory cells.
In order to do this, we need to fool Windows and other programs into looking elsewhere for stuff that is necessary, but rarely used and taking up a lot of disk space.
This part is only useful IF you have your operating system on your SSD AND it is formatted as NTFS and have a second drive available (NTFS) with space free to use.
What we are going to do is move certain directories to the other drive, then make Windows (and the programs) think it is still on the boot drive. We do this by using an NTFS 'junction'. Think of a junction as a pointer to a location. To the operating system, the files look like they are in location A, but they are really physically in location B.

For the tutorial, we are going to assume that the SSD is C: and the second drive is E:. Substitute your drive letters as needed. As always, MAKE A BACKUP FIRST!
If you are still with me, here is how to do it (the easy way):
Go to http://schinagl.priv.at/nt/hardlinks...kshellext.html and download (and INSTALL) the link shell extension software (and VC runtime, follow the instructions on the site) for your flavor of Windows 7 (or barf Vista).
Make sure explorer is set to SHOW hidden and system files (Tools/Folder Options/View tab, Show hidden, uncheck Hide protected operating system and hide extensions)
Create the following directories:
E:\\WinSystem
E:\\WinSystem\\Windows
Boot into safe mode. Open explorer and navigate to C:\\Windows.
Right click on the Installer directory and select CUT
Navigate to E:\\WinSystem\\Windows right click and select paste. It should have created the directory E:\\WinSystem\\Windows\\Installer with files in it.
Right click the directory E:\\WinSystem\\Windows\\Installer and select Pick Link Source.
Navigate to C:\\Windows and right click in the directory and select Drop As and select Junction.
You should now see C:\\Windows\\Installer is back (with a wierd link on the folder icon)... The OS now will put installer files on the other drive and look for them there, but think it is still on c:!
Other directories I do this with are the HP install directory (C:\\SwSetup) and MS Office setup directory (C:\\MSOCache).
In the previous tutorials, yo learned how to move the TEMP and internet Temporary files... This is a good place for them too. Here is the directory structure on my E:\\WinSystem directory:
E:\\WinSystem\\MSOCache
E:\\WinSystem\\SwSetup
E:\\WinSystem\\Temp
E:\\WinSystem\\Temporary Internet Files
E:\\WinSystem\\Windows\\Installer

EDIT 10/12/2010: Unless you are low on space, I do NOT recommend moving the temp and internet temp files off the SSD. The other folders yes.

Just make sure to drop the junction in the same place as the original directory and the OS will be none the wiser and you will have moved GIGABYTES of seldom used stuff of your SSD (and redirected some more writes)!

The only down side that I have found is as follows: If your backup strategy is like mine WAS, then you would only be making a backup image of the SSD. The problem is, that image backup software does not see that you moved the files, so they cannot copy the files in the E:\\WinSystem directory with the image. The fix is quite simple if U are using Windows 7 backup: Along with the system image, have it back up the directory E:\\WinSystem. Then it will keep them together and in sync (you restore the image AND the directory that went with the image).

Undoing the junction is easy too, if you want to. Simply delete the junction from the C drive and move the directory back where it was (hence the reasoning I had you create WinSystem\\Windows\\Installer instead of WinSystem\\Installer as a reminder of where the directory was when U started (thinking of WinSystem as the root)!
Edited by magic-man - 10/12/10 at 7:55pm
HP DV7-2270US
(13 items)
 
  
CPUGraphicsRAMHard Drive
Core 2 Quad HD 4650 8 Gigs 100 Gig Vertex LE SSD + 500 Gig Seagate 
OS
Windows 7 64-Bit 
  hide details  
Reply
HP DV7-2270US
(13 items)
 
  
CPUGraphicsRAMHard Drive
Core 2 Quad HD 4650 8 Gigs 100 Gig Vertex LE SSD + 500 Gig Seagate 
OS
Windows 7 64-Bit 
  hide details  
Reply
post #10 of 637
Thread Starter 
Tired of the huge event log? Tired of having to clear each log one at a time? Here is a batch file to clear ALL event logs in one shot: (enjoy!)

(Save the below as Clear_All_Logs.bat in your root double click it to execute once saved):

@echo off
FOR /F "tokens=1,2*" %%V IN ('bcdedit') DO SET adminTest=%%V
IF (%adminTest%)==(Access) goto noAdmin
for /F "tokens=*" %%G in ('wevtutil.exe el') DO (call :do_clear "%%G")
echo.
echo Event Logs have been cleared! ^
goto theEnd
:do_clear
echo clearing %1
wevtutil.exe cl %1
goto :eof
:noAdmin
echo You must run this script as an Administrator!
echo ^
:theEnd
pause>NUL
HP DV7-2270US
(13 items)
 
  
CPUGraphicsRAMHard Drive
Core 2 Quad HD 4650 8 Gigs 100 Gig Vertex LE SSD + 500 Gig Seagate 
OS
Windows 7 64-Bit 
  hide details  
Reply
HP DV7-2270US
(13 items)
 
  
CPUGraphicsRAMHard Drive
Core 2 Quad HD 4650 8 Gigs 100 Gig Vertex LE SSD + 500 Gig Seagate 
OS
Windows 7 64-Bit 
  hide details  
Reply
New Posts  All Forums:Forum Nav:
  Return Home
  Back to Forum: SSD

Gear mentioned in this thread:

Overclock.net › Forums › Components › Hard Drives & Storage › SSD › Tutorials: Real world Windows 7 SSD tweaks and optimization