1

Topic: Invalid partition table on /dev/sda - wrong signature 3739

Hi all,

Here's what my drive looked like before:

/dev/sda1 - fat16 - 47MB
/dev/sda2 - ntfs - 14GB
free space - 20GB
/dev/sda4 - extended partition - 34GB
     /dev/sda5 - linux-swap - 1GB
     /dev/sda6 - reiserfs - 33GB
/dev/sda3 - fat32 - 4GB (this is a dell recovery partition)

Obviously I wanted to use up that free space.  So I used a gparted live cd.

I asked Gparted to:

1) Grow /dev/sda4 from 34GB to 54GB
2) Move /dev/sda5 to the left
3) Grow /dev/sda6 from 33GB to 53GB

The first two it did just fine.  While attempting to grow /dev/sda6 (reiserfs) from 33GB to 53GB, it did the following:

1) calibrate /dev/sda6 - OK
2) calculate new size and position of /dev/sda6 - OK
3) check filesystem on /dev/sda6 for errors and fix them - OK
4) move filesystem to the left - OK
5) move partition to the left - ERROR

The libparted messages are: "Invalid partition table on /dev/sda -- wrong signature 3739"

I saved the details but am not sure how to get them to you guys smile  The best I can come up with is to copy the entire file tediously and put it up somewhere for you guys to see.  But that will take time.  I'm not going to reboot my computer, I'm leaving it right where it is in case rebooting screws it up.  While I'm typing up the full report, I am more than happy to give you whatever details you might need, just let me know.

Thanks!

spiderworm

2

Re: Invalid partition table on /dev/sda - wrong signature 3739

did you see that link in the errormessage? it contains info on how to get the saved details of the livecd wink

anyway, it looks like you need to run testdisk and be very, very carefull. This is a known error which happens every now and then and should be fixed in one of the next releases of libparted. The filesystem has been moved correctly so you probably need to move one partition after you have restored the partitiontable.

However, get me the details and i'll be able to help you in detail.

3

Re: Invalid partition table on /dev/sda - wrong signature 3739

Thanks plors for your quick response.

I would love some detailed help!  Copying this thing is going to take awhile smile  You can watch it as I work on it at:

http://tellim.com/random/gparted_details.html

Let me know if you want me to skip ahead to a different section.  Thanks!

spiderworm

4

Re: Invalid partition table on /dev/sda - wrong signature 3739

wait a minute!! you are copying it by hand?!!

don't do that, just copy the file to usbstick or floppy or whatever removable media you have!

5

Re: Invalid partition table on /dev/sda - wrong signature 3739

sorry plors,

I have no usbsticks and this laptop does not have a floppy drive.  there's apparently no networking on the gparted live cd? so let me know if you have any other ideas.

spiderworm

6

Re: Invalid partition table on /dev/sda - wrong signature 3739

i wouldn't know, but realize that one type may be the difference between a heathy and a dead drive smile

7

Re: Invalid partition table on /dev/sda - wrong signature 3739

you mean one typo?

spider

8

Re: Invalid partition table on /dev/sda - wrong signature 3739

si, sorry wink

9

Re: Invalid partition table on /dev/sda - wrong signature 3739

i dont know what else to do other that copy by hand.  I'm going to keep doing this and I suppose we can triple check the most important sections once I'm done?

spiderworm

10

Re: Invalid partition table on /dev/sda - wrong signature 3739

ok, thnx

btw, good news, since the partition you were trying to move was a swap we can easily dismiss it smile That means that recovery will be very easy.

Please let me know when you're finished with copying.

11

Re: Invalid partition table on /dev/sda - wrong signature 3739

plors,

Take a look at my very first post... I think the one that had trouble was the reiserfs one.

spiderworm

12

Re: Invalid partition table on /dev/sda - wrong signature 3739

you are right, no need to give all the other details then. Ifyou could just start at step 4 (move filesystem to the left - OK) and go from there to the end it's fine by me. (i will talk to the livecd maintainer about including support for network, but i can't promise anything)

13

Re: Invalid partition table on /dev/sda - wrong signature 3739

hi plors,

Sorry it took so long, but I finally was able to finish up.  I skipped to the section you asked for and went to the end.

http://tellim.com/random/gparted_details.html

spidey

14

Re: Invalid partition table on /dev/sda - wrong signature 3739

I have now filled in the parts I skipped... you have my complete gparted_details file (hopefully without any major typos).

http://tellim.com/random/gparted_details.html

spiderworm

15

Re: Invalid partition table on /dev/sda - wrong signature 3739

spiderworm, thnx! I have to go again, but i'll help you first thing in the morning.

