I have 2 identical 1TB drives, and have one formatted with ext3 and the other with reiserfs. I did a full copy of all files from the ext3 drive to the reiserfs one. On the ext3 drive, there is 770GB of data (leaving about 160GB of free space on the drive). The same data on the reiserfs drive only takes up 720GB (leaving about 210GB of free space)
50GB is a lot to lose! I don’t want to start a reiserfs vs. ext3 flamewar, but I hadn’t ever heard of this much size discrepancy before and it’s a very good argument for me to switch to reiserfs for all my drives.
Does ext3 really typically take up that much more space (5-6%)? If not, is there some other issue with one of my drives that I may not be aware of?
Yes, as default ext3 takes 5% of space so in that case it takes a lot You can always set it to 0% if You’d like. I guess if that is not a root partition then those 5% are not needed
-m reserved-blocks-percentage
Set the percentage of the filesystem which may only be allocated by privileged
processes. Reserving some number of filesystem blocks for use by privileged pro-
cesses is done to avoid filesystem fragmentation, and to allow system daemons,
such as syslogd(8), to continue to function correctly after non-privileged pro-
cesses are prevented from writing to the filesystem. Normally, the default per-
centage of reserved blocks is 5%.
tune2fs -m 0 /dev/sdXX (where XX is changed accordingly)
Is there a benefit to keeping this 5% on a data partition?
Also, I have a lot of power outages in my area and I don’t want to lose my data due to an outage. (fsck repairs on startup are very common for me). Is there a benefit to ext3 over reiserfs in terms of data recovery?
I’d recommend using xfs when using large files. It is a lot faster in regard of those and reiserfs is not good for large files, it’s best for small files so it’s either ext3 or xfs. You can lose data only if you copy something, if You just read the data then You won’t lose anything no matter how many power outages you’ll have In fact, you won’t lose any data if You just read it Also ext3 is more like an all rounder while xfs is once again, good with large files.
You recommend XFS to a guy who frequently has power outages and has not said if he has a UPS??? Nice job… Maybe next time you can go to his house and just trash his disk since the chance that XFS will ****up, even when just reading files, is much larger than under Ext3. Also, Ext4 is just around the corner and has some things that XFS misses (like journal checksumming) which can increase both data integrity and speed, so using Ext3 now gives you an easier upgrade path to Ext4. You can’t “losslessly” convert Ext3 -> XFS. Yes, yes, XFS can screw you even if you only read files, as I have experienced a year and a half ago where only Kwrite was open and suddenly power went down. Upon boot, I found my file screwed (no, there was no writing going on - the file was just open in kwrite for some time)
When You read data no filesystem will get thrashed. Everyone will tell You that. If you play a movie from an xfs partition it doesn’t have any files in the write queue so stop talking trash.
It is because the file was kept in the write queue. That’s all. The only reason ext3 is better is because it flushes files every 5 seconds. Even if you’d have ext3 then upgrading to ext4 wouldn’t make it perform better as only new files would use the new stuff like extents etc. And xfs already has extents.
That may be so and I’m not really sure if kwrite keeps files in write queue but XFS has caused me a lot of troubles in the past (firefox losing its bookmarks when power outage happens here and FS is XFS, among other things). Your argument about the upgrade path is not very strong. Consider this…
User has a 1TB disk as Ext3 -> wants to upgrade to Ext4 for extra performance & integrity -> Easy as pie, and if user wants all files to use extents, not just the new ones, user runs defragmentation on the newly converted Ext4 FS and there you have it ;). Also, journal checksumming applies to all files, whether they use extents or not, doesn’t matter…
User has a 1TB disk as XFS -> cannot upgrade easily to Ext4 without copying the full 1TB to another disk, formatting the 1TB disk as Ext4 and then copying files back to the Ext4 disk. If user sticks with XFS but wants extra integrity for his files, there’s no easy way to provide it under XFS, unless you mount the FS with sync and/or add an UPS to your system.
Also, I tend to remember a while back you thought on openFATE that XFS wasn’t actively developed and as such one should not use it (and now you defend it?), until I pointed out to you there that XFS is very much alive
Well, until openSUSE supports ext4 i stick with XFS, it’s not yet possible to defrag an ext4 partition I’d use ext4 for my /root partition (and i do since i write from 11.2 M2 )
You lost your bookmark because You used xfs on a partition that constantly changes some files etc.
I do hope that devs will change the standard behaviour to minimize the write queues to bare minimum:)
I changed my mind since using an ext4 with openSUSE 11.1 was quite hard (something breaks and i wouldn’t be able to use the recovery DVD)
XFS is good for a lot of things but I wouldn’t trust it when it comes to integrity, as was one of the questions/concerns of the OP. Better go with something a bit slower but where you have a better chance at keeping your stuff when bad things happen and also an easier upgrade path if you wish to switch to Ext4 in the future. As for Ext4 defrag, google e4defrag Also this may help further ext4 online defrag (ver 0.8) [LWN.net]
Well to be honest i agree i’d use ext3 if i had many blackouts but only on my system partition like / or /var or /home since there are many write requests done from the system but for a partition with files like movies, mp3 files, anything that is only generally read i’d use something more efficient. While ext3 is a good all rounder it doesn’t even allow for the disk to settle
Yeah, I also use XFS but only on portable USB drives which don’t stay all time connected/mounted. I use these drives to store my enormous movie and music collection. But since the OPs concern is about integrity and I have no clue if he wants to use this drive as main or as a data one which is mounted all the time, it’s better to point out that he may have more problems with XFS than the other FSes if he has so many power outages. Also, people keep forgetting that XFS was designed (and still is) for enterprise-class hardware where UPS and fault tolerance are the norm, not the junk peecee HW most people want to use it on. XFS was never intended to run on laptops or other crappy unreliable systems, although the devs have done the best they can to allow XFS to be data-reliable as much as possible on such systems, still it’s not near the robust Ext3 when it comes to integrity
I agree completely with You:) I assumed that no one would use a whole 1 TB disk only for systemrotfl!
That would be just plain mad.
I’m thinking all the time about buying some cheap UPS to keep the juice coming just for that minute or too so that i’ll have some time to turn that **** beast off
I guess it’s safe to use ext4/xfs on laptops thanks to those batteries but boy i don’t like the idea that i can’t upgrade in the laptop anything except the memory or a hard disk :X
Thanks to the both of you for the discussion. This drive is my /home partition, so it gets written to and read from regularly.
You are correct that I am far more concerned with data loss than I am with speed, as I have had some bad experiences of data loss with power outages. I don’t have a UPS, and I do have a crappy system ;). I don’t think XFS is for me anyway since there is a multitude of small files (music and pictures) on this partition along with the large ones (dv home movies).
I recommend You use a separate partition for the big files. It’s just no use in having such a big partition, while this is of course completely up to You what You do with Your system but i just wouldn’t keep all those movies etc. in /home but on a separate partition. The only thing i use /home is to keep my .mozilla folder inside it and to keep the KDE settings rotfl!
You make a good point. I have 4 physical drives with 8 partitions (including Windows drives), and was trying to limit the number of partitions I have to keep track of and simplify backups. (See, I said it was a crappy system…) I’ll consider moving my /home stuff to one of the smaller partitions and separate the big ones into divisions for movies/pictures/music/etc.
On Thu, 2009-06-18 at 15:56 +0000, BenderBendingRodriguez wrote:
> Yes, as default ext3 takes 5% of space so in that case it takes a lot
> You can always set it to 0% if You’d like. I guess if that is not a root
> partition then those 5% are not needed
The “root” minspace thing is pretty historical. But I thought things
had been done to prevent the HUGE 5% figure on large filesystems… but
whatever.
Regardless, the filesystem do operate differently. Reiserfs by default
does include tail packing which CAN result in some large space
improvements. Also, the size of the journal, etc. will vary.