Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
cryptsetup luksOpen reload ioctl on drive failed
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Kernel & Hardware
View previous topic :: View next topic  
Author Message
baldr333
n00b
n00b


Joined: 19 May 2021
Posts: 14
Location: Quebec

PostPosted: Sun May 26, 2024 12:06 am    Post subject: cryptsetup luksOpen reload ioctl on drive failed Reply with quote

Kernel 6.7.6 with openrc

Trying to mount a luks encrypted usb and failing, the drive works fine on other machines

Code:

sudo cryptsetup luksOpen /dev/sdb1 drive


output is:
Code:

device-mapper: reload ioctl on drive (253:0) failed: Invalid argument


from dmesg:
Code:

[ 6610.130723] device-mapper: table: 253:0: crypt: unknown target type
[ 6610.130726] device-mapper: ioctl: error adding target to table


luksDump from a luksFormat test file: https://bpa.st/G4XQ

Kernel config: https://dpaste.com/7HH8BR8UK

At this point I have no clue what could be causing this
played around extensively in the kernel and tried enabling the kernel use flag on cryptsetup but it did not do anything.
Wondering if the fact I do not have an initramfs on this machine could be the issue ?
Any clue in figuring this out will be much appreciated
Back to top
View user's profile Send private message
user
Apprentice
Apprentice


Joined: 08 Feb 2004
Posts: 211

PostPosted: Mon May 27, 2024 8:39 pm    Post subject: Reply with quote

Hi baldr333,
kernel config looks good.
cryptsetup missing argon2 support?

Code:
# equery u sys-fs/cryptsetup
Back to top
View user's profile Send private message
baldr333
n00b
n00b


Joined: 19 May 2021
Posts: 14
Location: Quebec

PostPosted: Tue May 28, 2024 11:40 pm    Post subject: Reply with quote

Hi,

Seem's like the argon2 flag was already set.

I tried enabling the Kernel useflag instead of the openssl one ,which was the default crypto backend,
but this time I get:

Code:

Cannot initialize crypto backend.
Device /dev/sdb1 is not a valid LUKS device.


Going to have to read more on this to try and figure it out, I have already read the dm-crypt wiki pages quite a few time but still can't figure out exactly what the problem is
Back to top
View user's profile Send private message
The Main Man
Veteran
Veteran


Joined: 27 Nov 2014
Posts: 1171
Location: /run/user/1000

PostPosted: Wed May 29, 2024 11:11 am    Post subject: Reply with quote

It's not initramfs, I don't have it either and it works.
Back to top
View user's profile Send private message
baldr333
n00b
n00b


Joined: 19 May 2021
Posts: 14
Location: Quebec

PostPosted: Sun Jun 16, 2024 1:03 am    Post subject: Reply with quote

Switched to the distribution Kernel and that solved my problem
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Kernel & Hardware All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum