Take the 2-minute tour ×
Server Fault is a question and answer site for professional system and network administrators. It's 100% free, no registration required.

I'm testing harddisk performance, and would like to test writing to the outer tracks of my harddisk with ZFS. One way of doing this would be to create a pool/filesystem with a start point just a few Gigs away from the end of my harddisk.

Is this possible? If so, how do I do it? I've looked in zfs man pages and googled, but couldn't find what I'm looking for.

Furthermore, I'd like to create a RAIDZ1 using only the last part (outer tracks) of my HDDs the same way - for performance testing purposes.

share|improve this question

2 Answers 2

up vote 5 down vote accepted

The term you're referring to is "short-stroking". You can do this by creating a pool of disk slices rather than the whole disks. Use some small percentage of the disk (10%-12%) capacity for the slices.

This may not be worth it, though. Use faster disks and SSDs since ZFS can leverage them well.

share|improve this answer
    
Ah, so I create disk slices in the OS first, and then a ZFS using these slices? I thought ZFS pools had to be placed on top of entire disks. –  poplitea Oct 8 '11 at 16:55
    
You can use disk slices in your ZFS pool. You just have to use the slice designation in your zpool create command. –  ewwhite Oct 8 '11 at 16:58
    
I tried that now - it works! Thank you :-) –  poplitea Oct 8 '11 at 17:13
    
You may actually end up with worse performance if you use slices instead of whole disks, due to the way ZFS handles the disk write cache –  Tom Shaw Oct 16 '11 at 5:08

In addition to slices already rightly suggested by ewwhite, you can also use plain primary partitions a ZFS low level device if you are running on x86 architecture, and even logical ones if on a recent OpenSolaris build, Solaris 11 Express or newer.

share|improve this answer
    
Yes, thank you. Once I understood that zfs accepts block devices other than just entire disks, it opened up a lot more flexibility to me :-) –  poplitea Oct 8 '11 at 21:11
1  
ZFS even accepts plain files, although not recommended for anything but testing purposes. –  jlliagre Oct 8 '11 at 21:31

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.