[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: repair partition: wrong size



George-Cristian Bîrzan wrote:
On Thu, 2010-08-05 at 09:59 -0500, hugo vanwoerkom wrote:
Gpart finds the partitions allright, but they aren't lost, just the wrong size. How do I set the correct size?

From its page:

Now if after the check-phase it says Ok, you should check the proposed
partition table very carefully. After that you may write back the
guessed table by calling "gpart -W /dev/hdc /dev/hdc" (exchange /dev/hdc
with your disk device). When gpart has successfully written the new
primary partition table, cross your fingers and reboot.



Actually  in my /dev/sdb both partition 2 + 3 are wrong:

num  start should be end should be
2    8003MB  8003MB  10.0GB 16.0GB
3    10.0GB  16.0GB  24.0GB 24.0GB

The simplest fix would be to delete both and recreate them because I have backups for both. But I would like to see if it can be fixed.

Gpart /dev/sdb gives:

Begin scan...
Possible partition(Linux ext2), size(7632mb), offset(0mb)
Possible partition(Linux ext2), size(7632mb), offset(7632mb)
Possible extended partition at offset(22897mb)
   Possible partition(Linux ext2), size(7632mb), offset(22897mb)
   Possible partition(Linux ext2), size(7632mb), offset(30529mb)
   Possible partition(Linux ext2), size(38154mb), offset(38162mb)
End scan.

Checking partitions...
Partition(Linux ext2 filesystem): primary
Partition(Linux ext2 filesystem): primary
   Partition(Linux ext2 filesystem): logical
   Partition(Linux ext2 filesystem): logical
   Partition(Linux ext2 filesystem): logical
Ok.

Guessed primary partition table:
Primary partition(1)
   type: 131(0x83)(Linux ext2 filesystem)
   size: 7632mb #s(15631176) s(63-15631238)
   chs:  (0/1/1)-(972/254/57)d (0/1/1)-(972/254/57)r

Primary partition(2)
   type: 131(0x83)(Linux ext2 filesystem)
   size: 7632mb #s(15631240) s(15631245-31262484)
   chs:  (973/0/1)-(1023/254/63)d (973/0/1)-(1945/254/58)r

Primary partition(3)
   type: 015(0x0F)(Extended DOS, LBA)
   size: 53419mb #s(109402650) s(46893735-156296384)
   chs:  (1023/254/63)-(1023/254/63)d (2919/0/1)-(9728/254/63)r

Primary partition(4)
   type: 000(0x00)(unused)
   size: 0mb #s(0) s(0-0)
   chs:  (0/0/0)-(0/0/0)d (0/0/0)-(0/0/0)r

But I don't think that is right: there are 3 primary partitions and 3 logical partitions and they should be all 8GB in length except the last one that is 40GB in length.

Hugo


Reply to: