"fsck -y /" keeps saying "Disk is still dirty" no matter how many times I run it

Polytropon freebsd at edvax.de
Fri Jan 8 20:17:32 UTC 2016

On Fri, 8 Jan 2016 12:11:43 -0800, Yuri wrote:
> As a result of the power outage I needed to run fsck on UFS disk with 
> soft-updates.
> But every time the command 'fsck -y /' says that it corrected a lot of 
> problems, but it still leaves the disk dirty. I ran it at least 15 times 
> - same result.

This seems to indicate a massive file system defect. Using
"fsck -fy /" enables fsck to use its full spectrum of repair
(in comparison to -p "preen mode"). Check if _the same_ problems
re-appear. In this case, they could not be fixed properly
and the file system won't get the "clean" indicator.

> What would be the way to proceed from here?

Re-initalize the file system and restore from a recent backup.
If you don't have one, you could try to backup from the damaged
file system with "dump", then run "newfs", and then "restore".

> (I ran fsck before, but it never happened that fsck keeps finding problems)

I've seen a comparable problem very few times, but usually
a second run of a forced full fsck solved the problem.

Are you sure the disk (!) doesn't have problems after the
power outage? It's possible that you're seeing a "hardware
issue" here.

Magdeburg, Germany
Happy FreeBSD user since 4.0
Andra moi ennepe, Mousa, ...

More information about the freebsd-questions mailing list