copy_server_key non riesce a formattare
Tentando di copiare le chiavi su /dev/sdb1 lo script usciva con errore
# /usr/local/sbin/copy_server_key /dev/sdb1
Found a 14.90 GiBi ext4 partition with label portachiavi on SanDisk (Cruzer_Edge)
We are going to overwrite this partition
this will OVERWRITE ALL DATA
Press enter to continue, Ctrl-C to cancel.
mke2fs 1.43.4 (31-Jan-2017)
/dev/sdb1 contiene un file system ext4 con etichetta "portachiavi"
last mounted on /mnt/portachiavi on Mon Aug 13 09:40:52 2018
Proceed anyway? (y,N) y
usage: copy_server_key [-h] [-s SERVER] device
copy_server_key: error: Could not format /dev/sdb1: Command '['mkfs.ext4', '-L', 'portachiavi', '/dev/sdb1']' returned non-zero exit status 1
Ho provato a formattarla con gparted e lui lo faceva senza problemi così mi sono accorto che aggiunge come opzione -F . Facendolo anche nello script anche questo procede senza problemi. Allego patch.
# diff /usr/local/sbin/copy_server_key copy_server_key
79a80
> '-F',