This guide covers an array of formatting related issues with SAS / SATA hard disk for usage in general purpose server environments.
Largely speaking all instructions here should perform reasonably well in all linux environments. Some systems though such as TrueNas do not allow the installation of additional packages needed to fix your issues effectively. For that reason I would consider to boot from an iso to avoid any issues. For the purpose of reformating disks SystemRescue (formerly known as SystemRescueCd) is a good choice.
- it is lightweight;
- it comes with support for most sas / raid controllers;
- it comes with support for plenty of network cards;
- you can easily add a package called parallel to compute multiple reformating tasks at once.
- Download the iso from the Systemrescue website
- run
pacman -Sy
to update the package manager - If you need to handle multiple disks run
pacman -S parallel
- If you want to access via ssh run
passwd
to set a password of your choice and enable the correct port for SSH (22) on the firewall that comes factory installed (iptables as of writing) - Follow the instructions you can find below in the guides.
- Change Block size from 3Par or EMC Storrage solution disks from 520 to 512 / 4096 bytes
- Remove the Data Integrity Feature from disks
- Reformating 520k Drives, Level 1 Techs Forum, 2018
- Troubleshooting Disk Format Warnings in TrueNas Scale, Truenas Forum, constantly updated