Urgent fsck help

Associate
Joined
14 Jan 2010
Posts
662
Hi,

I know you can do touch forcefsck or run shutdown -rF now to run fsck upon reboot but as far as I'm aware it may still require user intervention; is that correct?. Is there a way of running it without any user intervention and set it up to fix all errors?

It's a ubuntu server btw.

Thanks
 
If you edit /etc/default/rcS and enter FSCKFIX=yes, when you next reboot it should perform a fsck and fix any errors automatically...if it is in a particularly bad state though it may still require intervention

Scott
 
Cheers Scott.

It has errors on one of the partition (/var)I believe but I was thinking of doing the whole disk. How long will it approximately take to run with about 800GB (thousands of files!) of data? it's a production server so I don't want it to take 3 days and be offline :(
 
What state is the server currently in? Not too good I take it? (based on the 'urgent' in your thread title)

Where did you get the information from that it has got fs errors? (just confirming as you didn't sound 100% sure?)

If you can't afford too much downtime on the server at the moment or you wish to schedule a more convienient time to do a more thorough check then it might be worth just running a fsck on /var (if you are sure).

What filesystem are you using? ext4 has quicker fsck times than ext3. How much memory is in the server? etc.

Scott
 
Intermittent "ext3 fs error start transaction" is what I'm getting on one of the partitions and when it happens the server is not accessible from the network. I will run the fsck on /var.

Thanks for your help.
 
Cheers Scott.

It has errors on one of the partition (/var)I believe but I was thinking of doing the whole disk. How long will it approximately take to run with about 800GB (thousands of files!) of data? it's a production server so I don't want it to take 3 days and be offline :(

Can't speak for ext3, but a FSCK on a full 2tb XFS filesystem (Clean, no errors) takes about an hour here.
I'd say two, maybe three hours if the system is in a bad way :)

Also you need to consider the root cause of the errors. Either you're having unclean shutdowns (Not good on a production server!), or there's a disk or other hardware issue. If you can I'd update the kernel to the latest, and I'd also seriously consider taking a full backup and swapping out the disk.
I'd also be running a memtest, but I dunno how much downtime you can afford.

-Leezer-
 
Back
Top Bottom