Failed to boot OS, LUKS

Hello, the newly installed OS Manjaro is nto booting, the BIOS just continuously prompts boot source when is elect HDD. But when i insert USB install disk, and in it select to boot from HDD, it asks LUKS passphrase, but than says something about invalid LUKS partition.
I read that possibly i need to disable UEFI and Secure boot. I tried all this and neatly all bios options.

My aim is to install BTRFS filesystem, LUKS encryption, no swap.
I tried partition scheme like the one on image in first post: Architect: noob uncertainty regarding SWAP and LVM

I am not sure if it matter under which BIOS config (UEFI, AHCI/IDE/Secure boot) i install the OS when i change it then before first boot.

By the way, first install attempt silently ended (just after it created luks partition in the install beginning, i have seen some errors in dmesg:


the third installation (default -automatic one, no cust. partition) luks, ext4:


finished, but the boot not worked, it complained about no such cryptodisk found.

Fourth and fifth default, ext4 luks failed failed installation, filed with error:

Btw computer not wanting to boot some instances, only thru usb flash disk, then select from boot HDD, and then it complained about missing cryptodisk.

i made the usb flash disk using YUMI from Windows.

In one of the runs i checked dmesg and it contains some “error” messages. I put it here (password: mm), please keep it private.

Then i tried to install for the 6th time, this time without LUKS. and it finished and booting OK. So what is the problem with LUKS please?

Please what should i try?

UPDATE: thanks to user megavolt i think that in case of btrfs i had to create boot partition and i not did it. He suggested creating ext2 filesystem /boot partition first with boot flag and encryption enabled (tickbox) - 500MB. Then btrfs partition with mountpoint / (maybe optional with root flag) and also encryption ticked. And installation and boot worked on Virtualbox.

If sqhashfs can’t read then the boot image on the usb drive is corrupt. Use imagewriter or win32diskimager.

pamac install imagewriter

Or use ventoy:

pamac install ventoy

and

sudo ventoy -i /dev/sdY1

sdY1 have to be the usb stick. Check it with lsblk.
Then just copy&paste the *.iso to the usb drive.

Also check your iso if the sha1 or sha56 match with your downloaded iso: Downloading File /architect/20.0.3 - Manjaro Linux - OSDN

sha256sum *.iso
sha1sum *.iso
1 Like

No, the source image is all right, i have just checked and it match SHA1 and SHA256 to manjaro-xfce-20.1.1-201001-linux58.iso
I also tried to copy the iso to different SDHC card with same kind of failure installation error like on above mentioned image.
I used YUMI software to copy the iso to SD, Rufus crash my computer. Are you nearly certain that the ventoy will solve the issues i have shown above? Can i use Microsoft Windows version of the app? As i said, it installed the system without LUKS OK, but not LUKS one… Thank you

So… in virtualbox with the same iso luks worked and on the real computer it doesn’t, correct?

Let’s investigate what the real problem there is… please do a auto installation of luks again, but this time in debug mode.

Open a terminal and type:

sudo calamares -d

and after installation upload the session log:

sudo cat /root/.cache/calamares/session.log | curl -T - https://aptget.xyz/session.log

and post the link here.

Thanks :wink:

PS: Pictures of text or logs are rather useless… really nobody will have a look at it here. Just an advice. If there is text, then post the text here. If it is short, post it directly, if it is very long, upload it somewhere else and post the link here.

1 Like

To install Manjaro on a LUKS partition, you need to use the Architect installer.

  1. Create the LUKS partition and open it.
  2. Install into the LUKS container you just created.
  3. Keep in mind that you will need a separate ESP partition, so your bootloader can access the kernel and ramdisk images from a non-encrypted partition…

I personally mounted the ESP on /efi and the /boot as a bind mount of a subdir inside the ESP on my previous setup…

Thank you both, Virtualbox fails same way as on real PC (“No such cryptodisk found”). I do not know how to do these things in Architect as i mentioned in the topic https://forum.manjaro.org/t/newbie-zfs-btrfs-in-architect-encryption-sleep-swap-mode-questions but i will now try to find some tutorial on the internet. :pensive: Regarding debug mode i suppose it would not help as i am doing things wrong way (regarding partitioning).

You can always do man cryptsetup :wink:
Just for example:

sudo cryptsetup \
  --verbose \
  --type=luks2 \
  --pbkdf=argon2id \
  --pbkdf-memory=4194304 \
  --iter-time=10000 \
  --label=LUKS2 \
  --subsystem=OS \
  luksFormat \
  /dev/sda

sudo cryptsetup \
  luksOpen \
  /dev/sda \
  luksOS

Where 4194304 means 4GiB of ram used, 10000 means 10s, /dev/sda is the harddisk you want to encrypt (full HD)
You will need to create a filesystem inside the /dev/mapper/luksOS afterwards. (This is where you access the luks container opened above)

That is weird… i installed Manjaro XFCE 20.1.1 minimal with LUKS and auto installation in virtualbox. No problems. I did nothing special. No manual partitioning…

I would advice to compare how the auto partitioning of calamares looks and your way of manually partitioning.

I would run sudo parted -l to compare the partitioning.

My reply was in regards to LUKS2 :wink:

Your replies are quite general and targeted to experienced Linux users which i am not. So i can not be much helpfull in my replies and have to ask additional questions instead. So here i am.
grub command line does not allow me to run “sudo parted -l”.
You say to compare partitioning. But i already shown the screenshot in my first post here. That partitioning failed. All failed except the one done without LUKS. I tried to launch sudo calamares -d
but it failed with segfault. (this was done on Virtualbox) . Sorry megavolt, i posted the image as i am unable to make Virtualbox to use clipboard.

UPDATE: @megavolt helped me to do right partitioning in Calamarus GUI installer. I have not created boot partition. He suggested creating ext2 filesystem /boot partition first with boot flag and encryption enabled (tickbox) - 500MB. Then btrfs partition with mountpoint / (maybe optional with root flag) and also encryption ticked. And installation and boot worked on Virtualbox. I will report later if i have new findings on real PC installation. or if there be any related issues. thank you very much