From: "Fajar A. Nugraha" <list@fajar.net>
To: Michael Stephenson <mickstephenson@googlemail.com>
Cc: linux-btrfs@vger.kernel.org
Subject: Re: Filesystem corrupted, is there any hope?
Date: Fri, 24 Jun 2011 20:46:19 +0700 [thread overview]
Message-ID: <BANLkTi=1Jpc9E-XW8jY6uVYhukMTL2W_vQ@mail.gmail.com> (raw)
In-Reply-To: <BANLkTikLCk9=_CgXUWUTf91x7Aiyhuvndg@mail.gmail.com>
On Fri, Jun 24, 2011 at 5:16 PM, Michael Stephenson
<mickstephenson@googlemail.com> wrote:
> Hello,
> I formatted my home partition with btrfs, not realising that the fsck
> tool can't actually fix errors, as I have just discovered on your
> wiki.
> Had I knew this I would have not used it so early, this detail you
> would think would make distributions wary to make it an option on the
> livecd with no warning that if you ever have a power cut you are most
> certainly going to lose your data even if your hardware is fine.
> Anyway is their any hope? Is there beta code for an fsck that can do
> repairs? How long do I have to wait before there is? I can always just
> wait for a few months to get the data back.
That depends on what kind of corruption you have (dmesg / syslog
output would be nice)
For some cases, you can try:
- "btrfsck -s1", and if can finish without errors, try btrfs-select-super
- if it complains about some transid not available, try btrfs-zero-log
both btrfs-select-super and btrfs-zero-log need to be compiled
manually from source (i.e. "make btrfs-select-super" and "make
btrfs-zero-log"). if you use lzo, you might need the tmp branch
(http://git.kernel.org/?p=linux/kernel/git/mason/btrfs-progs-unstable.git;a=shortlog;h=refs/heads/tmp)
Some more suggestions:
- when possible, create a copy first of the device (e.g. with
dd_rescue) and work on the copy
- use "mount -o ro", and if readonly mount is successful, copy the
files somewhere safe and recreate your fs.
--
Fajar
next prev parent reply other threads:[~2011-06-24 13:46 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2011-06-24 10:16 Filesystem corrupted, is there any hope? Michael Stephenson
2011-06-24 13:46 ` Fajar A. Nugraha [this message]
2011-06-24 15:39 ` Michael Stephenson
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to='BANLkTi=1Jpc9E-XW8jY6uVYhukMTL2W_vQ@mail.gmail.com' \
--to=list@fajar.net \
--cc=linux-btrfs@vger.kernel.org \
--cc=mickstephenson@googlemail.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).