Opção de argumento ausente no sfdisk?

Opção de argumento ausente no sfdisk?
sfdisk --delete $disk

Do Ubuntu 18.04 ou posterior funciona. Qual é o comando equivalente no Ubuntu 16.04 LTS?

Ubuntu 16.04 LTS (--delete ausente),

Ubuntu 18.04 LTS (--delete presente)

Responder1

Solução 1:construa e instale o sfdisk a partir dos fontes (para poder usar uma versão mais recente)

wget https://mirrors.edge.kernel.org/pub/linux/utils/util-linux/v2.35/util-linux-2.35.tar.gz
tar -xvf util-linux-2.35.tar.gz
cd cd util-linux-2.35
./configure 
make
make install
/usr/local/bin/sfdisk --delete $disk

Solução 2:usarfdisk

# list disk and partitions
fdisk -l
# open the target disk with fdisk
fdisk /dev/target-disk
# then use the d command option to delete the partition you want to remove
# then use the w command option to save the changes 

Responder2

wipefs -a -f $disk

vaiFaça o truque

informação relacionada