Ask Ubuntu is a question and answer site for Ubuntu users and developers. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I've accidentally formatted one of my partitions with btrfs 0.19 filesystem, on 11.04, kernel 2.6.38-8-generic.

The command issued was:

mkfs.btrfs -L EADS-old /dev/sdd2.

After this I didn't write anything on this disk, it was only mounted few times. And the disk is obviously clean at a first glance.

How do I recover the data from it? It has quite a lot valuable data and I don't afford to backup the whole 1T of data.

I've tried testdisk program but I was unable to find any partitions nor usable data.

share|improve this question
Not confident enough for giving an answer to this as I've never used BTRFS and don't know how widely supported. But have you tried RIP Linux? Mayhaps it has more up to date support for newer filesystems than Ubuntu. – user6658 Sep 12 '11 at 19:47
Thank you, I've googled for hours, but nothing easy and valuable is found. I'll try this also. Testdisk is not working (found just some junks), after all the partitions are unchanged. Photorec did extract housands of files, but this is huge mess and mostly unusable :( – piotao Sep 13 '11 at 9:03
If you don't backup your data, sooner or later you WILL loose it. I'm afraid you're just going to have to chalk this up as lesson learned. – psusi Sep 13 '11 at 13:43
No, I don't used this disks since this time, hoping some day I'll recover them. They were mounted several times in RO mode and some analysis was done by restoring software, but no luck. I extracted 600GB of files in thousands of dirs, with numerical names, and that's all. Maybe I should try again nowadays, when btrfs tools matured? – piotao Jun 24 '12 at 17:25
Any news on this? I'm really curious how easy it is to recover a formatted btrfs filesystem. – user1202136 Aug 1 '14 at 8:33
up vote 2 down vote accepted

Try PhotoRec but seen the date of your question you probably removed more/all data in the mean while. PhotoRec does not explicity support BTRFS, but it works filesystem agnostic.

share|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.