Solved

fat32 accidentally converted to ext3, any way back?

Posted on 2002-07-24
9
221 Views
Last Modified: 2011-10-03
I had win98 and winxp running on my pc, but since xp gave me more bluescreens then 98 :-/ i wanted to install linux
So i made a boot partition and root partition with PM
after which i had a boot (100mb) and root (2gb) on my hd (before other partitions)
see http://users.pandora.be/temmer/images/hds.jpg

started gentoo from cd, and did "mke2fs -j /dev/hda1"
knowing that my first partition is the linux boot
then "mke2fs -j /dev/hda2" which gave an error msg
BUT: the table entries were not in disk order :(

device start end  system
hda1   273   1743 win95 fat32
hda2   1744  2069 win95 ext
hda3   1     13   linux
hda4   14    272  linux
hda5   1744  2069 ntfs


So i lost both my OS's and all data on it :(
i was wondering if there's any way to recover something
(i heard i could dump a whole partition, but how am i supposed to get data out of it?)

TIA for any response,
Temmer



*kicks himself* now why did i do that?
0
Comment
Question by:Temmer
9 Comments
 
LVL 51

Accepted Solution

by:
ahoffmann earned 100 total points
ID: 7175833
you my dump a partition to file like:

   dd if=/dev/hda2 of=/tmp/hda2.dump

make shure that /tmp is not on hda2, for obvious reason.
Then you can examine /tmp/hda2.dump with a tool of your choice. For example:

   strings /tmp/hda2.dump

will give you most of your ASCII data back, probaly not in the order of the original file, but it's more than nothing.
0
 

Author Comment

by:Temmer
ID: 7176727
The only problem now is that the partition has around 10GB of data, but i think i got enough space

Is there any header between the files in that dump, so i can quickly (relatively to the 10GB ;) find files in there?
0
 
LVL 51

Expert Comment

by:ahoffmann
ID: 7178377
dd produces a binary dump.
It contains all data unsorted, just as the filesystem sees it. Because the fs uses datablocks, your files might be split in sevaral blocks across the fs, then they are not in a continous stream within the dump.
0
 
LVL 4

Expert Comment

by:Robson
ID: 7179693
<voice type="Agent Smith">Your files are already dead</voice>

Lucky for you that mke2fs writes only a little data on it. Do as ahoffmann says, and you recover most of your ASCII data. If you want more, give your dist to some data recovery company and pay them $. Anyway, I doubt they will be of much success, because you overvrited FAT with ext2 superblock.
0
Windows Server 2016: All you need to know

Learn about Hyper-V features that increase functionality and usability of Microsoft Windows Server 2016. Also, throughout this eBook, you’ll find some basic PowerShell examples that will help you leverage the scripts in your environments!

 

Author Comment

by:Temmer
ID: 7179904
"Your files are already dead"
thought so ... :(

Anyway, i lost 2 windowses, oh boy i really care :p

The only things i really need are a few serials and passwords, so i should find it (somewhere) in the dump


Thx for the info, i'll start dumping it, format and reinstall winblows ;)
0
 
LVL 51

Expert Comment

by:ahoffmann
ID: 7180047
what do you need linux passwords for when you go back to windoze?
0
 

Author Comment

by:Temmer
ID: 7181845
Just all sorts of passwords, nothing with linux passwords ;)

And is it possible to split the dump? cause i dont have any partition large enough do dump it on
0
 
LVL 51

Expert Comment

by:ahoffmann
ID: 7182165
dd bs=8192 count=500000 if=/dev/hda2 of=/tmp/hda2.dump1
dd bs=8192 count=500000 skip=500000 if=/dev/hda2 of=/tmp/hda2.dump2
0
 
LVL 1

Expert Comment

by:enthusiast78
ID: 7188575
 I believe that if mkfs really did it's job on your partition, it's gone. But if the error message you mention was something like it couldn't actually create the filesystem, you can always enter "fdisk" and just change the partition type back to it's original value. Course, if you don't remember which one was, since there are lots of types for MS partitions, you might have to play test and reboot a little bit, but if you really care about your data, it could be rewarding.

  Hope this helps.
0

Featured Post

6 Surprising Benefits of Threat Intelligence

All sorts of threat intelligence is available on the web. Intelligence you can learn from, and use to anticipate and prepare for future attacks.

Join & Write a Comment

Introduction We as admins face situation where we need to redirect websites to another. This may be required as a part of an upgrade keeping the old URL but website should be served from new URL. This document would brief you on different ways ca…
This article will explain how to establish a SSH connection to Ubuntu through the firewall and using a different port other then 22. I have set up a Ubuntu virtual machine in Virtualbox and I am running a Windows 7 workstation. From the Ubuntu vi…
Learn how to get help with Linux/Unix bash shell commands. Use help to read help documents for built in bash shell commands.: Use man to interface with the online reference manuals for shell commands.: Use man to search man pages for unknown command…
This demo shows you how to set up the containerized NetScaler CPX with NetScaler Management and Analytics System in a non-routable Mesos/Marathon environment for use with Micro-Services applications.

744 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

Need Help in Real-Time?

Connect with top rated Experts

11 Experts available now in Live!

Get 1:1 Help Now