Re: cleanup after a small data loss on incorrect shutdown.

Chris Mason
2009-06-12T11:42:30Z

On Fri, Jun 12, 2009 at 03:08:58PM +0400, Michael Raskin wrote:
> Chris Mason wrote:
> >> 2. I found a file which is listed in the directory, but stat on it
> >> returns "No such file or directory". Certainly, rm and unlink cannot
> >> remove it. The partition has 14G in use. What can I do to provide a
> >> useful piece of FS structure information? How can I remove the file
> >> afterwards.
> >
> > I'd say to send us the btrfsck output, it will help answer these
> > questions.
>
> Oh, easily. "Bad block <number way beyond partition block count>".

Btrfs deals in byte numbers not block numbers ;)

> That's all. Reading one of the damaged file actually returned
> "Input/output error" - probably it tried to read beyond end-of-device. I
> had to kill this file (practical testing means that to continue to use
> my notebook normally I had to nuke the damaged file and get intact
> copies). The "no such file except in readdir" is still there right now.

Ok, btrfsck will give us more output when it finishes, but it hasn't
finished. It would help to use btrfs-image to send us a coyp of the
metadata so we can fix the btrfsck bug.

-chris