LinHES Forums
http://forum.linhes.org/

Filesystem performance boost, R5.5 install
http://forum.linhes.org/viewtopic.php?f=3&t=18473
Page 1 of 3

Author:  manicmike [ Mon Jul 07, 2008 7:35 pm ]
Post subject:  Filesystem performance boost, R5.5 install

If you get a bit annoyed with the pauses watching TV when deleting old shows, here is a good tip for an auto-install. Don't use it for an upgrade as it will delete all of your existing files!

At the end of the install when you get the Reboot? message, don't reboot yet.

Press Alt-F2 to get to a terminal, and vim (or nano if you prefer) /mnt/hdinstall/etc/fstab
In the /myth partition set the file type to "xfs", save and quit.
issue "mkfs.xfs -f /dev/sda3" (assuming you have a SATA or SCSI disk)
Alt-F1 and select the OK and reboot.

xfs is far more efficient at dealing with big files. you won't get the disk grinding every time you delete something and it's much faster than ext3 (the default). For an extra squeeze, you can also add "noatime" to your root partition's options in /etc/fstab.

Cheers

Mike

Author:  graysky [ Tue Jul 08, 2008 11:44 am ]
Post subject: 

Sounds cool. Too bad there isn't a way to convert an existing FS to XFS.

Author:  jzigmyth [ Tue Jul 08, 2008 11:50 am ]
Post subject: 

What would be the downside to using XFS instead of Ext3? Any robustness issues or anything like that?

Same goes for "noatime", what is the downside? (actually I don't even know what "noatime" is or does)
Zig

Author:  knappster [ Tue Jul 08, 2008 11:55 am ]
Post subject: 

graysky wrote:
Sounds cool. Too bad there isn't a way to convert an existing FS to XFS.


Where there's a will, there's a way:
http://www.knoppmythwiki.org/index.php? ... tem+switch

And in addition to jzigmyth's questions... if you change to XFS, will that affect auto-upgrades?

Author:  manicmike [ Tue Jul 08, 2008 2:50 pm ]
Post subject: 

knappster wrote:
And in addition to jzigmyth's questions... if you change to XFS, will that affect auto-upgrades?


No. Auto-upgrade restores your /etc/fstab which is the only file that will be affected.

Mike

Author:  manicmike [ Tue Jul 08, 2008 2:52 pm ]
Post subject: 

jzigmyth wrote:
What would be the downside to using XFS instead of Ext3? Any robustness issues or anything like that?

Same goes for "noatime", what is the downside? (actually I don't even know what "noatime" is or does)
Zig


No negatives these days. You wouldn't use it for a root partition just in case it isn't supported in the kernel, but /myth is perfect due to the large files thing.

Mike

Author:  ChapmanI [ Tue Jul 08, 2008 7:43 pm ]
Post subject: 

Are you suggesting using the "noatime" parameter on just "hda1" (the root filesystem), just "hda3," or on both "hda1" and "hda3"?

I know xfs is already in the R6 feature request queue (and accepted as a done deal I think). Should we add "noatime" to that list too?

Author:  tjc [ Tue Jul 08, 2008 7:51 pm ]
Post subject: 

I don't think anyone is suggesting using XFS let alone noatime on the root partition.

BTW - atime is access time for the files, and the "noatime" option disables tracking it. It's a silly micro optimization unless you're running something with large numbers of smallish files and lots of parallel access (say like an image or news server).

Author:  turpie [ Tue Jul 08, 2008 8:37 pm ]
Post subject: 

jzigmyth wrote:
Same goes for "noatime", what is the downside? (actually I don't even know what "noatime" is or does)
Zig

The noatime setting stops the filesystem from recording the "last accessed time" for each file, which isn't very useful for most people anyway but saves having to constantly update the atime record any a file is read/accessed.

Author:  ChapmanI [ Wed Jul 09, 2008 12:36 am ]
Post subject: 

manicmike wrote:
For an extra squeeze, you can also add "noatime" to your root partition's options in /etc/fstab.

ChapmanI wrote:
Are you suggesting using the "noatime" parameter on just "hda1" (the root filesystem), just "hda3," or on both "hda1" and "hda3"?

I know xfs is already in the R6 feature request queue (and accepted as a done deal I think). Should we add "noatime" to that list too?

tjc wrote:
I don't think anyone is suggesting using XFS let alone noatime on the root partition

I wasn't suggesting xfs for the root partition, though I can see how my comment could have been interpreted that way. The file sizes and volume of file creation/deletion doesn't lend itself to the use of xfs there. The /myth partition is another story, and xfs is widely accepted as the correct choice for it. I suppose my comment above should be updated with "... R6 feature request queue, for the /myth partition ..."

My "accepted as a done deal" point refers to the following: After several posts in the R6 Feature Request thread, about using xfs as the default for the /myth partition, Cecil said, "/myth will be what you want it to be..."

It sure seemed from manicmike's initial posting in this thread, that he meant for the "noatime" optimization to be applied to the root partition, but he didn't refer to applying it to the /myth partition. My gut says it makes sense to do it to both.

I've used a similar feature on the NTFS partitions of my Windows box for years. Last accessed time is useful for large system administrators, but rarely needed for average users and applications. I've seen mention of web servers significantly reducing their load, and increasing their page serving capacity, just by eliminating the updating of files with the last time accessed.

BTW, using "noatime" is a Linus approved optimization.
In a recent lkml thread, Linus Torvalds was involved in a discussion about mounting filesystems with the noatime option for better performance, "'noatime,data=writeback' will quite likely be *quite* noticeable (with different effects for different loads), but almost nobody actually runs that way." He noted that he set O_NOATIME when writing git, "and it was an absolutely huge time-saver for the case of not having 'noatime' in the mount options. Certainly more than your estimated 10% under some loads."

Elsewhere in that discussion Ingo Molnar said, "I cannot over-emphasize how much of a deal it is in practice. Atime updates are by far the biggest IO performance deficiency that Linux has today. Getting rid of atime updates would give us more everyday Linux performance than all the pagecache speedups of the past 10 years, _combined_."[/url]

Those comments seem to imply that it is slightly more than a "micro-optimization."

Author:  manicmike [ Wed Jul 09, 2008 1:56 am ]
Post subject: 

ChapmanI wrote:
It sure seemed from manicmike's initial posting in this thread, that he meant for the "noatime" optimization to be applied to the root partition, but he didn't refer to applying it to the /myth partition. My gut says it makes sense to do it to both.


I meant it for / only, but only because it will make some difference there (lots of small files) whereas no real difference with relatively small numbers of large files (/myth).

ChapmanI wrote:
I've used a similar feature on the NTFS partitions of my Windows box for years. Last accessed time is useful for large system administrators


Most sysadmins are large ;-) some are huge!
ChapmanI wrote:
Those comments seem to imply that it is slightly more than a "micro-optimization."


Agreed. I have read a lot about it and where there are a lot of files involved it is reported to make a big difference to the speed of file access.

Cheers

Mike

Author:  Grant_Edwards [ Wed Jul 09, 2008 8:42 am ]
Post subject: 

ChapmanI wrote:
I wasn't suggesting xfs for the root partition, though I can
see how my comment could have been interpreted that way. The
file sizes and volume of file creation/deletion doesn't lend
itself to the use of xfs there. The /myth partition is another
story, and xfs is widely accepted as the correct choice
for it.

XFS is definitely superior to ext3 for the /myth partition.
When I was using ext3, deleting a recording would cause
playback to pause (and sometimes crash) for the next 30-60
seconds. This would happen even when deleting relatively
"small" SD recordings. Since switching to XFS, I've never
noticed any effect when I delete a recording.
Quote:
My "accepted as a done deal" point refers to the following:
After several posts in the R6 Feature Request thread, about
using xfs as the default for the /myth partition, Cecil said,
"/myth
will be what you want it to be..."

That's good to hear. I can't imagine why anybody would want to
use ext3 -- especially as HD becomes more common.

Author:  opel70 [ Wed Jul 09, 2008 10:51 am ]
Post subject: 

knappster wrote:
graysky wrote:
Sounds cool. Too bad there isn't a way to convert an existing FS to XFS.


Where there's a will, there's a way:
http://www.knoppmythwiki.org/index.php? ... tem+switch

Just to clarify, this process doesn't "convert" an existing FS to XFS, it backs up and reformats. Requiring you to have enough space available to store a tar backup of your entire /myth partition somewhere else.

Author:  ChapmanI [ Wed Jul 09, 2008 8:00 pm ]
Post subject: 

manicmike wrote:
Most sysadmins are large ;-) some are huge!
No slight was intended towards system administrators. Nor was it a commentary on their girth.

Perhaps the phrasing should have been
Quote:
administrators of large systems

Author:  stevenj [ Wed Jul 09, 2008 8:55 pm ]
Post subject: 

I'm no export and could very well be wrong, but I thought I'd read here that a big negative of XFS was that if used on an LVM partition, you couldn't extend it. With the storage pools in the new version, LVM isn't so necessary any more, so I'm planning to move to XFS now with 5.5. Been desperately waiting for this version to migrate my 4-drive LVM /myth partition to a new 750GB HD XFS partition I bought in March.

Steve

Page 1 of 3 All times are UTC - 6 hours
Powered by phpBB® Forum Software © phpBB Group
http://www.phpbb.com/