View previous topic :: View next topic |
Author |
Message |
koenvl n00b
Joined: 08 Jan 2004 Posts: 13 Location: Brussels, Belgium
|
Posted: Thu Jan 08, 2004 10:15 pm Post subject: formatted windows partition by mistake |
|
|
Hi,
Today I did:
while I wanted to do:
hda1 is my windows partition.
It's not my first time installing Gentoo, just a stupid mistake at 3 h xx AM :-s
Does anyone know how to undo this, or at least how to recover the data on hda1 in this case?
Greets,
Koen Van Lindt |
|
Back to top |
|
|
LinuxTechnologies n00b
Joined: 10 Aug 2003 Posts: 40 Location: England
|
Posted: Thu Jan 08, 2004 10:30 pm Post subject: |
|
|
Not a chance. You've wiped the entire partition. You can only learn from your mistakes - there's no "Are you sure?" when it comes to Linux. |
|
Back to top |
|
|
uglyb0b Apprentice
Joined: 07 Sep 2003 Posts: 280
|
Posted: Thu Jan 08, 2004 11:55 pm Post subject: |
|
|
make2fs -j..... it wipes the partition. if you'd deleted it with windows, then you could recover, but ext3 wiped it. sorry. _________________ Blog.
Linux geek and Mac whore. |
|
Back to top |
|
|
GhostBear n00b
Joined: 05 Feb 2003 Posts: 27 Location: Canada, eh?
|
Posted: Fri Jan 09, 2004 4:50 am Post subject: |
|
|
Don't worry, you don't know it yet... but you just did yourself a favour |
|
Back to top |
|
|
st. anger Apprentice
Joined: 30 Oct 2002 Posts: 273
|
Posted: Fri Jan 09, 2004 4:56 am Post subject: |
|
|
i made the same mistake once. lost 10 gigs of mp3s.
it happens. _________________ pizza. |
|
Back to top |
|
|
Ateo Advocate
Joined: 02 Jun 2003 Posts: 2021 Location: Republic of California
|
Posted: Fri Jan 09, 2004 5:37 am Post subject: |
|
|
A favor you have done yourself indeed..... =P |
|
Back to top |
|
|
rsk Apprentice
Joined: 18 Apr 2002 Posts: 220 Location: Tucson, AZ
|
Posted: Fri Jan 09, 2004 6:16 am Post subject: |
|
|
This is deja vu to the first time I ever installed Linux... it was RedHat 5.0, i was in the chat room at the same time trying to figure out how to mount my windows partition from Windowmaker... and some very helpful dipshit in the room told:
"sure its easy, just type mkefs -j /dev/hda1" I thought "How strange" but whatever, I knew nothing about Linux... so I typed it and watched it run and run and say something about formatting which set the bells off, so I CTRL-C'd it and asked Mr. Helpful what that command did, he replied "It formats your partition"... I almost blew my top, when I asked why he had suggested I do that when I clearly asked about mounting my parition, he replied "Woops, didn't read your question clearly enough"...
So anyway, that was a 5 year old hard drive that had never been backed up in its life... not that I lost anything important, it was all just sentimental stuff that would have ended up on a CD in a closet somewhere anyway.
So to make a long story short, I feel your pain, but there is nothing to do. This isn't like sending a file to the recycle bin then going "woops!", what you just did is told your computer to "smite everything on my hard drive and wash it clean of all its sins", so it did just that _________________ Best,
Riyad |
|
Back to top |
|
|
Ateo Advocate
Joined: 02 Jun 2003 Posts: 2021 Location: Republic of California
|
Posted: Fri Jan 09, 2004 7:19 am Post subject: |
|
|
LMFAO @ rsk... That bring memories from my days of megabit support and the n00bie support techs coming in...
Whoops. I OD'd. |
|
Back to top |
|
|
rinnan Tux's lil' helper
Joined: 24 May 2003 Posts: 138 Location: Honolulu, Hawai`i
|
Posted: Fri Jan 09, 2004 9:08 am Post subject: not a 100.0% loss, just a 99.99% loss. |
|
|
While it's true that the command you typed overwrote important filesystem information in your partition, it's probably not (quite) as bad as what's being said here. Not every single byte of every single sector has been overwritten. With a file salvage utility, it may be possible, depending on the precise position of the desired file on the drive, to recover single files here and there. So if there's a specific file you need, or a small number, and you know what they are called and where they are, it may yet be possible to partially or entirely salvage a few of them. Simple text files might be findable by searching the partition at a byte-position level using a sophisticated enough hex editor and searching for strings that you know are in the file. Compressed files, binary files, and so on are pretty much entirely unrecoverable, and recovering any file in it's entirely is very unlikely. I've done this and was still able to recover, partially, a plain text file with an important phone number in it, for example.
Erik |
|
Back to top |
|
|
koenvl n00b
Joined: 08 Jan 2004 Posts: 13 Location: Brussels, Belgium
|
Posted: Fri Jan 09, 2004 9:38 am Post subject: |
|
|
ok, thanks everyone. Looks like I have indeed lost a bunch of MP3s and some school work. The most important files I've got on CDR, so that's a relief.
But I would still want at least to _try_ recovering some files. I'm curious what mke2fs has left on my HD.
Koen |
|
Back to top |
|
|
Ateo Advocate
Joined: 02 Jun 2003 Posts: 2021 Location: Republic of California
|
Posted: Fri Jan 09, 2004 12:25 pm Post subject: |
|
|
You have performed the equivalent to format c: /u /s. So mke2fs has left nothing but a nice, clean formatted partition. There is no recovering data after you perform an ext2 format. Sorry to burst your bubble....
You're not dealing with a low level format here as can be done with fat16/32/ntfs so I'm not sure an file recovery utility can be used. |
|
Back to top |
|
|
naughtgone n00b
Joined: 09 Jan 2004 Posts: 1
|
Posted: Fri Jan 09, 2004 1:32 pm Post subject: maybe! |
|
|
I did the same thing on my XP box. Rewrote the partition table and all, then did a mke2fs, mkswap and mkreiserfs for the new partitions.
So after I realized what I had done I was very... err... distressed, and looking up data recovery companies.
However, I went back into fdisk, deleted all the partitions, remade my original partition table (just one large NTFS). The XP CD sees the install there, and I actually booted it up and looked at some pictures, although it seems corrupted (ie very unstable).
Still, much better than nothing. |
|
Back to top |
|
|
eeyrjmr n00b
Joined: 17 Nov 2003 Posts: 38
|
Posted: Fri Jan 09, 2004 2:19 pm Post subject: |
|
|
mkefs -j /dev/hda1 does not wipe the HD it just overwrites the TOC of the harddrive.
I started off with a "shread" on my hda1 and that took hours to go through 30gig but mkefs only took abt 2min.
However, although the majority of yr raw data is still on your harddrive it is near on impossible to get it back without spending weeks going through all the sectors |
|
Back to top |
|
|
piquadrat Guru
Joined: 18 Feb 2003 Posts: 301 Location: Switzerland
|
Posted: Fri Jan 09, 2004 2:19 pm Post subject: |
|
|
Same happened to me once. I installed Gentoo for the second time and didn't want to download all the sources all over again. So I copied them to my data partition (which was FAT32 by then), wiped out Gentoo, booted the LiveCD and mounted the data partition to copy back the distfiles. A few minutes later, something went wrong and I decided to rm -rf /* Gentoo again for a new start...of course I forgot that the data partition was still mounted...mp3, work data, mails, all gone
Well, long story short, I could recover the most important stuff with some tool by Ontrack or something (it has a price tag, though...). It scans the disk for patterns of filetypes like *.doc, *.jpg, *.mp3, and tries to recover them, but without the filenames. It works better if the partition wasn't fragmented to much.
It won't give you a full recovery, but with a good portion of luck, you will find some of your important data again. |
|
Back to top |
|
|
sciwhiz007 n00b
Joined: 01 Jan 2004 Posts: 31 Location: /dev/random
|
Posted: Sat Jan 10, 2004 5:34 pm Post subject: |
|
|
Wow, brings back memories of installing Gentoo a long time ago. I did the exact same thing, and a typo of 1 number made me lose Windows and everything in C:. Luckily I had the fortune to have divided up my drive into partitions with none of my personal files on C:, so I didn't lose anything in the process.
This makes me think, why can't mke2fs display a confirmation statement like mkreiserfs does? But then again, most of us are so used to questions, wizards and the like that we tend to mindlessly choose the default response.
Pays to be careful... _________________ You can take a horse to water but you can't make it drink.
You can give a person facts, but you can't make them think. |
|
Back to top |
|
|
d_adams Apprentice
Joined: 20 Oct 2003 Posts: 223
|
Posted: Sat Jan 10, 2004 9:23 pm Post subject: |
|
|
One last try, this may or may not work for you, but has for me in the past. Don't give up all hope yet, if you haven't done anything else to the drive. Four words "Easy Recovery Pro 6" or the latest version if you can find it. It will go through a formatted drive and recover data in several different ways, including raw data recovery. You need a spare drive to do this, and as far as I know it's a windows only program, but can recover deleted/formatted data from a drive.
I've used this numerous times for clients that hosed their servers and had lost $$$ trying to re-create that data from scratch. They pay through the nose if they know you can recover 3 months of hard work that they were too stupid to back up. No matter how many times you tell them, they just don't listen. In your case it was an accident, but I have one client that does this every 6 months and they pay me an average of $1500-3000 a year just to recover from their secretary or boss's screw-ups. _________________ http://www.1and1.com/?k_id=16196755 click me for cheap linux based web hosting. |
|
Back to top |
|
|
koenvl n00b
Joined: 08 Jan 2004 Posts: 13 Location: Brussels, Belgium
|
Posted: Sun Jan 11, 2004 6:03 pm Post subject: |
|
|
Yup, I found Ontrack Easy Recovery Pro 6 and I've got a spare HD in the box. I'll try it out after my exams. But, hey, I still got that back-up from a week ago, so /me is still safe. Just my father's accountancy which has not been backed-up (how do you say that) for a month or two and some other stuff. But we will fix this thing right :-p
Tnx everyone!
Koen |
|
Back to top |
|
|
piquadrat Guru
Joined: 18 Feb 2003 Posts: 301 Location: Switzerland
|
Posted: Sun Jan 11, 2004 6:53 pm Post subject: |
|
|
BTW: before playing around with the damaged partition, I'd make a full image with dd. So if anything goes wrong, you can begin from sctatch. But since you've got a recent backup, it may not be worth the hassle... |
|
Back to top |
|
|
Omegaice n00b
Joined: 18 Sep 2005 Posts: 15
|
Posted: Sat Mar 11, 2006 12:15 pm Post subject: Drive Fat Table |
|
|
Ok sort of related to installing but i didnt know where else to put this, i installed gentoo onto my second drive but when i was formating the disks i accidently started formatting my windows download drive(40gb of downloads *cries*), i canceled it as quickly as possible.
Is there any way to get the drive back? because the data should be mostly in tact. |
|
Back to top |
|
|
Keruskerfuerst Advocate
Joined: 01 Feb 2006 Posts: 2289 Location: near Augsburg, Germany
|
Posted: Sat Mar 11, 2006 12:57 pm Post subject: |
|
|
No. |
|
Back to top |
|
|
sternklang Veteran
Joined: 10 Sep 2005 Posts: 1641 Location: Somewhere in time and space
|
Posted: Sat Mar 11, 2006 5:15 pm Post subject: |
|
|
Short of sending the drive to a data recovery service (which will cost you hundreds of dollars) I'm not sure what you can do. There may be data recovery software for Windows that can do it, but the better software will also cost hundreds and require some knowledge of hard disks, partitioning and file system structures to properly recover the data. There's no quick "unformat" or anything like that in linux, if that's what you're asking.
Sorry to be the bearer of bad news. |
|
Back to top |
|
|
nixnut Bodhisattva
Joined: 09 Apr 2004 Posts: 10974 Location: the dutch mountains
|
Posted: Sun Mar 12, 2006 4:02 pm Post subject: |
|
|
merged above three posts here. _________________ Please add [solved] to the initial post's subject line if you feel your problem is resolved. Help answer the unanswered
talk is cheap. supply exceeds demand |
|
Back to top |
|
|
nephros Advocate
Joined: 07 Feb 2003 Posts: 2139 Location: Graz, Austria (Europe - no kangaroos.)
|
Posted: Thu Mar 16, 2006 9:14 pm Post subject: |
|
|
Just to summarize a bit here:
It is NOT true that mkfs destroys all information on the partition - at least not with ext filesystems. It basically only writes some inode information, which is actually a very small part of the disk.
Therefore, most of the data on the disk will still be there, and using certain forensic tools ( e.g. dd and grep ) can likely recover most of them taken enough time and determination.
It is however very unlikely that one will be able to restore that filesystem to a consistent state either. Trying can't hurt though I guess, but possibly it will only make it worse.
As for data recovery companies - well just look at their price lists.
Calculate if doing your lost work again isn't cheaper than their services - it most likely is.
Also: Welcome to the TWKBH-club. (Those Wo Keep Backups Handy) _________________ Please put [SOLVED] in your topic if you are a moron. |
|
Back to top |
|
|
|