Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

Failed to setup dm-crypt key mapping

41 views
Skip to first unread message

jenapl...@gmail.com

unread,
Jul 15, 2008, 7:46:55 PM7/15/08
to
Hello!!!
I'm sorry for my bad english...
I have a problem with dm-cypt...
I was following this tutotrial
http://ubuntu-tutorials.com/2007/08/17/7-steps-to-an-encrypted-partition-local-or-removable-disk/
to create an encrypted partition but at step 5 when i have to encrypt
the partition with cryptsetup luksFormat i receive this error:

cryptsetup luksFormat /dev/hdb1 -c aes -s 256 -h sha256

WARNING!
========
This will overwrite data on /dev/hdb1 irrevocably.

Are you sure? (Type uppercase yes): YES
Enter LUKS passphrase:
Verify passphrase:
Failed to setup dm-crypt key mapping.
Check kernel for support for the aes-cbc-plain cipher spec and verify
that /dev/hdb1 contains at least 258 sectors.
Failed to write to key storage.
Command failed.

I look to the dm-crypt wiki http://www.saout.de/tikiwiki/tiki-index.php?page=LUKSFaq:
dm-crypt does not work properly.

1. Check if you have a /dev/ tree, including /dev/mapper/control.
I think it's ok this is the out:
ls -l /dev/mapper/control
crw-rw---- 1 root root 10, 63 2008-07-15 18:43 /dev/mapper/control

2. Check if you have device mapper and dm-crypt included in the kernel
I think it's ok this is the out:
dmsetup targets
crypt v1.5.0
multipath v1.0.5
striped v1.0.2
linear v1.0.2
error v1.0.1

3. Check if you have the cipher you want to use included in the
kernel.
This is the out:
cat /proc/crypto
name : sha512
driver : sha512-generic
module : sha512
priority : 0
refcnt : 1
type : digest
blocksize : 128
digestsize : 64

name : sha384
driver : sha384-generic
module : sha512
priority : 0
refcnt : 1
type : digest
blocksize : 128
digestsize : 48

name : cbc(aes)
driver : cbc(aes-generic)
module : cbc
priority : 100
refcnt : 1
type : blkcipher
blocksize : 16
min keysize : 16
max keysize : 32
ivsize : 16

name : aes
driver : aes-generic
module : aes
priority : 100
refcnt : 1
type : cipher
blocksize : 16
min keysize : 16
max keysize : 32

name : sha256
driver : sha256-generic
module : sha256
priority : 0
refcnt : 1
type : digest
blocksize : 64
digestsize : 32

name : md5
driver : md5-generic
module : kernel
priority : 0
refcnt : 1
type : digest
blocksize : 64
digestsize : 16

The modules are manually loaded they are:

lsmod |grep dm
dm_round_robin 4480 1
dm_crypt 14984 0
dm_multipath 20488 2 dm_round_robin
dm_mod 58816 8 dm_crypt,dm_multipath

I use kubuntu 7.10 with kernel 2.6.22-15-generic...
I don't understand what's the problem...
I hope you can help me...
Thank you!!!

0 new messages