How to fix a broken ACPI
Translations
Stop the normal boot of the kernel
You have to tell the kernel to go into boot_config(8)
before
performing autoconf(4)
procedures.
To do this enter -c
at the kernel boot prompt:
boot> -c
Press Enter and you kernel should now be in UKC mode.
If you want to boot another kernel and enter UKC mode:
boot> boot hd0a:/bsd.rd -c
Configure kernel "on the fly"
The UKC mode is the User Kernel Configuration mode, and it displays
yet another prompt: UKC>
On this prompt, to disable ACPI, enter the following:
UKC> disable acpi
492 acpi disabled
The 492 acpi disabled
message indicates the kernel has now disabled
its ACPI functions and will not attempt to configure ACPI during normal
booting.
The same procedure, of course, can be applied to other malfunctioning interfaces or peripherals that crash the OpenBSD kernel.
On one of my older notebooks this helps:
UKC> disable acpiprt* 426 acpiprt* disabled
But on my Thinkpad 570 it displays
503 acpiprt* disabled
.
Once the kernel configuration has been modified, type the following to continue booting:
UKC> quit
If the kernel has booted normally, see below to make this change permanent. If not, restart the configuration from the very beginning, and try disabling the next offending peripheral.
Try the following for a list of all kernel options:
UKC> list
You can also try help
or ?
at the UKC> prompt for more
information on the User Kernel Configuration.
Make the kernel configuration changes permanent
Before you do anything, please make sure you read the excellent OpenBSD FAQ and for this case especially the section on kernel configuration.
The command to be entered is the following one:
# config -u -f -e /bsd
The problem here is config(8) -u
needs kvm(3)
to access the changes
made during boot in UKC, with OpenBSD 6.1 access to /dev/{,k}mem
was disabled at securelevel > 0.
We can override this by putting kern.allowkmem=1
into
/etc/sysctl.conf
and reboot but this would break the securelevel.
Better option is to launch config(8)
retype the changes and
write the modified kernel to another file (here bsd.new
):
# config -e -o /bsd.new /bsd