View previous topic :: View next topic |
Author |
Message |
mdpye Tux's lil' helper
Joined: 18 Apr 2002 Posts: 102 Location: Nottingham, England
|
Posted: Thu Jul 18, 2002 5:02 pm Post subject: Using ext3 writeback mode for better performance... |
|
|
OK, so everybody knows that writeback mode gives better performance in ext3 and still the same level of protection as the other journalled filesystems, but how to actually enable it on your root partition seems to be less than well documented. So here it is:
You should add "data=writeback" to the options sections of any other ext3 filesystems you use in /etc/fstab, but not your root partition (/). This is because the default mode is ordered and the mode cannot be changed once mounted. Your root partition is mounted by the kernel, read-only, during boot up and remounted read-write by your init scripts. However, trying to change from ordered to writeback mode will cause the remount to fail.
Instead, append "rootflags=data=writeback" to your kernel command line (or use grub, or stick it in lilo.conf if you want it permanent). This will have the kernel mount the root filesystem in writeback mode.
You do not need to specify the mode in /etc/fstab, but you can if you wish. I don't recommend it, as it is unneccesary and if you upgrade your kernel and forget to add the parameter ( ) the boot will fail and you'll need a rescue disk to sort it.
Just sharing the results of today's googling. _________________ Cheers, MP |
|
Back to top |
|
|
fghellar Bodhisattva
Joined: 10 Apr 2002 Posts: 856 Location: Porto Alegre, BR
|
|
Back to top |
|
|
mdpye Tux's lil' helper
Joined: 18 Apr 2002 Posts: 102 Location: Nottingham, England
|
Posted: Fri Jul 19, 2002 9:39 am Post subject: Re: Using ext3 writeback mode for better performance... |
|
|
Interesting, but not a particularly good benchmark for real world testing. Strangely enough, from the docs and different tests etc I've seen I got the impression that data=journal was depreciated.
Still, the tip still applies, as it is actually how to use anything EXCEPT ordered, which is now left trailing as the slowest mode (if journal is actually fast!)... _________________ Cheers, MP |
|
Back to top |
|
|
how n00b
Joined: 29 Jun 2002 Posts: 10 Location: Norway
|
Posted: Mon Jul 22, 2002 10:34 pm Post subject: Re: Using ext3 writeback mode for better performance... |
|
|
mdpye wrote: |
Still, the tip still applies, as it is actually how to use anything EXCEPT ordered, which is now left trailing as the slowest mode (if journal is actually fast!)... |
Most of the tests I've seen indicates that it all depends on how the filesystem is used. So IMHO, the best tip would be "experiment with different options".
data=journal certainly is the most secure option, as it ensures consistency of the data on the disk at all times. It also happens to be the fastest option in a few situations. IIRC, data=ordered is also fast under certain conditions.
You should also try the noatime options (with any filesystem), so the fs metadata isn't dirtied after every access (as opposed to after every write). |
|
Back to top |
|
|
|
|
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum
|
|