Page 2 of 4 FirstFirst 1234 LastLast
Results 11 to 20 of 32

Thread: mount advice needed

  1. #11
    Join Date
    Jul 2008
    Location
    Italy
    Posts
    82

    Default Re: mount advice needed

    Quote Originally Posted by arvidjaar View Post
    GPT format has two copies of partition table - one at the beginning of disk, another at the end of disk. Both copies include addresses (block numbers) of other copy. In your case first copy of partition table claims that second copy is locate at block 0x5d50a3af == 1565565871. This is exactly 4294967296 blocks less than actual last block number ( 5860533167) which explain error message.

    Now 4294967296 is 0x100000000, so it sounds like partition table was edited by 32 bit application that lost high bits. OTOH partition entries themselves are correct; as example:



    Last block on this partition is 0x15d50a38e == 5860533134 which is exactly 33 blocks less than total disk size; and GPT table consumes usually 33 blocks (1 block header and 32 blocks partitions array).

    So yes, partition table is corrupted. It should be safe to rewrite alternate GPT (there is enough space). But I would not trust parted (it is too high level and hides too much), and use gdisk that offers option to fix it. Of course, preserving 33 sectors from 1565565871 downward before attempting to fix makes sense as well
    Thanks, but I must admit it's over my head and I'm not sure what I should do. It is a disk with no OS and contains all my data files music, photos and Documents so it would be a disaster if I lost it so I'm a bit frightened about making a mistake. Maybe that American president who said "If it ain't broke don't fix it" should be given priority.
    OpenSuSE Leap 15.1 KDE, 64bit
    M/B Intel DP67BG. CPU Intel i7-2600K @3.40GHz. 16GB DIMM 1600MHz. Nvidia GeForce GTX570.
    SanDisk 240GB SSD, ST33000651AS 3TB, WDC WD10EACS-00D 1TB, ST31000340AS 3TB, Hitachi HDT72101 1TB.

  2. #12
    Join Date
    Jun 2008
    Location
    Netherlands
    Posts
    25,156

    Default Re: mount advice needed

    Quote Originally Posted by ghep View Post
    It is a disk with no OS and contains all my data files music, photos and Documents so it would be a disaster if I lost i
    ???
    I would make an exra backup beside the normal backup and why worry then?
    Henk van Velden

  3. #13
    Join Date
    Jul 2008
    Location
    Italy
    Posts
    82

    Default Re: mount advice needed

    I've had a look at the gdisk options and I am a bit worried about using gdisk -x -s because I'm afraid it will ask me for numbers I don't understand, here is the output of
    Code:
    gdisk -l /dev/sdb
    GPT fdisk (gdisk) version 1.0.1
    
    Partition table scan:
      MBR: protective
      BSD: not present
      APM: not present
      GPT: present
    
    Found valid GPT with protective MBR; using GPT.
    
    Warning! Secondary partition table overlaps the last partition by
    4294967296 blocks!
    Try reducing the partition table size by 17179869184 entries.
    (Use the 's' item on the experts' menu.)
    Disk /dev/sdb: 5860533168 sectors, 2.7 TiB
    Logical sector size: 512 bytes
    Disk identifier (GUID): 713BDCEB-C906-4D1A-A0D4-1E9F04687D2F
    Partition table holds up to 128 entries
    First usable sector is 34, last usable sector is 1565565838
    Partitions will be aligned on 8-sector boundaries
    Total free space is 4062 sectors (2.0 MiB)
    
    Number  Start (sector)    End (sector)  Size       Code  Name
       1              40            2087   1024.0 KiB  EF02  BIOS boot partition
       2            6144      5843795967   2.7 TiB     0700  
       3      5843795968      5860533134   8.0 GiB     8200  Linux swap
    As you can see it suggests using gdisk -x -s
    What's confusing is the output talks about blocks, entries and sectors
    It says reduce the partition table size by 17179869184 entries and then 'Partition table holds up to 128 entries' What am I missing?
    OpenSuSE Leap 15.1 KDE, 64bit
    M/B Intel DP67BG. CPU Intel i7-2600K @3.40GHz. 16GB DIMM 1600MHz. Nvidia GeForce GTX570.
    SanDisk 240GB SSD, ST33000651AS 3TB, WDC WD10EACS-00D 1TB, ST31000340AS 3TB, Hitachi HDT72101 1TB.

  4. #14
    Join Date
    Jul 2008
    Location
    Italy
    Posts
    82

    Default Re: mount advice needed

    Quote Originally Posted by hcvv View Post
    ???
    I would make an exra backup beside the normal backup and why worry then?
    You're right I'll try and find the space to do it.
    OpenSuSE Leap 15.1 KDE, 64bit
    M/B Intel DP67BG. CPU Intel i7-2600K @3.40GHz. 16GB DIMM 1600MHz. Nvidia GeForce GTX570.
    SanDisk 240GB SSD, ST33000651AS 3TB, WDC WD10EACS-00D 1TB, ST31000340AS 3TB, Hitachi HDT72101 1TB.

  5. #15
    Join Date
    Sep 2012
    Posts
    5,139

    Default Re: mount advice needed

    Quote Originally Posted by ghep View Post
    It says reduce the partition table size by 17179869184 entries and then 'Partition table holds up to 128 entries'
    It's misleading. It simply compares last usable block in main partition header and assumes everything after it should be backup partition table. Could you show
    Code:
    gdisk /dev/sdb
    v
    q
    It compares main and backup partition tables and does some more sanity checks.

  6. #16
    Join Date
    Jul 2008
    Location
    Italy
    Posts
    82

    Default Re: mount advice needed

    Quote Originally Posted by arvidjaar View Post
    It's misleading. It simply compares last usable block in main partition header and assumes everything after it should be backup partition table. Could you show
    Code:
    gdisk /dev/sdb
    v
    q
    It compares main and backup partition tables and does some more sanity checks.

    Code:
    gdisk /dev/sdb
    GPT fdisk (gdisk) version 1.0.1
    
    Partition table scan:
      MBR: protective
      BSD: not present
      APM: not present
      GPT: present
    
    Found valid GPT with protective MBR; using GPT.
    
    Warning! Secondary partition table overlaps the last partition by
    4294967296 blocks!
    Try reducing the partition table size by 17179869184 entries.
    (Use the 's' item on the experts' menu.)
    
    Command (? for help): v
    
    Problem: The secondary header's self-pointer indicates that it doesn't reside
    at the end of the disk. If you've added a disk to a RAID array, use the 'e'
    option on the experts' menu to adjust the secondary header's and partition
    table's locations.
    
    Warning! Secondary partition table overlaps the last partition by
    4294967296 blocks!
    Try reducing the partition table size by 17179869184 entries.
    (Use the 's' item on the experts' menu.)
    
    Identified 2 problems!
    
    Command (? for help): q
    OpenSuSE Leap 15.1 KDE, 64bit
    M/B Intel DP67BG. CPU Intel i7-2600K @3.40GHz. 16GB DIMM 1600MHz. Nvidia GeForce GTX570.
    SanDisk 240GB SSD, ST33000651AS 3TB, WDC WD10EACS-00D 1TB, ST31000340AS 3TB, Hitachi HDT72101 1TB.

  7. #17
    Join Date
    Sep 2012
    Posts
    5,139

    Default Re: mount advice needed

    So you actually have backup partition table in the middle of file system and it was not even overwritten so far. You can use gdisk to move backup to end of disk where it should have been. To test it:
    Code:
    gdisk /dev/sdb
    x
    e
    v
    q
    This enters expert menu, changes main and backup partition headers to indicate backup partition table is now at the end of disk and verifies result (in particular, that backup actually fits in available space). It will not write anything to disk.

  8. #18
    Join Date
    Jun 2008
    Location
    Netherlands
    Posts
    25,156

    Default Re: mount advice needed

    While work is done on repairing this situation, I want to draw attention to the fact that after this is repaired, you should realy contemplate on how this could be created. That is, I hope you want to avoid breaking your disk partitioning again in the future.

    I can think of one way to get what you got and that is copying (the so called "cloning") of a smaller disk to this larger disk. And after that is done doing some new partitioning.
    Henk van Velden

  9. #19
    Join Date
    Jul 2008
    Location
    Italy
    Posts
    82

    Default Re: mount advice needed

    Quote Originally Posted by arvidjaar View Post
    So you actually have backup partition table in the middle of file system and it was not even overwritten so far. You can use gdisk to move backup to end of disk where it should have been. To test it:
    Code:
    gdisk /dev/sdb
    x
    e
    v
    q
    This enters expert menu, changes main and backup partition headers to indicate backup partition table is now at the end of disk and verifies result (in particular, that backup actually fits in available space). It will not write anything to disk.
    thanks, here's the result :-
    Code:
    gdisk /dev/sdb
    GPT fdisk (gdisk) version 1.0.1
    
    Partition table scan:
      MBR: protective
      BSD: not present
      APM: not present
      GPT: present
    
    Found valid GPT with protective MBR; using GPT.
    
    Warning! Secondary partition table overlaps the last partition by
    4294967296 blocks!
    Try reducing the partition table size by 17179869184 entries.
    (Use the 's' item on the experts' menu.)
    
    Command (? for help): x
    
    Expert command (? for help): v
    
    Problem: The secondary header's self-pointer indicates that it doesn't reside
    at the end of the disk. If you've added a disk to a RAID array, use the 'e'
    option on the experts' menu to adjust the secondary header's and partition
    table's locations.
    
    Warning! Secondary partition table overlaps the last partition by
    4294967296 blocks!
    Try reducing the partition table size by 17179869184 entries.
    (Use the 's' item on the experts' menu.)
    
    Identified 2 problems!
    
    Expert command (? for help): q
    I spent last night trying to reduce the space occupied on sbd2 so I could back it up somewhere else and it really opened up a can of worms because apparently I moved a lot of stuff there as a backup and then failed to delete them after I resolved whatever problem I had then. So I'm slowly but surely eliminating the double copies as I find them, I'm getting close but not there yet.
    OpenSuSE Leap 15.1 KDE, 64bit
    M/B Intel DP67BG. CPU Intel i7-2600K @3.40GHz. 16GB DIMM 1600MHz. Nvidia GeForce GTX570.
    SanDisk 240GB SSD, ST33000651AS 3TB, WDC WD10EACS-00D 1TB, ST31000340AS 3TB, Hitachi HDT72101 1TB.

  10. #20
    Join Date
    Sep 2012
    Posts
    5,139

    Default Re: mount advice needed

    Quote Originally Posted by ghep View Post
    thanks, here's the result
    You did not do what I asked.

Page 2 of 4 FirstFirst 1234 LastLast

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •