PDA

View Full Version : Performance tweaks and partition alignment for OCZ Agility 60GB SSD


c627627
03-10-10, 11:47 PM
I have the OCZ Agility 60GB SSD (http://www.ocztechnology.com/products/solid_state_drives/ocz_agility_series_sata_ii_2_5-ssd) with:
* Seek Time: < .1ms
* Read: Up to 185 MB/s
* Write: Up to 100 MB/s
* Sustained Write: Up to 60 MB/S

I do not notice any problems with it, I understand that many of the tweaks out there were originally meant to vastly improve performance of the slower SSDs not the faster ones.

I have a triple boot, Win 7 and Win XP on SSD and Vista on a 7200 RPM mechanical Samsung.


Partitions on the SSD are
1. Win 7
2. Win XP
3. Program Files for both


Should I do Partition alignment as described here (http://www.ocztechnologyforum.com/forum/showthread.php?48366-How-to-setup-Core-V1-2-Solid-Apex-Vertex-SSD-with-aligned-partitions-using-USB-%28if-available-on-the-drive%29-or-SATA.-Updated-to-show-how-to-use-Vista-recovery-disk&p=326656&viewfull=1#post326656) for Win 7 and XP and Program Files partitions?

Should I just align the Windows XP partition? What are the benefits for a fast SSD? I need to reimage it back using the existing image.

Should I do it by booting into Vista which is not on the SSD and aligning the partitions from there?

Should I disable Windows XP prefetcher as described here (http://www.ocztechnologyforum.com/forum/showthread.php?43460-Making-XP-pro-SSD-friendly) and enable power protect cache (dskcache) even though I have a fast SSD and notice no problems whatsoever in either Windows 7 or Windows XP?

_____________________
Intel i7 920 [200] BCLK x 19 = 3.80 GHz @ [1.4000] CPU Voltage & [1.35000] QPI/DRAM Uncore Voltage, Batch 3836A394
3 x 1GB G.SKIL DDR3 1333 (PC3 10666) [DDR3-1691MHz] 10-10-10-24 @ 1.64 DRAM Bus Voltage
ASUS P6T Deluxe v.1 [LGA 1366 Intel X58] BIOS 1606
Thermalright Ultra-120 eXtreme 1366 RT with 120mm Scythe S-Flex F fan
ASUS EAH4850 TOP Radeon HD 4850 512MB @ 680 MHz GPU & 2100 MHz Memory
OCZ Agility 60GB SSD
Antec nine hundred case, two front 120mm fans, one back 120mm Fan, one top 200mm fan
Corsair CMPSU-750TX 750W

nd4spdbh2
03-10-10, 11:49 PM
you need to offset the first partition correctly. cus if the first one isnt set correctly... the ones after it wont be and even then you still need to align subsequent ones.

c627627
03-11-10, 12:18 AM
OK. So align the first partition, then all the other ones after that? And should I bother with the second part (prefetch, etc.) if I notice no hickups whatsoever?


What kind of space savings are we talking about on a 60 GB SSD using partition alignment?

nd4spdbh2
03-11-10, 09:56 AM
OK. So align the first partition, then all the other ones after that? And should I bother with the second part (prefetch, etc.) if I notice no hickups whatsoever?


What kind of space savings are we talking about on a 60 GB SSD using partition alignment?

ya make sure all partitions are aligned at least to 64KB (128 sector) offset. You could play with the other stuff (disable 8dot3 names... no one needs those) and u might consider enabling power protect cache.

As far as space savings it depends... its definietly going to save some... that could be anywhere from 10mb to 1gb at 30gbs of usage.

c627627
03-15-10, 10:40 AM
When I change the BIOS setting to AHCI, I blue screen before Windows loads.


I have a few SATA drives and an IDE burner.


_____________________
Intel i7 920 [200] BCLK x 19 = 3.80 GHz @ [1.4000] CPU Voltage & [1.35000] QPI/DRAM Uncore Voltage, Batch 3836A394
3 x 1GB G.SKIL DDR3 1333 (PC3 10666) [DDR3-1691MHz] 10-10-10-24 @ 1.64 DRAM Bus Voltage
ASUS P6T Deluxe v.1 [LGA 1366 Intel X58] BIOS 1606
Thermalright Ultra-120 eXtreme 1366 RT with 120mm Scythe S-Flex F fan
ASUS EAH4850 TOP Radeon HD 4850 512MB @ 680 MHz GPU & 2100 MHz Memory
OCZ Agility 60GB SSD
Antec nine hundred case, two front 120mm fans, one back 120mm Fan, one top 200mm fan
Corsair CMPSU-750TX 750W

nd4spdbh2
03-15-10, 11:00 AM
you will need to set it to ACHI in the bios THEN install windows.

Mr Alpha
03-15-10, 11:04 AM
Windows uses different drivers for IDE and AHCI mode. So if you change the BIOS to AHCI mode without first telling Windows to load AHCI drives you get a bluescreen. Use these instructions (http://support.microsoft.com/kb/922976) to change to AHCI drivers in Windows before changing to AHCI mode in BIOS.

EarthDog
03-15-10, 11:13 AM
You can also load the AHCI drivers in windows then change it....

Alpha got it...should have refreshed before I replied.

c627627
03-15-10, 11:21 AM
Oh. Remind me again why I need to bother with this for SSD?

_____________________
Intel i7 920 [200] BCLK x 19 = 3.80 GHz @ [1.4000] CPU Voltage & [1.35000] QPI/DRAM Uncore Voltage, Batch 3836A394
3 x 1GB G.SKIL DDR3 1333 (PC3 10666) [DDR3-1691MHz] 10-10-10-24 @ 1.64 DRAM Bus Voltage
ASUS P6T Deluxe v.1 [LGA 1366 Intel X58] BIOS 1606
Thermalright Ultra-120 eXtreme 1366 RT with 120mm Scythe S-Flex F fan
ASUS EAH4850 TOP Radeon HD 4850 512MB @ 680 MHz GPU & 2100 MHz Memory
OCZ Agility 60GB SSD
Antec nine hundred case, two front 120mm fans, one back 120mm Fan, one top 200mm fan
Corsair CMPSU-750TX 750W



To resolve this issue, enable the AHCI driver in the registry before you change the SATA mode of the boot drive. To do this, follow these steps:

1. Exit all Windows-based programs.
2. Click Start, type regedit in the Start Search box, and then press ENTER.
3. If you receive the User Account Control dialog box, click Continue.
4. Locate and then click one of the following registry subkeys:
HKEY_LOCAL_MACHINE\System\CurrentControlSet\Servic es\Msahci
HKEY_LOCAL_MACHINE\System\CurrentControlSet\Servic es\IastorV
5. In the right pane, right-click Start in the Name column, and then click Modify.
6. In the Value data box, type 0, and then click OK.
7. On the File menu, click Exit to close Registry Editor.

EarthDog
03-15-10, 11:48 AM
NCQ is only enabled with AHCI.

W7 should do most of this for you but check...: Disable Superfetch, Indexing on that drive, defrag schedule, To save space I vlite'd the W7 install and cut out hibernation, restore, sleep, etc...

c627627
03-15-10, 12:18 PM
I disabled the heck out of my Windows 7 already: http://www.ocforums.com/showthread.php?t=616200

Check on all except for Superfetch, I think the word is to keep that on.


Can you tell me what real world difference NCQ / AHCI would bring to me:

_____________________
Intel i7 920 [200] BCLK x 19 = 3.80 GHz @ [1.4000] CPU Voltage & [1.35000] QPI/DRAM Uncore Voltage, Batch 3836A394
3 x 1GB G.SKIL DDR3 1333 (PC3 10666) [DDR3-1691MHz] 10-10-10-24 @ 1.64 DRAM Bus Voltage
ASUS P6T Deluxe v.1 [LGA 1366 Intel X58] BIOS 1606
Thermalright Ultra-120 eXtreme 1366 RT with 120mm Scythe S-Flex F fan
ASUS EAH4850 TOP Radeon HD 4850 512MB @ 680 MHz GPU & 2100 MHz Memory
OCZ Agility 60GB SSD
Antec nine hundred case, two front 120mm fans, one back 120mm Fan, one top 200mm fan
Corsair CMPSU-750TX 750W

EarthDog
03-15-10, 01:51 PM
Real world, no idea. But enabling AHCI overall improved my drive performance. Here is what it does on an intel drive: As one might expect from a company with a long history of developing core-logic chipsets, the X25-M's storage controller is an Intel design—and a smart one at that, with support for, ahem, SMART monitoring. More interestingly, the controller supports Native Command Queuing (NCQ)—a new trick for SSDs. NCQ was developed to reduce the performance impact of mechanical latency found in traditional hard drives, so it's might seem like an odd choice for a solid-state drive with no mechanical parts. According to Intel, its SSDs are so fast that NCQ helps to compensate for latency encountered in the host PC. Even today's fastest systems take some time (time is relative in the microsecond world of the SSD) between when a request is completed and another one is issued. Queuing up multiple requests can keep a solid-state drive busy during this downtime, and the X25-M is capable of stacking requests 32 deep.

c627627
03-15-10, 01:57 PM
There are a lot of SSDs out there, but most are not up to the performance of Intel SSDs and OCZ Agility & Vertex.


So what does NCQ / AHCI do for Intel or Agility/Vertex SSD on a i7 920 home system at 4 GHz.

EarthDog
03-15-10, 02:09 PM
If I can dig up my screenshots pre AHCI and post AHCI I will. Otherwise, I will refer you back to the excerpt I quoted above as that was about an Intel drive anyway. Sorry I cant say "it will cut your boot time by 2 seconds" as I know that is what you are looking for.

Mr Alpha
03-15-10, 02:30 PM
Reading and writing to flash chips isn't all that fast. The way SSD get such high speeds (both sequential and random) is by having multiple channels (10 for the Intel controller, for example) and then reading and writing to multiple flash chips at once. Sort of like a really sophisticated RAID0 setup. Except where RAID0 is just dumbly striping across drives the SSD controller is dynamically optimizing it all the time.

In AHCI mode you get Native Command Queuing, NCQ, which lest the drive reorder IO in the queue. By reordering the IOs the SSD controller can keep as many channels as possible operating in parallel.

For example there are a bunch of reads in the queue to chip on channel A and behind them a read to the chip on channel B. NCQ lets the controller pick that read to the channel B out of the queue and do it at the same time as it continues to work on the read to channel A. The Intel controller excels at this. Its random read almost doubles by enabling NCQ, and the more commands you feed it the more efficiently it can use its 10 channels and the faster it gets. The indilinx controller, with only four channels, doesn't scale as well.

c627627
03-15-10, 03:28 PM
I see. I believe the topic of this thread OCZ Agility uses the indilinx controller.


It therefore stands to benefit less. While of course, it's best to enable AHCI from the get go, I question the real life benefits of this because I would have to manually edit multiple operating systems (I have a multi-boot), I'll probably do it but I am looking to understand the real life benefits for indilinx based drives.

c627627
03-17-10, 12:30 AM
For the record, it appears to be next to impossible to enable AHCI on already installed Windows XP and since I have a multi boot which includes Windows XP, there's nothing I can do other than reinstall Windows XP, which is not going to happen at this time so :shrug:



EDIT: Yes there can:

http://www.overclockers.com/forums/showthread.php?t=648104

Z3l20
03-17-10, 12:43 AM
Is there any way to check what your current alignment is? I bought a Vertex series 60GB today and Win7 installed on it without requiring me to change anything (didn't need to upgrade firmware, align the drive, etc.. as I heard earlier models required you too).

I want to make sure I'm getting the most out of my drive and have completed a lot of the steps mentioned in this thread and in the OCZ threads, but can't seem to figure out what my current alignment is.

Mr Alpha
03-17-10, 05:40 AM
AS SSD (http://www.alex-is.de/PHP/fusion/downloads.php?cat_id=4) Benchmark will check alignment for you, but Windows 7 should align things properly for you.

Evilsizer
03-17-10, 10:15 AM
also last time i read the barefoot controller cant handle AHCI. Tony at ocz said to stick with IDE mode. like i said last time i read but that might have changed with newer FW's.

nd4spdbh2
03-17-10, 10:42 AM
Is there any way to check what your current alignment is? I bought a Vertex series 60GB today and Win7 installed on it without requiring me to change anything (didn't need to upgrade firmware, align the drive, etc.. as I heard earlier models required you too).

I want to make sure I'm getting the most out of my drive and have completed a lot of the steps mentioned in this thread and in the OCZ threads, but can't seem to figure out what my current alignment is.



start > type diskpart n press ender

In the cmd window that opens type

list disk

then

select disk N (where N is the number for your ssd listed by the list disk prompt)

then type list partition

Look at the offset value, should be 32.

Look at the attached picture for more details (my offset is 64KB because i set it that way, offers slightly better performance than a 32KB offset)

EarthDog
03-17-10, 10:50 AM
Another way... (same difference?)

To check that your partition is aligned correctly, go to your start menu and in the run box type msinfo32 and run it. Click on components => storage => disks and check what the partition starting offset is for your SSD. If it isn't divisible by 4096, then it's not aligned correctly (ie if you get any number that isn't a whole number, then it's not aligned).

c627627
03-17-10, 11:20 AM
If it isn't divisible by 4096, then it's not aligned correctly.

Mine's 1024KB for primary partition on SSD, that's divisible by 4096. But hm, why is it 1024?

Extended/Logical partitions list offsets in GBs.

Mr Alpha
03-17-10, 02:49 PM
Microsoft has started to use 1024k as the standard offset because it is a multiple of both 4k and many popular RAID stripe sizes, so you have a big chance of being correctly aligned even with RAID.

It is also only the first partition on the drive that will have the 1024k offset. The later partitions will have 1024k plus the size of the preceding partitions.

nd4spdbh2
03-17-10, 03:43 PM
Microsoft has started to use 1024k as the standard offset because it is a multiple of both 4k and many popular RAID stripe sizes, so you have a big chance of being correctly aligned even with RAID.

It is also only the first partition on the drive that will have the 1024k offset. The later partitions will have 1024k plus the size of the preceding partitions.

He speaks the truth. It is why i run even on my mechanical hds a 128KB offset to 1. align to 4KB reads n writes and 2. Align to the 128KB stripe size.

c627627
03-17-10, 04:14 PM
Therefore I do not need to align anything and 1024 KB is as it should be for SSD?

My mechanical drive with a primary partition is also showing a 1024 KB offset, however, my other mechanical drives do not have primary partitions, only extended/ logical partitions and they're showing Extended partitions having a 8033 KB offset. What's up with that?

nd4spdbh2
03-17-10, 07:37 PM
correct your ssd is aligned just fine. As far as your other drives i dunno what to tell you could be something to do with extended and logical partitions (why would you not create regular primary partitions anyway?)

MitchV
04-01-10, 07:43 PM
I allowed Win7 to create my SSD partitions on my 60GB Agility.

Partition 1 offset is 1024KB (as expected). It is 100MB in size.
Partition 2 offset is 101MB. It is 59GB in size.

I believe the 101MB represents 100MB + 1024KB... but is this ideal? How good/bad is this for performance and is it worth re-doing?

Thanks!

Evilsizer
04-01-10, 10:49 PM
the 100mb partition is a windows restore/backup space. the offset should be in a KB/Kb size not MB.

M Diddy
04-02-10, 01:07 AM
the offset should be in a KB/Kb size not MB.


Actually, that's incorrect. Win7, IIRC, defaults the OS partition to 101 MB, not KB.

Mine's setup the same way.

Evilsizer
04-02-10, 01:23 AM
Actually, that's incorrect. Win7, IIRC, defaults the OS partition to 101 MB, not KB.

Mine's setup the same way.

then i guess this guide to SSD partition alignment is completely wrong?
http://www.ocztechnologyforum.com/forum/showthread.php?t=48309

M Diddy
04-02-10, 02:47 AM
then i guess this guide to SSD partition alignment is completely wrong?
http://www.ocztechnologyforum.com/forum/showthread.php?t=48309

Not at all. XP/2003 suffers from this issue. I've had to partition many a volume using Diskpar when setting up Exchange servers.

I was just stating the point that with Win7, when checking the offset using Diskpart, it can indeed be shown in MB as well.

As long as it's a multiple of 4KB, it's fine.

c627627
07-08-10, 08:06 PM
For the record, it appears to be next to impossible to enable AHCI on already installed Windows XP and since I have a multi boot which includes Windows XP, there's nothing I can do other than reinstall Windows XP, which is not going to happen at this time so :shrug:


I was wrong:


My tests showed that when I installed a PCI SATA card, AHCI would only work for drives connected to the PCI card itself. Windows XP did not make any modifications to allow AHCI for use later if you went back to motherboard SATA connections. So now, since the original guide is confusing, here are the tested details to make things easier:




To be able to power on / plug in your internal hard drive without shutting down your Windows XP computer:


1. Check to see if file iaStor.sys is in your \Windows\System32\Drivers\ folder. If not, go here and download the Intel Matrix Storage Manager: http://downloadcenter.intel.com/Detail_Desc.aspx?agr=Y&DwnldID=17882

File names change for updated versions but for the example of IATA89ENU.exe file downloaded to C: drive: Start Menu > Run... > C:\IATA89ENU.exe -a -a

Now go to \Program Files\Intel\Intel Matrix Storage Manager\Driver to find and copy iaStor.sys to your \Windows\System32\Drivers\ folder.


[Note that you can't just double click on IATA89ENU.exe]



2. Figure out which ICH your motherboard uses by looking it up here:
http://en.wikipedia.org/wiki/List_of_Intel_chipsets

If it's ICH8R, ICH9R, or ICH10R, then copy and paste the corresponding lines below into Notepad and Save As a file with a .reg extension. Double click on it > Yes.


3. Reboot into BIOS and switch to AHCI mode.


4. When prompted, select Install from a list or specific location (Advanced) > Next > Don't search. I will choose the driver to install. > Next > Next > Have Disk… button > Browse… to
\Program Files\Intel\Intel Matrix Storage Manager\winall\Driver

Done and here are the reg files:


For ICH10R:


Windows Registry Editor Version 5.00

;
; Important: The File iastor.sys has to be present in the System32\Drivers folder.
;


[HKEY_LOCAL_MACHINE\SYSTEM\ControlSet001\Control\Cr iticalDeviceDatabase\pci#ven_8086&dev_3A22&cc_0106]
"Service"="iaStor"
"ClassGUID"="{4D36E96A-E325-11CE-BFC1-08002BE10318}"

[HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Servic es\iaStor]
"Type"=dword:00000001
"Start"=dword:00000000
"Group"="SCSI miniport"
"ErrorControl"=dword:00000001
"ImagePath"=hex(2):73,00,79,00,73,00,74,00,65,00,6d,00,33,00, 32,00,5c,00,44,00,\
52,00,49,00,56,00,45,00,52,00,53,00,5c,00,69,00,61 ,00,53,00,74,00,6f,00,72,\
00,2e,00,73,00,79,00,73,00,00,00
"Tag"=dword:00000019
"DisplayName"="Intel AHCI Controller"

[HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Servic es\iaStor\Parameters]
"queuePriorityEnable"=dword:00000000
"BusType"=dword:00000003

[HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Servic es\iaStor\Enum]
"0"="PCI\\VEN_8086&DEV_3A22&SUBSYS_B0051458&REV_01\\3&13c0b0c5&0&FA"
"Count"=dword:00000001
"NextInstance"=dword:00000001




For ICH9R:


Windows Registry Editor Version 5.00

[HKEY_LOCAL_MACHINE\SYSTEM\ControlSet001\Control\Cr iticalDeviceDatabase\pci#ven_8086&dev_2922&cc_0106]
"Service"="iaStor"
"ClassGUID"="{4D36E96A-E325-11CE-BFC1-08002BE10318}"

[HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Servic es\iaStor]
"Type"=dword:00000001
"Start"=dword:00000000
"Group"="SCSI miniport"
"ErrorControl"=dword:00000001
"ImagePath"="system32\\drivers\\iaStor.sys"
"tag"=dword:00000019
"DisplayName"="Intel AHCI Controller"

[HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Servic es\iaStor\Parameters]
"queuePriorityEnable"=dword:00000000

[HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Servic es\iaStor\Enum]
"0"="PCI\\VEN_8086&DEV_2922&SUBSYS_B0051458&REV_02 \\3&13c0b0c5&0&FA"
"Count"=dword:00000001
"NextInstance"=dword:00000001



For ICH8R:



Windows Registry Editor Version 5.00

[HKEY_LOCAL_MACHINE\SYSTEM\ControlSet001\Control\Cr iticalDeviceDatabase\pci#ven_8086&dev_2821&cc_0106]
"Service"="iaStor"
"ClassGUID"="{4D36E96A-E325-11CE-BFC1-08002BE10318}"

[HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Servic es\iaStor]
"Type"=dword:00000001
"Start"=dword:00000000
"Group"="SCSI miniport"
"ErrorControl"=dword:00000001
"ImagePath"="system32\\drivers\\iaStor.sys"
"tag"=dword:00000019
"DisplayName"="Intel AHCI Controller"

[HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Servic es\iaStor\Parameters]
"queuePriorityEnable"=dword:00000000

[HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Servic es\iaStor\Enum]
"0"="PCI\\VEN_8086&DEV_2821&SUBSYS_B0051458&REV_02 \\3&13c0b0c5&0&FA"
"Count"=dword:00000001
"NextInstance"=dword:00000001











Of course, for Windows 7/Vista:

Before switching to AHCI, simply change the value of the following registry keys to 0

HKEY_LOCAL_MACHINE\System\CurrentControlSet\Servic es\Msahci
HKEY_LOCAL_MACHINE\System\CurrentControlSet\Servic es\IastorV