View previous topic :: View next topic |
Author |
Message |
kucklehead Tux's lil' helper
Joined: 13 Oct 2020 Posts: 108
|
|
Back to top |
|
|
alamahant Advocate
Joined: 23 Mar 2019 Posts: 3879
|
Posted: Sat Sep 11, 2021 8:32 am Post subject: |
|
|
It might be the case that
/dev/mmcblk
changes to /dev/sdx
Plz use PARTUUID or UUID _________________
|
|
Back to top |
|
|
Hu Moderator
Joined: 06 Mar 2007 Posts: 21606
|
Posted: Sat Sep 11, 2021 3:56 pm Post subject: |
|
|
Killed is not normal here. My suspicion is that your cryptsetup dies badly, before it can finish its work. If you drop to a rescue shell and do the initramfs steps by hand, do you also get Killed? What is the full command that is killed to produce that output? |
|
Back to top |
|
|
kucklehead Tux's lil' helper
Joined: 13 Oct 2020 Posts: 108
|
Posted: Sat Sep 11, 2021 7:48 pm Post subject: |
|
|
When I do drop into shell and do the initramfs by hand, I still get the same results.
Example: If I type in cryptsetup open /dev/mmcblk1p2 cryptlvm
It'll ask for my password, and the same error is "reproduced"
If I go into shell and poke around such as:
Which it pops up all the busybox tools, and my devices. Which is good
I got done with building arch linux systemd build, and to setup my stuff, I ran this expression:
Code: | cryptsetup --type luks2 --cipher aes-xts-plain64 --hash sha256 --iter-time 2000 --key-size 256 --pbkdf argon2i --sector-size 512 --use-urandom --verify-passphrase luksFormat device |
Note: This is all done in chroot, which shouldn't be a problem at all.
As for using UUIDs. I switched from using /dev/mapper/<logical volume> to using UUIDS in my fstab. For my kernel parameters, my root isn't in UUID. I'll change that into UUIDs, and see if that works.
Edit:
I have a feeling it might be the command I typed in that is causing it to die. Even reading this right here again:
https://wiki.gentoo.org/wiki/Dm-crypt
The only commands I need are:
Code: |
cryptsetup -s 512 luksFormat /dev/sdb2
cryptsetup luksOpen /dev/sdb2 cryptlvm
|
Which I can set my lvm on it. The question is though, if it is that command, can I still recover it? |
|
Back to top |
|
|
kucklehead Tux's lil' helper
Joined: 13 Oct 2020 Posts: 108
|
Posted: Sun Sep 12, 2021 6:29 pm Post subject: |
|
|
I was wrong about the command. How do I debug it and find out why it is outputting "Killed" whenever I try to manually open it or open it on boot. This is for a Chromebook, and I don't know if that affects anything exactly? |
|
Back to top |
|
|
alamahant Advocate
Joined: 23 Mar 2019 Posts: 3879
|
Posted: Sun Sep 12, 2021 6:56 pm Post subject: |
|
|
If you have logical volumes you do NOT need UUID
Maybe only for the cryptdevice. _________________
|
|
Back to top |
|
|
Hu Moderator
Joined: 06 Mar 2007 Posts: 21606
|
Posted: Sun Sep 12, 2021 7:03 pm Post subject: |
|
|
Normally, Killed would be printed by your shell to advise you that the child process was terminated by a SIGKILL. It's rather unusual for that to happen in interactive contexts. The only case I can think of would be that your cryptsetup was built with buffer overrun detection, and a buffer overrun occurred, which triggered the handler to SIGKILL the process to contain further damage. If so, an strace should confirm that it is sending itself a SIGKILL. Normally, I would expect this sequence of events to also print a fairly obvious diagnostic about "stack smashing detected" just before the SIGKILL is sent. |
|
Back to top |
|
|
kucklehead Tux's lil' helper
Joined: 13 Oct 2020 Posts: 108
|
Posted: Wed Sep 15, 2021 1:31 am Post subject: |
|
|
Unfortunately strace isn't built with my busybox shell. Been following this guide here: https://linux.die.net/man/1/strace
Is there any debugging tools that come with it or do I have to include strace into it?
I tried installing it with dracut and it doesn't load past loading initramfs <gentoo>
These are the commands I used to build the init with dracut:
Code: |
cd /usr/src/linux
make menuconfig
make -j3
make modules_install
make install
ls /lib/modules
dracut --force -H --kver <gentoo-kernel-bin-version>
|
creyptsetup luksOpen /dev/mmcblk1p2 cryptlvm results in the same error. |
|
Back to top |
|
|
kucklehead Tux's lil' helper
Joined: 13 Oct 2020 Posts: 108
|
Posted: Sat Sep 18, 2021 6:05 pm Post subject: |
|
|
How do I trace it? I was googling it and found pgrep? Is there an article I can read. How do I do this exactly? |
|
Back to top |
|
|
Hu Moderator
Joined: 06 Mar 2007 Posts: 21606
|
Posted: Sat Sep 18, 2021 7:10 pm Post subject: |
|
|
strace -o /tmp/crypt.strace -f -tt crypsetup luksOpen /dev/mmcblk1p2 cryptlvm. Before posting, edit your password out of the strace output. If cryptsetup crashes even on a wrong password, that would be ideal, as you could just enter a dummy password that it does not matter if we know. |
|
Back to top |
|
|
kucklehead Tux's lil' helper
Joined: 13 Oct 2020 Posts: 108
|
|
Back to top |
|
|
|