[dm-crypt] Cannot wipe header on device

David Christensen dpchrist at holgerdanske.com
Thu Dec 10 20:06:13 CET 2015


On 12/10/2015 02:18 AM, Luís de Sousa wrote:
> I am trying to encrypt an external hard drive on Ubuntu 14.04 ...
> $ sudo cryptsetup -y -v luksFormat /dev/sdb1

Why "-y"?  It seems to be the default when I do "cryptsetup luksFormat" 
on Debian.


> Cannot wipe header on device /dev/sdb1.
> Command failed with code 5: Cannot wipe header on device /dev/sdb1.
...
> [ 3208.140990] usb 2-1.4: New USB device found, idVendor=059f, idProduct=0651
> [ 3208.141001] usb 2-1.4: New USB device strings: Mfr=1, Product=2,
> SerialNumber=3
> [ 3208.141024] usb 2-1.4: Product: LaCie Hard Drive USB
> [ 3208.141031] usb 2-1.4: Manufacturer: LaCie

I prefer StarTech.


> [ 3209.176917] scsi 4:0:0:0: Direct-Access     SEAGATE  ST3160812A
>    3.AA PQ: 0 ANSI: 2
> [ 3209.177561] sd 4:0:0:0: Attached scsi generic sg2 type 0
> [ 3209.181342] sd 4:0:0:0: [sdb] 312581808 512-byte logical blocks:
> (160 GB/149 GiB)

That's an older PATA drive:

     http://www.seagate.com/support/disc/manuals/ata/100389997c.pdf


> $ tail /var/log/syslog
> Dec  8 09:18:20 MekanikDestruktiwKommandoh kernel: [ 3698.016311]
> end_request: critical target error, dev sdb, sector 0
> Dec  8 09:18:28 MekanikDestruktiwKommandoh wpa_supplicant[1188]:
> wlan0: CTRL-EVENT-SCAN-STARTED

Have you run the Seagate SeaTools Diagostics?  I prefer the DOS version 
-- it's a stand-alone bootable CD:

     http://www.seagate.com/support/downloads/seatools/


If SeaTools finds a problem:

1.  Plug the drive into a different machine and try again.

2.  If the problem persists, open up the USB case, pull the drive, put 
it into a desktop/ server machine with a PATA interface, and run 
SeaTools again.


Otherwise, it's something in Ubuntu.  Try another Linux distribution.


David



More information about the dm-crypt mailing list