How does the number of subdirectories impact drive read / write performance on Linux?

This is easy to test the options for yourself, in your environment and compare the results. Yes, there is a negative impact on performance as the number of directories increases. Yes, other filesystems can help get around those barriers or reduce the impact. The XFS filesystem is better for this type of directory structure. ext4 … Read more

Is post-sudden-power-loss filesystem corruption on an SSD drive’s ext3 partition “expected behavior”?

You’re both wrong (maybe?)… ext3 is coping the best it can with having its underlying storage removed so abruptly. Your SSD probably has some type of onboard cache. You don’t mention the make/model of SSD in use, but this sounds like a consumer-level SSD versus an enterprise or industrial-grade model. Either way, the cache is … Read more

Running out of memory running fsck on large filesystems

A 64 bit kernel and large quantities of RAM will allow the fsck to finish nice and fast. Alternately, there’s now an option in e2fsck that’ll tell it to store all of it’s intermediate results in a directory instead of in RAM, which helps immensely. Create /etc/e2fsck.conf with the following contents: [scratch_files] directory = /var/cache/e2fsck … Read more

What are the differences between ext3, ext4 , ReiserFS?

Taken from: Linux Filesystem Primer EXT2 Recommended to move to EXT3 Not Journaled POSIX access control EXT2 file system is the predecessor to the EXT3 file system. EXT2 is not journaled, and hence is not recommended any longer (customers should move to EXT3). EXT3 Most popular Linux file system, limited scalability in size and number … Read more

How do I list a file’s data blocks on Linux?

You could use the “debugfs” tool to view file info on the command line or interactivley. either use: # debugfs /dev/<spartition> # stat /path/to/file or # debugfs -R “stat /path/to/file” /dev/<partition> for example: # debugfs -R “stat /etc/passwd” /dev/sda5 Inode: 435914 Type: regular Mode: 0644 Flags: 0x0 Generation: 979004472 Version: 0x00000000 User: 0 Group: 0 … Read more

Production-ready, highly reliable filesystems on Linux: ext4 ext3 XFS or JFS (or ZFS)?

ZFS on linux is unfortunately still not a viable solution, even if you dismiss the issue of being a FUSE module (which can seriously cramp performance on certain workloads). It simply isn’t complete enough. Also, I don’t think there’s a debugfs for ZFS on linux, which is a serious negative. debugfs is the traditional name … Read more

How do you re-mount an ext3 fs readwrite after it gets mounted readonly from a disk error?

I just recently ran into this problem and solved it by rebooting but after further investigation it appears that issuing the following command might fix it. echo running > /sys/block/device-name/device/state I think you might want to look at look at section 25.14.4: Changing the Read/Write State of an Online Logical Unit in this document, however, … Read more