Page 1 of 1
GParted has lost a partition. How to get it back?
Posted: Fri 10 Aug 2012, 19:47
by gcmartin
Trouble with Puppy implementation of GPARTED.
This problem has happened in just about every Puppy tested today.
I was called by a friend who has made a mistake. She, in looking over GPARTED has inadvertently deleted and formatted an EXT4 partion from her hard-drive. (She actually thought she was working on an adecent partition on a 3 partition HDD.
I was asked to take a look at the Puppy desktop. GParted is suppose to have a recovery feature that is present in its screen's menu, Device>AttemptDataRescue, but, someone, somewhere has deprecated (or broken) GParted!
Questions
- Has this already been addressed?
- Could this be fixed in the future?
Lastly
- Do you have any recommendation for partiton recovery in Puppy Linux should this happen to anyone else?
Thanks in advance for ALL helpful mentions
Posted: Fri 10 Aug 2012, 20:00
by DPUP5520
Hey man I just got your message, Gparted has always had a few small problems in Puppy that were never fully resolved, rescuing partition data using the CLI should work just fine however, if the data is indeed recoverable. Unfortunately no laptop right now to test
Posted: Fri 10 Aug 2012, 20:31
by rcrsn51
The versions of Gparted that have the data recovery feature also need the "gpart" utility. Since no Puppy appears to have this, I pulled it out of Debian and packaged it as a PET below. But I didn't actually test it on live partitions.
Posted: Fri 10 Aug 2012, 22:53
by Peterm321
If gparted/gpart doesnt provide a solution, maybe testdisk/photorec could help.
You may find it helpful to make an image backup of the mistakenly overwritten partition before reformatting or copying files to it.
http://www.murga-linux.com/puppy/viewto ... 01&t=77288
Posted: Fri 10 Aug 2012, 23:19
by Karl Godt
I was asked to take a look at the Puppy desktop. GParted is suppose to have a recovery feature that is present in its screen's menu, Device>AttemptDataRescue, but, someone, somewhere has deprecated (or broken) GParted!
Where and when ? Which Puppy (-derivate) are you talking about ?
*
About testdisk : it is somewhat incomprehensive to work with. I was able to use it to recover once but the write new mbr feature did not work for me. testdisk really finds old partition signatures that had been deleted and presents them in a confusing way to choose things. I used parted cli to write the new partitions and tune2fs to alter the ext2 partitions to ext3 ones and mkfs.ntfs to alter fat32 to ntfs. When testdisk shows very old partitions it is useful to give partitions LABEL names to make things easier to understand. Some utilities are not capable to tune a LABEL afterwards like for ntfs and swap i think.
Posted: Sat 11 Aug 2012, 07:19
by pemasu
I used once extundelete for recovering deleted files.
Posted: Sat 11 Aug 2012, 18:34
by DPUP5520
Karl Godt wrote:I was asked to take a look at the Puppy desktop. GParted is suppose to have a recovery feature that is present in its screen's menu, Device>AttemptDataRescue, but, someone, somewhere has deprecated (or broken) GParted!
Where and when ? Which Puppy (-derivate) are you talking about ?
*
About testdisk : it is somewhat incomprehensive to work with. I was able to use it to recover once but the write new mbr feature did not work for me. testdisk really finds old partition signatures that had been deleted and presents them in a confusing way to choose things. I used parted cli to write the new partitions and tune2fs to alter the ext2 partitions to ext3 ones and mkfs.ntfs to alter fat32 to ntfs. When testdisk shows very old partitions it is useful to give partitions LABEL names to make things easier to understand. Some utilities are not capable to tune a LABEL afterwards like for ntfs and swap i think.
Yea Testdisk can be confusing to use if it's not one of your primary recovery utilities. PupRescue has the Gpart utility and the recovery feature still has some bugs in puppy which i've been working on fixing. And i've never had a problem using testdisk to write the mbr, however I do prefer and usually use install-mbr.
Posted: Sun 12 Aug 2012, 02:58
by Karl Godt
Code: Select all
Current partition structure:
1 P Linux 0 1 1 1291 254 63 20755917 [Crunchbang]
2 * Linux 1292 0 1 2575 254 63 20627460 [Fox3]
3 P HPFS - NTFS 2576 0 1 4438 254 63 29929095
4 E extended LBA 4439 0 1 60800 254 63 905455530
5 L Linux Swap 4439 2 1 4565 254 63 2040129
X extended 6482 0 1 8394 254 63 30732345
6 L Linux 6482 1 1 8394 254 63 30732282 [LightHousePup]
X extended 8395 0 1 10331 254 63 31117905
7 L Linux 8395 1 1 10331 254 63 31117842 [luci-218]
X extended 10332 0 1 12254 254 63 30892995
8 L Linux 10332 1 1 12254 254 63 30892932 [MacPup431_O2]
X extended 12255 0 1 14231 254 63 31760505
9 L Linux 12255 1 1 14231 254 63 31760442 [LightHouse]
X extended 14232 0 1 15289 254 63 16996770
10 L Linux 14232 1 1 15289 254 63 16996707 [Ext2]
X extended 15290 0 1 15417 254 63 2056320
11 L Linux Swap 15290 1 1 15417 254 63 2056257
X extended 15418 0 1 46277 254 63 495765900
12 L Linux 15418 1 1 46277 254 63 495765837 [Vorrat]
X extended 46278 0 1 46408 254 63 2104515
13 L Linux Swap 46278 1 1 46408 254 63 2104452
X extended 46409 0 1 60669 254 63 229102965
14 L Linux 46409 1 1 60669 254 63 229102902 [BACK]
X extended 60670 0 1 60800 254 63 2104515
15 L Linux Swap 60670 1 1 60800 254 63 2104452
X extended 4566 0 1 6481 254 63 30780540
16 L Linux 4566 1 1 6481 254 63 30780477 [MacPup_F3]
That's the testdisk.log of the very end of the malaisse in my case .
What is confusing :
Every logical partition in the extended partition has a two lines description :
Code: Select all
X extended 4566 0 1 6481 254 63 30780540
16 L Linux 4566 1 1 6481 254 63 30780477 [MacPup_F3]
except for the first one
4 E extended LBA 4439 0 1 60800 254 63 905455530
5 L Linux Swap 4439 2 1 4565 254 63 2040129
X extended 6482 0 1 8394 254 63 30732345
6 L Linux 6482 1 1 8394 254 63 30732282 [LightHousePup]
Another thing : The many old partitions seems not to show in testdisk.log .
*
Here the beginning of the testdisk session :
Code: Select all
Partition table type (auto): Intel
Disk /dev/hda - 500 GB / 465 GiB - Hitachi HDP725050GLAT80
Partition table type: Intel
Results
Linux 0 1 1 1291 254 63 20755917 [/]
EXT2 Large file Sparse superblock, 10627 MB / 10134 MiB
Linux 1292 0 1 2575 254 63 20627460 [/]
EXT3 Large file Sparse superblock, 10561 MB / 10072 MiB
HPFS - NTFS 2576 0 1 4438 254 63 29929095
NTFS, 15 GB / 14 GiB
Linux Swap 4439 2 1 4565 254 63 2040129
SWAP2 version 1, 1044 MB / 996 MiB
Linux 4566 0 1 6481 254 63 30780540 [MacPup430_F3]
EXT3 Large file Sparse superblock Recover, 15 GB / 14 GiB
Linux 6482 1 1 8394 254 63 30732282 [/]
EXT3 Large file Sparse superblock, 15 GB / 14 GiB
Linux 8395 1 1 10331 254 63 31117842 [luci-218]
EXT4 Large file Sparse superblock Recover, 15 GB / 14 GiB
Linux 10332 1 1 12254 254 63 30892932 [MacPup431_O2]
EXT3 Large file Sparse superblock, 15 GB / 14 GiB
Linux 12255 1 1 14231 254 63 31760442 [/]
EXT3 Large file Sparse superblock, 16 GB / 15 GiB
Linux 14232 1 1 15289 254 63 16996707 [/]
EXT2 Large file Sparse superblock, 8702 MB / 8299 MiB
Linux Swap 15290 1 1 15417 254 63 2056257
SWAP2 version 1, 1052 MB / 1004 MiB
Linux 15418 1 1 46277 254 63 495765837 [/]
EXT3 Large file Sparse superblock Recover, 253 GB / 236 GiB
Linux Swap 46278 1 1 46408 254 63 2104452
SWAP2 version 1, 1077 MB / 1027 MiB
Linux 46409 1 1 60669 254 63 229102902 [/]
EXT3 Large file Sparse superblock, 117 GB / 109 GiB
Linux Swap 60670 1 1 60800 254 63 2104452
SWAP2 version 1, 1077 MB / 1027 MiB
The end outcome was : The Macpup partition as /dev/hda6 became /dev/hda16 and all other partitions have also new /dev/hd* associations through parted - resulting in fixing a lot of entries in grub's menu.lst .
The write mbr failure probably is a result of having had that IDE HDD attached to a USB converter on a SATA-only PC . I was using that IDE-HDD to move backups of the SATA-HDD onto .
*
I trashed the MBR of the IDE-HDD while accidentally
while the last command had been
and cp "dd'ed" onto /dev/sdb .
I am not really sad for corrupting Crunchbang but for the Luma-001 frugal installation on it .
Posted: Mon 13 Aug 2012, 12:42
by rcrsn51
I hope that this thread doesn't fall off the radar. If adding gpart to Puppy turns Gparted into a useful data recovery tool, it needs to happen.
However, I tried it myself and the results were unsatisfactory. Using a flash drive, I deliberately deleted a partition, then asked Gparted to find it. It could not.
Posted: Tue 14 Aug 2012, 16:00
by rcrsn51
I ran another test and this time Gparted+gpart found the lost partition. It opened a temporary mount point to the partition so you could off-load the files to external storage. If it worked consistently, this would be much simpler than using testdisk/photorec.
Gparted does not attempt to repair the partition table. Instead, it recommends that you use testdisk.
GParted is suppose to have a recovery feature that is present in its screen's menu, Device>AttemptDataRescue, but, someone, somewhere has deprecated (or broken) GParted!
I looked at Mint 12. It is also missing gpart.
Posted: Tue 14 Aug 2012, 16:38
by Karl Godt
rcrsn51 wrote:
I looked at Mint 12. It is also missing gpart.
according to
http://packages.debian.org/source/squeeze/gpart the "homepage" at a university is gone...
Tried to compile it but have errors apparently because of too new headers.
Will leave it until if i have time .
Posted: Tue 14 Aug 2012, 19:56
by rcrsn51
The Debian version that I packaged above as a PET also worked in Mint.
Posted: Tue 14 Aug 2012, 20:57
by 01micko
http://www.slackware.org.uk/slacky/slac ... t/0.1h_11/
That is a link to the slacky.eu community's version which is in the Slacko PPM (search it
).
This particular version includes a static binary which will probably work in older pups too. (That's a guess!). It also includes documentation which may be worth a read.
I'll include the small dynamically linked binary in future versions of Slacko.
Posted: Wed 15 Aug 2012, 02:17
by Karl Godt
rcrsn51 wrote:The Debian version that I packaged above as a PET also worked in Mint.
http://archive.debian.net/source/potato/gpart
Posted: Sat 25 Aug 2012, 17:29
by bigpup
Having the latest version of Gparted would seem to be part of the issue.
Gparted is at version 0.13.1
http://sourceforge.net/projects/gparted/files/gparted/
I always get the latest version of the Gparted live CD to do any partitioning and format.
extundelete how to install???
Posted: Sun 21 Apr 2013, 18:22
by paule
pemasu wrote:I used once extundelete for recovering deleted files.
I am hoping to use extundelete, could you elaborate on how you installed it? When I try I try to compile the package, I get a "C++ unable to create binaries" or words to that effect.
Thanks in advance.
cheers, Paul