really strange ext4 behavior

Ric Wheeler rwheeler at redhat.com
Sat Feb 12 22:19:52 UTC 2011


On 02/12/2011 05:12 PM, Michał Piotrowski wrote:
> Hi,
>
> I added a disc to my box. I wanted to use ext4. I run fs_mark to test
> speed, to my surprise I heard a really strange noises.
>
> It's very strange because the drive is new
>    9 Power_On_Hours          0x0032   100   100   000    Old_age
> Always       -       12
>
>
> #  fs_mark  -d  test/
> [..]
> FSUse%        Count         Size    Files/sec     App Overhead
>       0         1000        51200         22.8            54347
>
> I decided to create an ext3 file system on this drive and everything works fine.
>
> #  fs_mark  -d  test/
> [..]
> FSUse%        Count         Size    Files/sec     App Overhead
>       0         1000        51200        103.7            57229
>
> When I mount this ext3 fs as ext4 and run fs_mark I hear strange sounds again.
>
> I use F14 and self compiled kernel from rawhide 2.6.37-1.fc14.x86_64 +
> e2fsprogs-1.41.14-2.fc14.x86_64.
>
> I mount ecryptfs on top of this file system.
>
> Does anyone know what might be causing this strange ext4 behavior?
>

Hi Michael,

fs_mark run a fsync heavy test. What you might be hearing is the impact of the 
fsync's. ext4 defaults to using "write barriers" enabled, ext3 does not. Without 
write barriers, those fsync push data from the box to the write cache on the 
drive only. With barriers, the disk will flush that cache to the platter, so the 
platter moves and you probably hear the head, etc.

You can test if this is the cause by mouting ext4 with "nobarrier" to see if the 
noise goes away.

Drives can be noisy, but occasionally, if they are over noisy (you hear 
chattering when writing), it might just be a bad drive that has trouble settling 
the heads after a seek.

You might want to check with:

  smartctl -a /dev/sda

To look for errors that the drive reports.

Good luck!

Ric



More information about the devel mailing list