Want to win a PS4? Go Premium and enter to win our High-Tech Treats giveaway. Enter to Win


How do I recover missing files on an ext3 hard drive?

Posted on 2004-10-21
Medium Priority
Last Modified: 2013-12-15
We have a Linux computer that lost power, without being powered down properly. Its now missing a critical directory, containing about 1000 critical files.

How would I recover that data?
Question by:Risky101
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions

Expert Comment

ID: 12377572
When you brought the system back up was not a fsck run on it?  What was the result?

More newer distros use some kind of journaling file system, such as ext3.   Give us a bit more information and perhaps we can help you out.

Author Comment

ID: 12377603
Its an ext3 file system, running on Fedora 2. Another system we have is running on Redhat 9.1 - we've had the same symptoms on it too.

Running fsck.ext3 on it made no difference.

Author Comment

ID: 12377616
Is there some way we could use an alternate superblock? Would that possibly fix the problem?
Technology Partners: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!


Author Comment

ID: 12377632
As more clues, the directory contains about 1,000 .png files. The directory is called "data". We need to recover this directory, and the .png files contained in it.
LVL 17

Expert Comment

ID: 12378814
Have you tried any of the undelete tools? They were developed for ext2 but ext3 is just ext2 with journalling support. Have a look at

Author Comment

ID: 12385504
Sorry, this wont work. From http://e2undel.sourceforge.net/how.html:

"The following applies only to ext2. Even ext3, despite its compatibility with ext2, behaves in one crucial point differently from ext2 (see below), so undeleting files on ext3 requires a completely different approach."

In addition, the e2undel page does not mention ext3 compatibility.

Accepted Solution

NYCmitch25 earned 1000 total points
ID: 12646065
*** BAD NEWS! ***

Q: How can I recover (undelete) deleted files from my ext3 partition?
Actually, you can't! This is what one of the developers, Andreas Dilger, said about it:
In order to ensure that ext3 can safely resume an unlink after a crash, it actually zeros out the block pointers in the inode, whereas
ext2 just marks these blocks as unused in the block bitmaps and marks the inode as "deleted" and leaves the block pointers alone.

Your only hope is to "grep" for parts of your files that have been deleted and hope for the best.

A:  sounds like mirroring or backups is the only saving grace!

Author Comment

ID: 12650706
Thanks for this. We have implemented a backup policy.

Featured Post

Hire Technology Freelancers with Gigs

Work with freelancers specializing in everything from database administration to programming, who have proven themselves as experts in their field. Hire the best, collaborate easily, pay securely, and get projects done right.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Using 'screen' for session sharing, The Simple Edition Step 1: user starts session with command: screen Step 2: other user (logged in with same user account) connects with command: screen -x Done. Both users are connected to the same CLI sessio…
Setting up Secure Ubuntu server on VMware 1.      Insert the Ubuntu Server distribution CD or attach the ISO of the CD which is in the “Datastore”. Note that it is important to install the x64 edition on servers, not the X86 editions. 2.      Power on th…
Learn how to navigate the file tree with the shell. Use pwd to print the current working directory: Use ls to list a directory's contents: Use cd to change to a new directory: Use wildcards instead of typing out long directory names: Use ../ to move…
Connecting to an Amazon Linux EC2 Instance from Windows Using PuTTY.
Suggested Courses

610 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question