View Full Version : Bricked my Internal Flashspace
11-02-2010, 05:48 AM
I somehow managed to dd zeros onto the beginning /dev/mmcblk0. Please don't ask why or how someone can be that stupid, it is embarrassing enough :o
Is there some way to fix the partition table or at least get as much data recovered as possible?
Thanks in advance
11-02-2010, 06:50 AM
Does your N900 still boot? If yes, then it'd be pretty easy just to recreate the broken partition table, reboot, recover what's left, and then start over.
This is a dump from my N900, yours should be identical.
# sfdisk -d /dev/mmcblk0 > partitions
# cat partitions
# partition table of /dev/mmcblk0
/dev/mmcblk0p1 : start= 64, size= 56631296, Id= c
/dev/mmcblk0p2 : start= 56631360, size= 4194304, Id=83
/dev/mmcblk0p3 : start= 60825664, size= 1572864, Id=82
/dev/mmcblk0p4 : start= 0, size= 0, Id= 0
You could create a file on your N900 and paste the above text in, then run:
# sfdisk --no-reread /dev/mmcblk0 < filename
This should let you remount - though it might give some errors, you may need to run fsck - probably you will have to specify an alternate superblock.
Finally, you're not alone, I've done this, sadly more than once : )
11-03-2010, 06:40 AM
Thanks a lot for your help. I at least got the linux and the swapspace up and running again. But I completely bashed my FAT partition. Whe trying to fsck it, I get the error: Logical sector size is zero. The solution of copying sector 6 to sector 0 didn't work for me for I killed both with my dd command. Is there a way to recover the filesystem or at least some of the files (esp. the backupfiles)?
vBulletin® v3.8.7, Copyright ©2000-2013, vBulletin Solutions, Inc.