I have a disk which has a corrputed alternate GPT and Linux doesn't want to read the primary one.I see all sorts of weird messages in the kernel logs. Here's what happens when I plug in the drive.[ 1030.358675] usb 3-1: new SuperSpeed USB device number 14 using xhci_hcd[ 1030.378105] scsi host4: uas[ 1030.379592] scsi 4:0:0:0: Direct-Access     Seagate  Expansion        9300 PQ: 0 ANSI: 6[ 1030.408991] sd 4:0:0:0: Attached scsi generic sg1 type 0[ 1030.409144] sd 4:0:0:0: [sdb] Spinning up disk...[ 1031.438623] .[ 1032.451912] .[ 1033.465247] .[ 1034.478653] .[ 1034.478938] ready[ 1034.479056] sd 4:0:0:0: [sdb] 2930277167 512-byte logical blocks: (1.50 TB/1.36 TiB)[ 1035.549485] sd 4:0:0:0: [sdb] Write Protect is off[ 1035.549488] sd 4:0:0:0: [sdb] Mode Sense: 4f 00 00 00[ 1035.549640] sd 4:0:0:0: [sdb] Write cache: enabled, read cache: enabled, doesn't support DPO or FUA[ 1068.039214] sd 4:0:0:0: [sdb] tag#2 uas_eh_abort_handler 0 uas-tag 3 inflight: CMD IN [ 1068.039218] sd 4:0:0:0: [sdb] tag#2 CDB: opcode=0x28 28 00 ae a8 7b 2a 00 00 01 00[ 1068.039304] sd 4:0:0:0: [sdb] tag#1 uas_eh_abort_handler 0 uas-tag 2 inflight: CMD IN [ 1068.039307] sd 4:0:0:0: [sdb] tag#1 CDB: opcode=0x28 28 00 ae a8 7b 29 00 00 01 00[ 1068.039336] sd 4:0:0:0: [sdb] tag#0 uas_eh_abort_handler 0 uas-tag 1 inflight: CMD IN [ 1068.039340] sd 4:0:0:0: [sdb] tag#0 CDB: opcode=0x28 28 00 ae a8 7b 28 00 00 01 00[ 1068.039389] scsi host4: uas_eh_bus_reset_handler start[ 1068.152519] usb 3-1: reset SuperSpeed USB device number 14 using xhci_hcd[ 1068.170382] scsi host4: uas_eh_bus_reset_handler successAnd as soon as I forcefully plug it out, I get:[  757.393131] Alternate GPT is invalid, using primary GPT.[  757.393148]  sdb: sdb1 sdb3This log entry seems to reflect that the primary GPT is valid and has the missing partitions. However, fdisk, parted and even dd get stuck when I try to read or write something to the block device, so I can't recover it by hand.I looked into using a hex editor to overwrite the alt GPT with the primary one but as I mentioned, I/O to the disk is stuck.If this is relevant, the disk is a Seagate one and has a LUKS partition and a NTFS partition and the table is a GUID partition table.
Disk with corrputed alternate GPT
linux;gpt;external hdd