Re: cryptsetup - No key available with passphrase

Michael Kjörling <[email protected]> Fri, 3 Mar 2023 10:17:03 +0000
Newsgroups dev.linux.lists.cryptsetup
Message-ID <[email protected]>
On 3 Mar 2023 08:55 +0100, from [email protected] (Milan Broz):
> Actually it is quite interesting issue. Argon2 KDF uses a lot of memory
> and any glitch (even one bit flip) will change it's output.
> So memory failure explains what you see here.
> (You should see this rarely if --type luks1 was used for format,
> as LUKS1 does not use Argon2. But memory failure is just a recipe
> for disaster later...)

I agree. If you're seeing RAM errors on a system with non-ECC RAM, then
that's going to crop up at one point or another and bite you hard in
some hard-to-predict, difficult-to-debug and impossible-to-reproduce
manner. I'm actually surprised that if this is a RAM issue that it's as
reproducible as you reported; maybe just one memory module is bad? A
single bit stuck either as a 0 or a 1 wouldn't necessarily show up
during normal use, but something like Argon2 just might perhaps have
difficulties because of it because it's effectively an error amplifier,
and a stuck bit wouldn't necessarily cause checksum mismatches.

Consider running an extended memtest session (>24 hours or several full
passes, whichever takes longer) both after the computer has been
running for a while (and thus the components have warmed up to a
somewhat normal operating temperature), and immediately after it has
been turned off for a while, perhaps over night (allowing it to cool
down to room temperature).

At the very least, double-check the RAM specs to see what it's designed
to be clocked at, and make sure the BIOS reports that the RAM is
clocked at a specified compatible setting.

-- 
Michael Kjörling                     🔗 https://michael.kjorling.se
“Remember when, on the Internet, nobody cared that you were a dog?”