Questions tagged [kexec]
kexec is a system call that enables to load and boot into another kernel from the currently running kernel.
29 questions
0
votes
1
answer
238
views
How to use kexec on Guix? Getting a blank screen
I'm trying to use kexec on Guix, which I think should be
kexec -l /run/current-system/kernel/bzImage --append="$(cat /proc/cmdline)" --initrd=/run/current-system/initrd
kexec -e
However, ...
1
vote
1
answer
239
views
Is it possible to boot into new Linux image which is stored in RAM (and not written to disk)
I'm looking to create a setup where an OS image is (automatically) downloaded over the network and then booted into. The obvious way would be to write it to disk, reconfigure grub (or whatever) and ...
2
votes
0
answers
229
views
Linux reboots with no panic when booting SMP configuration from kexec
I'm working on a project involving kexec. I have it working on some of our hardware platforms. On one platform, I'm getting sudden reboots with no panic dump during SMP setup:
[ 25.219028] smpboot: ...
1
vote
2
answers
270
views
5.4 Linux kernel on x86 panics with alignment exception when kexec'ed from 6.1 kernel
The boot chain here is UEFI -> 6.1.14 kernel built with EFI stub, initramfs loads and checks 5.4.109 kernel, then kexecs it.
CPU is a 2-core Intel Atom N6210.
When booted this way, at startup when ...
0
votes
1
answer
734
views
How to chainload another kernel with kexec inside a LUKS2 + LVM2 partition?
I have a Debian 11 installation with the following partition layout:
path
format
mount point
/dev/nvme0n1p7
ext4 (no encryption)
/boot (Debian 11)
/dev/nvme0n1p8
dm-crypt LUKS2
LVM2 (named vg_main)
/...
1
vote
1
answer
2k
views
Unable to Get Kernel Crash Dump on Kernel Panic
I'm using kexec-tools to get a crash dump of kernel on kernel panic. However, when I trigger the panic using sysrq-trigger, the system freezes. I have to power off and then power on to restore the ...
1
vote
0
answers
279
views
Load a second kernel at boot
At boot, the bootloader loads a kernel, let's say vmlinuz1. Is there a way to pass some kind of parameters to it in order to chainload another kernel (let's say vmlinuz2)? I know kexec can load ...
3
votes
0
answers
1k
views
How should I fix a failed kexec that produces "CPUs are stuck in the kernel" in dmesg?
I have built both a kernel from the Raspberry Pi sources and kexec-tools for arm64, and booted my kernel on a Raspberry Pi 4.
When I attempt to run kexec, it produces no output, exits with a nonzero ...
-2
votes
1
answer
4k
views
Installing `kali-win-kex` on WSL2 fails
I tried installing Kali-Win-Kex by following the official guide.
$ sudo apt install kali-win-kex -y
dpkg: error processing archive /var/cache/apt/archives/kali-win-kex_2.7_amd64.deb (--unpack):...
5
votes
1
answer
2k
views
kexec reboot no longer skips firmware/hard reboot after upgrade to ubuntu 20.04
(Posting here rather than the Ubuntu subsite because I don't think it's specifically related to Ubuntu...)
I've previously been successfully using kexec-reboot -lr from the exceptionally useful page ...
1
vote
1
answer
289
views
If retain_initrd is used, can this cpio image be accessed from userspace?
By default, the Linux kernel frees the memory that was used for an initramfs after its unpack is complete.
If the kernel argument retain_initrd is used, then kexec --reuseinitrd becomes available to --...
0
votes
1
answer
1k
views
Reboot with kexec without making it default and vice versa
Upon installing kexec-tools, on Ubuntu at least, I am asked if I want to use kexec to handle all invocations of reboot. I don't, but there are some occasions that I do want graceful termination of ...
1
vote
1
answer
503
views
SSH key added on boot without password prompt - how and why?
I have a passphrase-protected SSH key stored in ~/.ssh/id_rsa. In my .zshrc I have this fragment:
if ! ssh-add -l > /dev/null; then
ssh-add
fi
After booting, I usually open the terminal, see the ...
4
votes
1
answer
3k
views
How to reset the video mode of the Intel driver i915 for the kexec-ed kernel so I can see what kexec kernel is doing?
I'm running Arch Linux and I've set up kdump so that when the current kernel panics(or I manually induce a crash via sysrq+c) then another kernel(the kexec kernel) starts up in order to create a crash ...
2
votes
2
answers
3k
views
Kexec into new kernel, but I can't access the initramfs prompt!
I used kexec to successfully load my kernel, but it's just printing dmesg lines. How do I get out of this to drop into the initramfs prompt? Ctrl-Alt-F2 just loads a black screen and ctrl-c does ...