Please help: can't replace deferred disk

Feb 14, 2021
41
2
13
68
Denmark
I had this layout for a small Proxmox server:

Screenshot_2021-09-12_14-53-47.png
ZFS told me that /dev/sda was deferred because of errors, so I decided to replace it...

3 hardware disks involved: DEFERRED (no longer in the box), NEW (to replace DEFERRED), OLD (mirror copy).

I took DEFERRED offline from the zpool, shutdown the server, replaced DEFERRED with NEW. I was able to boot again, all good - I thought ... I then did

$sgdisk --replicate /dev/sdb /dev/sda (where sda is the new disk)

It threw a lot of errors:

Code:
***************************************************************
Found invalid GPT and valid MBR; converting MBR to GPT format
in memory.
***************************************************************
Caution! Secondary header was placed beyond the disk's limits! Moving the
header, but other problems may occur!
Warning: The kernel is still using the old partition table.
The new table will be used at the next reboot or after you
run partprobe(8) or kpartx(8)
The operation has completed successfully.

When I now look at the partition schemes with fdisk, OLD shows 2 Linux Raid partitions, 250 MB and 931 GB. But when I look at the partition from the Proxmox GUI, OLD shows 3 partitions: 1 MB zfs_member, 500 MB vfat, and 999 GB ZFS.

I've been able to copy the partition layout from DEFERRED to NEW. But I can't copy this layout to OLD, while it's in use.

I can't install Grub on NEW. I guess I in some way trashed the partition layout of OLD. But things are still working, because the kernel still uses the old layout. I'm really worried that the server won't boot if / when I restart it.

My best idea right now is to shutdown the server and check / replace the partition layout of OLD with the layout from DEFERRED.

Please help :)
 

About

The Proxmox community has been around for many years and offers help and support for Proxmox VE, Proxmox Backup Server, and Proxmox Mail Gateway.
We think our community is one of the best thanks to people like you!

Get your subscription!

The Proxmox team works very hard to make sure you are running the best software and getting stable updates and security enhancements, as well as quick enterprise support. Tens of thousands of happy customers have a Proxmox subscription. Get yours easily in our online shop.

Buy now!