If you ever need to clean the disks on a bare-metal machine running Linux, this is a quick reference on how to do it in our Hetzner environment.
If you are facing an issue and see this error message: Error: Error Message: DetectLinuxOnAnotherDisk failed (permanent error): FAIL: nvme0n1p1 eui.002538bb31006f8f looks like a Linux /boot/efi partition on another disk.
, the process described in this page will solve it.
The first way to wipe the disks is by using the annotation wipe-disks
in the HetznerBareMetalHost
object. Servers with this annotation will have the indicated disks wiped the next time it's provisioned.
If you have already added the server to the cluster, you can scale down and up again the associated machine deployment to trigger a reprovisioning.
Otherwise, the server disks will be wiped the next time you perform an update.
Another way to wipe the disks is by doing it manually using the rescue system.
We recommend using the annotation method, but the manual way is explained here for users in older versions of Autopilot that don't yet support the wipedisk annotation.
Access the Hetzner Console and go to the Robot servers.
After selecting the server you want to wipe, go to the Rescue tab, select the appropriate ssh key and keyboard layout, and enable the rescue system.
Now you need to reboot the machine in the Reset tab. To enter the rescue system, only a "Send CTRL+ALT+DEL to server" reset will work. The machine will take a few minutes to become available after the reboot.
SSH into the machine using the key you specified in the previous step.
For disks without RAID, do the steps below:
For disks on RAID:
Repeat this process for all disks in the machine as needed.