The kernel freezes every process before it loads a hibernated image, so the screen looked hung for as long as the load took. A drop-in on systemd-hibernate-resume.service now opens the kernel console just before resume, draws a band across the middle of tty12 and confines the kernel's progress lines to it. The running bootvine stops drawing and stops taking the console back meanwhile, and repaints if no image was restored.
21 lines
451 B
Bash
Executable File
21 lines
451 B
Bash
Executable File
#!/usr/bin/bash
|
|
|
|
check() {
|
|
require_binaries bootvine || return 1
|
|
return 255
|
|
}
|
|
|
|
depends() {
|
|
echo systemd
|
|
}
|
|
|
|
install() {
|
|
inst_binary bootvine
|
|
inst_simple "$systemdsystemunitdir/bootvine.service"
|
|
inst_simple "$systemdsystemunitdir/systemd-hibernate-resume.service.d/bootvine.conf"
|
|
if [[ -f /etc/bootvine.toml ]]; then
|
|
inst_simple /etc/bootvine.toml
|
|
fi
|
|
$SYSTEMCTL -q --root "$initdir" enable bootvine.service
|
|
}
|