cryptsetup fails to open device

This forum is for topics specific to the Raspberry Pi and Arch Linux ARM

cryptsetup fails to open device

Postby smaxer » Sat Jun 15, 2013 9:13 am

Hi,

I'm having problems opening my encrypted device on my raspberry:

$this->bbcode_second_pass_code('', '
alarmpi@~ # cryptsetup luksOpen /dev/sdc1 Book --key-file /opt/home/keys/Book
device-mapper: reload ioctl on failed: No such file or directory
Failed to open temporary keystore device.
device-mapper: remove ioctl on temporary-cryptsetup-1921 failed: No such device or address
device-mapper: reload ioctl on temporary-cryptsetup-1921 failed: No such device or address
device-mapper: remove ioctl on temporary-cryptsetup-1921 failed: No such device or address
device-mapper: remove ioctl on temporary-cryptsetup-1921 failed: No such device or address
device-mapper: remove ioctl on temporary-cryptsetup-1921 failed: No such device or address
device-mapper: remove ioctl on temporary-cryptsetup-1921 failed: No such device or address
')

and in with dmesg I read:
$this->bbcode_second_pass_code('', '
[60063.506832] device-mapper: table: 253:0: crypt: Error allocating crypto tfm
[60063.506863] device-mapper: ioctl: error adding target to table
')

Does anybody have an idea what I'm missing oder whats goging wrong?

Thanks,
Chris
smaxer
 
Posts: 23
Joined: Sat Jun 15, 2013 9:01 am

Re: cryptsetup fails to open device

Postby sdjf » Sun Jun 30, 2013 8:25 am

You might try starting your command with strace, which will give you debugging output and show system calls.

strace -s 100 -o NAMEOFOUTPUTFILE YOURCOMMAND ANYOPTIONS &

I cannot make out what all these things are in your output, but try a simple ls to see whether they are in a different directory and you might need to give the full paths to them. I have no experience with what you are asking about, but since nobody else has jumped in, figure some simple basic debugging advice might help.

That first error message looks like it is missing an argument, double check the man page for your command and make sure you have entered all the required options and parameters with the correct syntax.
sdjf
 
Posts: 178
Joined: Wed May 08, 2013 1:55 pm

Re: cryptsetup fails to open device

Postby smaxer » Tue Jul 09, 2013 8:42 pm

Hi sdif,

thanks for the reply the problem was rather simple "depmod -a" didn't work:
$this->bbcode_second_pass_code('', '
#depmod -a
depmod: ERROR: could not open directory /lib/modules/3.6.11-11-ARCH+: No such file or directory
depmod: FATAL: could not search modules: No such file or directory
')
and an "ls" in /lib/modules gave the following:
$this->bbcode_second_pass_code('', '
# ls /lib/modules
3.6.11-13-ARCH+ extramodules-3.6.11--raspberrypi
')
So I solved it by "ln -s 3.6.11-13-ARCH+ 3.6.11-11-ARCH+". Depmod works now so does cryptsetup but my problem is that even if I install the latest Kernel (linux-raspberrypi-3.6.11-13) for the next reboot it says in dmesg:
$this->bbcode_second_pass_code('', '
#dmesg
[ 0.000000] Linux version 3.6.11-11-ARCH+ (nobody@panda5) (gcc version 4.7.2 (GCC) ) #1 PREEMPT Tue May 14 16:12:58 UTC 2013
#uname -a
Linux alarmpi 3.6.11-11-ARCH+ #1 PREEMPT Tue May 14 16:12:58 UTC 2013 armv6l GNU/Linux
')

So I somehow messed up the kernel boot order but I don't know how to fix that.... anybody an idea?

Thanks
smax
smaxer
 
Posts: 23
Joined: Sat Jun 15, 2013 9:01 am

Re: cryptsetup fails to open device

Postby WarheadsSE » Tue Jul 09, 2013 8:50 pm

Time to reboot.
Core Developer
Remember: Arch Linux ARM is entirely community donation supported!
WarheadsSE
Developer
 
Posts: 6807
Joined: Mon Oct 18, 2010 2:12 pm

Re: cryptsetup fails to open device

Postby smaxer » Tue Jul 09, 2013 8:51 pm

I did already a reboot, several reboots....didn't help.
smaxer
 
Posts: 23
Joined: Sat Jun 15, 2013 9:01 am

Re: cryptsetup fails to open device

Postby WarheadsSE » Tue Jul 09, 2013 9:30 pm

make sure your boot partition is mounted, then update the kernel or reinstall it.
Core Developer
Remember: Arch Linux ARM is entirely community donation supported!
WarheadsSE
Developer
 
Posts: 6807
Joined: Mon Oct 18, 2010 2:12 pm

Re: cryptsetup fails to open device

Postby smaxer » Tue Jul 09, 2013 9:44 pm

Thanks, Warhead! For some reason I didn't have the /boot partition listed in fstab. Fixed now. Works now.

Thanks and good night!
smaxer
 
Posts: 23
Joined: Sat Jun 15, 2013 9:01 am


Return to Raspberry Pi

Who is online

Users browsing this forum: No registered users and 4 guests