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

Re: The backup GPT table is corrupt



On 2025-08-12 11:19, Thomas Schmitt wrote:
Hi,

mick.crane wrote:
root@courgette:/home/mick# gdisk /dev/sda
...
Caution: invalid backup GPT header, but valid main header; regenerating
backup header from main header.
...
OK; writing new GUID partition table (GPT) to /dev/sda.
...
The operation has completed successfully.
...
root@courgette:/home/mick# gdisk /dev/sda
...
Warning! One or more CRCs don't match. You should repair the disk!
Main header: OK
Backup header: ERROR
Main partition table: OK
Backup partition table: OK

That's strange. Can it be that the last block of the disk is bad ?

Please post the content of that block.
Refering to info from your initial post
Units: sectors of 1 * 512 = 512 bytes
Disk /dev/sda: 111.79 GiB, 120034123776 bytes, 234441648 sectors
this would be

  sudo dd bs=512 count=1 if=/dev/sda skip=234441647 | \
  od -t x1 >/tmp/gpt_backup_header.hex

root@courgette:/home/mick# dd bs=512 count=1 if=/dev/sda skip=234441647 | \
  od -t x1 >/tmp/gpt_backup_header.hex
1+0 records in
1+0 records out
512 bytes copied, 4.4058e-05 s, 11.6 MB/s
root@courgette:/home/mick#

/tmp/gpt_backup_header.hex

0000000 45 46 49 20 50 41 52 54 00 00 01 00 5c 00 00 00
0000020 cc c9 67 f5 00 00 00 00 af 4b f9 0d 00 00 00 00
0000040 01 00 00 00 00 00 00 00 22 00 00 00 00 00 00 00
0000060 8e 4b f9 0d 00 00 00 00 b6 c0 c0 ce 33 a9 6a 42
0000100 92 1b 04 bd a9 9e 80 8b 8f 4b f9 0d 00 00 00 00
0000120 80 00 00 00 80 00 00 00 00 00 00 00 00 00 00 00
0000140 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
*
0001000


Reply to: