3

I've got /dev/sdb1 encrypted and mounted as /home.

The following line is in /etc/fstab:

/dev/sdb1       /home           ext3    noauto,loop=/dev/loop6,encryption=AES128

and

#mount /home

works fine, but

#losetup -e encryption=AES128 /dev/loop0 /dev/sdb1

which I'm sure always used to work, gives:

ioctl: LOOP_SET_STATUS: No such file or directory, requested cipher or key length (128 bits) not supported by kernel

Does anyone know why? If the mechanism for aes encryption over loopback devices has been changed, how am I supposed to fsck such a drive?

1 Answer 1

1

If I'm not mistaken, -e is shorthand for --encryption. Try the next command instead:

losetup --encryption AES128 /dev/loop0 /dev/sdb1

or:

losetup -e AES128 /dev/loop0 /dev/sdb1

References:

$ losetup --help
 -e | --encryption <type> enable data encryption with specified <name/num>

Taken from the examples section of man losetup:

          # dd if=/dev/zero of=/file bs=1k count=100
          # losetup -e des /dev/loop0 /file
          Password:
          Init (up to 16 hex digits):
          # mkfs -t ext2 /dev/loop0 100
          # mount -t ext2 /dev/loop0 /mnt
           ...
          # umount /dev/loop0
          # losetup -d /dev/loop0
2
  • Oops. I feel really dim now. Thank you very much. Assuming you don't mind, I'll ask for this question to be deleted, it's just noise. But thank you! Mar 16, 2011 at 21:32
  • Do not delete it, it can help people who look for the right syntax. This question is not dumb, this one is.
    – Lekensteyn
    Mar 16, 2011 at 22:00

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .