How to Fix Boot Timeout with LUKS Encrypted Swap?

August 9, 2025 1 answer
Asked by CuriousCat88
I've set up LUKS encryption for both my root and swap partitions. However, I've noticed that when I decrypt the root partition, there's a delay of about 1:30 minutes before I can access the login screen. During the wait, I see these messages: `[TIME] Timed out waiting for device /dev/.` and `[DEPEND] Dependency failed for Swaps.` It seems like the system is trying to find the swap partition but fails to do so. I haven't set up auto-decryption for the swap partition because previous attempts caused issues, so I end up manually decrypting and mounting it each boot. Is there a way to bypass the timeout or a better solution for this setup? Thanks!

Answers

TechWhiz42
Have you considered using a swap file on your encrypted root partition instead of a separate swap partition? It might simplify things. Alternatively, you can set up an automatic cryptswap which generates a random key and takes care of the mounting for you. Check out section 1 of the Arch wiki on swap encryption for more details!

CuriousCat88: I thought using crypttab would lose the swap data on reboot, which didn't seem ideal. But I'm definitely going to check it out. Thanks for the suggestion!

Reply to this answer

Add your answer

Answers are reviewed before publication.

Related Discussions