https://labs.parabola.nu/https://labs.parabola.nu/favicon.ico?15367742552017-07-19T09:52:23ZParabola Issue TrackerPackages - Bug #1419: [cryptsetup] race condition => doesn't find key, waits for rootfs, and timeoutshttps://labs.parabola.nu/issues/1419?journal_id=81082017-07-19T09:52:23Zfablamar78
<ul></ul><p>You can read this : <a class="external" href="https://labs.parabola.nu/issues/1416">https://labs.parabola.nu/issues/1416</a></p>
<p>Other workaround :</p>
<p>"mkinitcpio-busybox 1.26 broke the encrypt hook somehow.<br />people have had success reverting to 1.25.1-2, or renaming the keyfile to /crypto_keyfile.bin while removing the cryptkey parameter alltogether:<br /><a class="external" href="https://lists.parabola.nu/pipermail/assist/2017-July/000865.html">https://lists.parabola.nu/pipermail/assist/2017-July/000865.html</a>"</p>
<p>How I solved the issue on my setup :</p>
<p>1. Show keys<br />cryptsetup luksDump /dev/sda1</p>
<p>2. Remove old key in luks (in my case, the key was in Key Slot 1, make sure it is..)</p>
<p>cryptsetup luksKillSlot /dev/sda1 1</p>
<p>3. Remove old key in FS :</p>
<p>rm /etc/yourkey (mine was /etc/pass)</p>
<p>4. Create a new keyfile as /crypto_keyfile.bin</p>
<p>dd bs=512 count=4 if=/dev/urandom of=/crypto_keyfile.bin iflag=fullblock</p>
<p>5. Add it to luks :</p>
<p>cryptsetup luksAddKey /dev/sda1 /crypto_keyfile.bin</p>
<p>chmod 000 /crypto_keyfile.bin</p>
<p>6. Edit "FILES=" in mkinitcpio.conf so it reflects the location of the new key :</p>
<p>FILES="/crypto_keyfile.bin"</p>
<p>7. Create initramfs again</p>
<p>mkinitpcio -p linux-libre #Or other kernel..</p>
<p>8. Remove "cryptkey=rootfs:/path/to/key" arg from your linux cmd (not needed anymore as now using /crypto_keyfile.bin which is default path)</p>
<p>Reboot</p> Packages - Bug #1419: [cryptsetup] race condition => doesn't find key, waits for rootfs, and timeoutshttps://labs.parabola.nu/issues/1419?journal_id=82692017-09-18T00:27:04ZAnonymous
<ul></ul><p>what should I do if I have no key in slot 1 but only in slot 0.</p>
<p>It keeps dropping me to a shell for the same reason...</p> Packages - Bug #1419: [cryptsetup] race condition => doesn't find key, waits for rootfs, and timeoutshttps://labs.parabola.nu/issues/1419?journal_id=82702017-09-18T02:08:06Zisacdaavid
<ul><li><strong>Related to</strong> <i><a class="issue tracker-1 status-2 priority-3 priority-default closed" href="/issues/1416">Bug #1416</a>: cryptkey=rootfs:/etc/pass issue | keyfile is not added to initramfs somehow</i> added</li></ul> Packages - Bug #1419: [cryptsetup] race condition => doesn't find key, waits for rootfs, and timeoutshttps://labs.parabola.nu/issues/1419?journal_id=84842017-11-03T18:03:23ZGNUtooGNUtoo@cyberdimension.org
<ul></ul>Now it seems to work again with:
<ul>
<li>cryptsetup 1.7.5-1</li>
<li>mkinitcpio 23-2</li>
<li>mkinitcpio-busybox 1.27.2-1</li>
</ul>
<p>I don't know what fixed it.</p>
<p>Denis.</p> Packages - Bug #1419: [cryptsetup] race condition => doesn't find key, waits for rootfs, and timeoutshttps://labs.parabola.nu/issues/1419?journal_id=85372017-11-10T16:07:31Zisacdaavid
<ul><li><strong>Status</strong> changed from <i>open</i> to <i>fixed</i></li></ul><p>overcome by circumstances that we never quite figured out S:</p>