Solved: [Question: finding boundaries of ext2fs-partitions.]

Osman (osman@Cable.EU.org)
Sat, 28 Aug 1999 19:28:45 +0200 (CEST)


For the sake of the archive system and people searching it:

Below you will find a history of my corespondance with Andries Brouwer &
Michail Brzitwa.
I Finaly reported success to both of these two great men, without whom I
would never been able to recover my precious data!

Guys I realy thank you!
Osman

On Thu, 26 Aug 1999, Osman wrote:
>
> Date: Thu, 26 Aug 1999 10:09:02 +0200 (CEST)
> From: Osman <osman@Cable.EU.org>
> To: Michail Brzitwa <mb@ichabod.han.de>
> Cc: System Administrator <osman@Cable.EU.org>
> Subject: gpart patch
[cut]
> BTW:
> I am trying to use your prg to find my ext2 partition on my scsi-disk.
> I have lost the partition table of it.
> I know it used to have 2 partitions on it, 1 swap and 1 ext2.
> I don't recall in wich sequence nor the size of them.
> I used "gpart -i -v /dev/sdc" and "gpart -i -v -C 8709,64,32 /dev/sdc"
> But it is not able to find any of them.
> Any thoughts on what I'm doing wrong?

On Thu, 26 Aug 1999, Michail Brzitwa wrote:
>
> Date: Thu, 26 Aug 1999 11:41:24 +0200
> From: Michail Brzitwa <mb@ichabod.han.de>
> To: Osman <osman@Cable.EU.org>
> Subject: Re: gpart patch
>
> Without any gpart output I can't. If I should guess, I'd
> recommend using a sector increment scan ('-n s') and, if
> this isn't enough, a full scan ('-n s -f'). Please try that
> and send me gparts '-vvv' output (even if it succeeds).

On Thu, 26 Aug 1999, Michail Brzitwa wrote:
>
> Date: Thu, 26 Aug 1999 17:08:32 +0200
> From: Michail Brzitwa <mb@ichabod.han.de>
> To: Osman <osman@Cable.EU.org>
> Subject: Re: gpart patch
>
> On Thu, Aug 26, 1999 at 02:38:45PM +0200, you (Osman) wrote:
> > I used "gpart -n s -vvv -l gpart.out /dev/sdc" see attachment.
> > How do I proceed?
>
> If the guessed table seems ok, use the same increment parameters
> ('-n s') and add '-W /dev/sdc' to write the table back.

On Thu, 26 Aug 1999 Andries.Brouwer@cwi.nl wrote:
>
> Date: Thu, 26 Aug 1999 12:51:55 +0200 (MET DST)
> From: Andries.Brouwer@cwi.nl
> To: Andries.Brouwer@cwi.nl, osman@Cable.EU.org
> Cc: mb@ichabod.han.de
> Subject: Re: rescuept
>
> From osman@Cable.EU.org Thu Aug 26 10:54:06 1999
>
> I just tried "rescuept" from util-linux (aeb@cwi.nl) and it found:
> [root@fw rescuept]# ./rescuept /dev/sdc
> # partition table of /dev/sdc
> # total size 17836668 sectors
> unit: sectors
> # 8574 MB ext2 partition (type 83): sectors 1- 17559040
> # 133 MB new swap space (type 82): sectors 17559045- 17832148
> /dev/sdc0 : start= 1, size=17559040, Id=83
> /dev/sdc0 : start= 17559045, size= 273104, Id=82
>
> But I don't know how to translate this output to entries in a partition
> table yet.
>
> In fact the output *is* a partition table, precisely
> the input sfdisk would need.

On Thu, 26 Aug 1999, Osman wrote:
>
> Date: Thu, 26 Aug 1999 14:43:31 +0200 (CEST)
> From: Osman <osman@Cable.EU.org>
> To: Andries.Brouwer@cwi.nl
> Cc: System Administrator <osman@Cable.EU.org>
> Subject: Re: rescuept
>
> Can I pipe this output/file to sfdisk?
> Do I need some special options?
> Excuse me for beeing so scary but I've never used sfdisk and never done
> this before... [stupid smile on my face]

On Thu, 26 Aug 1999 Andries.Brouwer@cwi.nl wrote:
>
> Date: Thu, 26 Aug 1999 15:49:50 +0200 (MET DST)
> From: Andries.Brouwer@cwi.nl
> To: Andries.Brouwer@cwi.nl, osman@Cable.EU.org
> Subject: Re: rescuept
>
> > Can I pipe this output/file to sfdisk?
>
> I think so, yes.
>
> > I've never done this before...
>
> Neither have I, but it should work :-)
>
> Please report on success.
>
> Good luck - Andries
>
>
> P.S. So, I think you can say
> ./rescuept /dev/sdc | sfdisk /dev/sdc
>
> don't forget the disk argument to sfdisk or you
> may repartition some default disk like /dev/sda :-)
> You might read the sfdisk docs just to be sure.
> I would probably do this in two steps:
> ./rescuept /dev/sdc > sdc.table
> look at sdc.table to see that it looks reasonable, then
> sfdisk /dev/sdc < sdc.table
>
> sfdisk has options to preserve the previous situation
> so that you can undo what you did in case something
> is wrong.
>

-- 
              The best things in life are free, but the
                expensive ones are still worth a look.

- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.rutgers.edu Please read the FAQ at http://www.tux.org/lkml/