Basicly we have to do 2 things.
- restore the old partitiontable using testdisk (it's on the livecd)
- then move your partition (not the filesystem, its already moved) to enclose the move filesystem. We have to use fdisk for that, because the GUI cannot do this on sector level yet.

and done... should be a breeze smile

see you tomorrow.

16 (edited by spiderworm 2006-09-13 23:32:50)

Re: Invalid partition table on /dev/sda - wrong signature 3739

Well, I did testdisk.... it was able to recover my partition table, and i wrote the changes.  I haven't done fdisk yet.  gparted now sees the following:

/dev/sda1 - fat16 - 47.03MB
/dev/sda2 - ntfs - 14.65 GiB
/dev/sda3 - extended - 53.78 GiB
     unallocated - 7.88 MiB
     /dev/sda5 - linux-swap - 1019.72 MiB
     /dev/sda6 - reiserfs - 33.61 GiB **problem**
     unallocated - 19.17 GiB
/dev/sda4 - fat32 - 4.64 GiB **problem**
unallocated - 7.84 MiB

The filesystems that still have problems, sda6 and sda4, have the following errors:

sda6 - reiserfs_open: the reiserfs superblock cannot be found on /dev/sda6 .... debugreiserfs: can not open reiserfs on /dev/sda6": no filesystem found. ..... Unable to read the contents of this filesystem!  Because of this some operations may be unavailable!

sda4 - Unable to read the contents of this filesystem!  Because of this some operations may be unavailable!

My understanding is that the superblock on the reiserfs partition SHOULD be on the first sector?  I'm guessing it's not, which is why gparted cannot read it.  Right now, gparted says the first sector is 32917248 and the last sector is 103410404 for a total of 70493157 sectors.  If the superblock isn't on the first sector of the partition, does this mean i need to find the superblock somehow and then move the partition so that the first sector contains the superblock?

spiderworm

17

Re: Invalid partition table on /dev/sda - wrong signature 3739

ok, you should remove your /dev/sda6 and recreate it on sectors 32917248 - 143605034 (using (c)fdisk)
then your reiserfs filesystems should be OK.

About sda4, i didn't realize there was a problem with that one as well.. There should be nothing serious, because otherwise gparted wouldn't have reported the operation as a scuces. Please reread the filesystem (by refreshing gparted) and see if you maybe restored the partition at the wrong location.

have fun wink

18

Re: Invalid partition table on /dev/sda - wrong signature 3739

btw, if you still have those details, i'd like to see all the details about the operation on sda4, now they are cuttoff halfway. (i still can't believe you don't have acces to some portable device, this is the 21th century tongue )

19

Re: Invalid partition table on /dev/sda - wrong signature 3739

Hi plors,

You have the full report at http://tellim.com/random/gparted_details.html .... there was nothing that was supposed to be done to sda4, so i dont know why that one got goofed up.... restarting gparted does nothing.

I'm going to try fdisk... I'm a little worried that fdisk will format the partition either when I delete it or when I recreate it... is there any chance it will do that?

spidey

20

Re: Invalid partition table on /dev/sda - wrong signature 3739

Grow /dev/sda4 from 34.62 GiB to 53.78 GiB
that's the first operation in the list you provide in that link....

fdisk wil not  format anything, it only deals with partitions, so don't worry.

21

Re: Invalid partition table on /dev/sda - wrong signature 3739

Wow, you're very correct, but this is very odd.  Before using gparted, /dev/sda4 was the 34GB extended partition...  After testdisk recreated the partition table, /dev/sda4 became the 4GB Dell Recovery partition.  Why would this have happened?  Am I able to change the order somehow so that the 4GB Dell Recovery Partition is once again /dev/sda3?

Since you're sure that fdisk will not format the partition or overwrite the superblock or anything like that, I'm going to do it smile  I am pretty scared tho

spiderworm

22

Re: Invalid partition table on /dev/sda - wrong signature 3739

ok, keep me updated and don't panic. The filesystem is ok, it's just the partition and we can repeat that process till it's ok smile

we'll deal with that strange sda4 later

23

Re: Invalid partition table on /dev/sda - wrong signature 3739

Plors,

You said:

ok, you should remove your /dev/sda6 and recreate it on sectors 32917248 - 143605034 (using (c)fdisk)

But when I try to creeate a new partition, it doesn't ask my for sectors, it wants to know which cylinder to put it on, and it only gives me a range of 1919-8939.  Please advise.

spider

24

Re: Invalid partition table on /dev/sda - wrong signature 3739

use fdisk -u <device>

25

Re: Invalid partition table on /dev/sda - wrong signature 3739

great smile thanks, that seemed to work.  i noticed i could also switch between sectors and cylinders within fdisk with u.

it looks like it worked... gparted is showing no errors on /dev/sda6 OR /dev/sda4 (the new Dell Recovery partition).  I didn't do anything to fix that partition, I don't know what happened.

Anyways tho, /dev/sda6 is showing that there is only 1.41GB free, which isn't possible, since I just added 20 GB empty space to it.  Any ideas why this might be?

Also, I'm feeling a bit braver now... should I try to mount /dev/sda6?

spidey