# Frequent file system corruption with ext4

## tnadav

My computer is behaving wird. I installed Gentoo on my computer three days ago.

At first everything worked great. After a while I experienced UI frezzes, and the only thing I could do is to reboot.

After that the system complains about file system corruption, so I log in to root, run fsck and reboot again and the system works fine until the UI Frezzes again.

The wired thing is that Mac OS X on my pc behaves exactly the same while it used to work great once, so I suspect there may be a hardware issue.

The problem with assuming that there is a hardware issue is that Windows 7 doesn't have this problem on my computer

So I have two questions:

Is there a known bug that can cause this problem?

How can I prove that I have or that I don't have a hardware issue?

----------

## audiodef

Go to http://www.sysresccd.org/ and make yourself a sysresccd. Boot up with it and run testdisk and other tools (there are many you can choose from). I can't bring the specific program to mind that does this (probably more than one, anyway) but you should be able to scan your disk for errors and cordon off bad sectors permanently. 

If, after doing this, you continue to have errors, it's probably time for a new hard disk.

----------

## John R. Graham

Hi, @tnadav. Welcome to Gentoo. I have two questions for you:What UI did you install?

What's the name of the main Gentoo document that guided you through the install process?- John

----------

## tnadav

 *audiodef wrote:*   

> Go to http://www.sysresccd.org/ and make yourself a sysresccd. Boot up with it and run testdisk and other tools (there are many you can choose from). I can't bring the specific program to mind that does this (probably more than one, anyway) but you should be able to scan your disk for errors and cordon off bad sectors permanently. 
> 
> If, after doing this, you continue to have errors, it's probably time for a new hard disk.

 

Thnaks, I'll look into it

 *John R. Graham wrote:*   

> Hi, @tnadav. Welcome to Gentoo. I have two questions for you:What UI did you install?
> 
> What's the name of the main Gentoo document that guided you through the install process?- John

 

I installed gnome 2.

I don't understand the second question, I used the Gentoo handbook for amd64 architecture

----------

## audiodef

 *tnadav wrote:*   

> 
> 
> I don't understand the second question, I used the Gentoo handbook for amd64 architecture

 

That's exactly what he meant.   :Wink: 

----------

## tnadav

sysresccd didn't really helped me (it only had testdisk which doesn't work on ext4)

however I noticed that the hard disk's temperature was too high, cleaned my computer from dust and now everything seems to be working well, I will update this thread in case I have more problems.

I will have to reinstall Gentoo, do you think that I should stick to ext3?

----------

## audiodef

Ubuntu has used ext4 as the installed fs for quite some time now, with nary a problem. I'm not sure why Gentoo people don't embrace it as much. It will eventually replace ext3 anyway, so I say go for it. I use it. If you use /root as /boot, I think there's an extra step somewhere you have to do to make sure grub gets along with ext4.

----------

## Naib

Been using ext4 on my home nas since ext4 went "stable" in the kernel and converted desktop when the issues surrounding it and kde were worked out 

no problems at all

----------

## DirtyHairy

Used ext4 for everything (/, /home, /usr/portage --- no separate /boot) when I installed my new laptop, and everything works perfectly. The gentoo grub ebuild seems to already apply the ext4 patches, so nothing special there either.

----------

## tnadav

 *audiodef wrote:*   

> Ubuntu has used ext4 as the installed fs for quite some time now, with nary a problem. I'm not sure why Gentoo people don't embrace it as much. It will eventually replace ext3 anyway, so I say go for it. I use it. If you use /root as /boot, I think there's an extra step somewhere you have to do to make sure grub gets along with ext4.

 

Ubuntu sucks so much I prefer Windows XP over it.

What about BTRFS?

----------

## gerard27

 *Quote:*   

> What about BTRFS?

 

Well sure replace a tested and tried fs with something alpha.

I also have been using ext4 for a long time w/o ANY problem.

Gerard.

----------

## Ant P.

Try reiser4, it has many of the features and speed of btrfs and has never eaten my data - unlike the newer and less stable ext4.  :Wink: 

----------

## tnadav

 *gerard82 wrote:*   

>  *Quote:*   What about BTRFS? 
> 
> Well sure replace a tested and tried fs with something alpha.
> 
> I also have been using ext4 for a long time w/o ANY problem.
> ...

 

I thought everything within the stable version of Linux Kernel is stable...

 *Ant P. wrote:*   

> Try reiser4, it has many of the features and speed of btrfs and has never eaten my data - unlike the newer and less stable ext4. 

 

Reiser4 isn't in the linux kernel, how do I use it for root?

----------

## DirtyHairy

Straight from menuconfig:

 *Quote:*   

>  CONFIG_BTRFS_FS:
> 
>  Btrfs is a new filesystem with extents, writable snapshotting,
> 
>  support for multiple devices and many more features.
> ...

 

----------

## Ant P.

 *tnadav wrote:*   

> Reiser4 isn't in the linux kernel, how do I use it for root?

 

Use zen-sources.

----------

## John R. Graham

 *Ant P. wrote:*   

> Try reiser4, it has many of the features and speed of btrfs and has never eaten my data - unlike the newer and less stable ext4. 

 Curiously enough, I had the same experience until recently. I started getting corruption and other somewhat bizarre symptoms with 2.6.38 and have switched to XFS as a result, which has been rock solid. I wasn't using Zen Sources, though; instead, I was patching Gentoo Sources with the Reiser4 patch set.

Glutton for punishment that I am, I'm preparing to experiment with ZFS.   :Very Happy: 

- John

----------

## Randy Andy

Hi Geeks.

I'm using ext4 since it went marked as stable into the kernel.

Shortly after this, i converted or installed all my 5 Gentoo boxes from ext3, xfs, jfs, and reiser to ext4. 

For me it was an improvement regarding cpu load, speed, out of the box working filessytem check and speed oft it.

In the meantime there was lots of improvements of the ext4 system, which makes it at least as stable and performant as the others named above, if you would like to trust some published benchmarks.

Until now, i had never a corrupted ext4 filesystem of any lsot of data.

You can use it as root and boot filesystem as well since it was stable, cause at the same time it exist a patched version of GRUB legacy, which makes it possible to boot from.

Lilo and GRUB2 has no problems at all with it afaik.

So i sware on it and will use it until BTRFS is stable. Then i would like to test it and if it's good enough for me i will give it eventually a chance, to be my future filesystem of choice.

I would like the idea of a snapshotting filesystem without an additional layer like lvm, so lets see...

Only my 50 cent.

Best regards, Andy.

----------

## dusanc

 *Ant P. wrote:*   

>  *tnadav wrote:*   Reiser4 isn't in the linux kernel, how do I use it for root? 
> 
> Use zen-sources.

 

I would advise against using R4 from zen-sources, but patch gentoo-sources with R4.

And you'd have to use .38 or .37, but I'd rcomend .37  :Very Happy: 

----------

