[issue961] grml-crypt error handling problem

Tong Sun bts at bts.grml.org
Sun Jan 30 18:34:41 CET 2011


New submission from Tong Sun <suntong001 at gmail.com>:

Hi, 

Just reporting the errors occurred when I was using grml-crypt. The error might
not be duplicable, but still, logged here for future reference. 

Executing the same command twice with 2 different errors:

First execution, failed to umount image and free loop dev:

% grml-crypt -f -vvv -text2 format $imgf
Debug - checkId(): accepted, UID matches "0"
Debug - your cryptsetup understands --batch-mode
Notice - Operating on a file
WARN: overwriting file Sources.img
Debug - exec-die: ( losetup /dev/loop0 Sources.img ) ret(0)
Enter LUKS passphrase: 
Debug - exec-warn: ( cryptsetup  --batch-mode --key-size 256 --cipher
aes-cbc-essiv:sha256 --iter-time 1000  luksFormat /dev/loop0 ) ret(0)
Enter passphrase for /dev/loop0: 
Debug - exec-warn: ( cryptsetup luksOpen /dev/loop0 grml-crypt_Sources.img ) ret(0)
mke2fs 1.41.12 (17-May-2010)
Debug - exec-warn: ( /sbin/mkfs.ext2 /dev/mapper/grml-crypt_Sources.img
>/dev/null ) ret(0)
Successully created ext2 on encrypted /dev/loop0
Device grml-crypt_Sources.img is busy.
WARN: problems executing ( cryptsetup luksClose grml-crypt_Sources.img ); ret(240)
Debug - exec-warn: ( cryptsetup luksClose grml-crypt_Sources.img ) ret(240)
loop: can't delete device /dev/loop0: Device or resource busy
WARN: problems executing ( losetup -d /dev/loop0 ); ret(1)
Debug - exec-warn: ( losetup -d /dev/loop0 ) ret(1)

Second execution, could not open /dev/mapper/... to create a filesystem:

% grml-crypt -f -vvv -text2 format $imgf
Debug - checkId(): accepted, UID matches "0"
Debug - your cryptsetup understands --batch-mode
Notice - Operating on a file
WARN: overwriting file Sources.img
Debug - exec-die: ( losetup /dev/loop1 Sources.img ) ret(0)
Enter LUKS passphrase: 
Debug - exec-warn: ( cryptsetup  --batch-mode --key-size 256 --cipher
aes-cbc-essiv:sha256 --iter-time 1000  luksFormat /dev/loop1 ) ret(0)
Device grml-crypt_Sources.img already exists.
WARN: could not open /dev/mapper/grml-crypt_Sources.img to create a filesystem
on it!; ret(239)
Debug - exec-warn: ( cryptsetup luksOpen /dev/loop1 grml-crypt_Sources.img )
ret(239)
Debug - exec-warn: ( cryptsetup luksClose grml-crypt_Sources.img ) ret(0)
Debug - exec-warn: ( losetup -d /dev/loop1 ) ret(0)

----------
messages: 3664
nosy: suntong
priority: bug
status: unread
title: grml-crypt error handling problem

_____________________________________
GRML issue tracker <bts at bts.grml.org>
<http://bts.grml.org/grml/issue961>
_____________________________________


More information about the Bugs-changes mailing list