Solved Unable to shutdown multiple computers - EFI issue

Using the latest versions of FreeBSD (13/14-RELEASE) I have begun to encounter issues with powering off computers.

The current procedure that occurs is after sending the
poweroff command, the computer will begin the normal shutdown process. The computer will power off for about 5 seconds or so and then turn itself back on, followed by a normal boot. When I say turn off the fans stop, the front LEDs extinguish, the disk spins down, etc.

I have encountered this problem on several computers, all of which were the same, HP 6200 Pro SFF, but have also encountered it on a separate Viglen PC. All the machines use Intel CPUs of various models.

If I press and hold the power button for 5 or so seconds the power will "hard power off" and the PC will not restart by itself. So unlikely power switch shorted as some have reported this on this model of PC.

I have tinkered with resetting the BIOS, replacing the BIOS battery, upgrading the BIOS and numerous boot/BIOS options with no success.

Finally today I created an Ubuntu boot disk and tested the shutdown with that. Sure enough, on giving Ubuntu the
poweroff command the computer duly shuts down and stays off. Leading me to think that something in FreeBSD shutdown is perhaps leaving something in system activated and hence why the computer wakes itself up.

I have had a look to see if there were any
sysctl options that may slow down a shutdown but ensure everything is terminated. Nothing really jumped out at me.

If I need to supply more information, like a shutdown trace, please let me know and I'll figure how to do.

Any help is greatly appreciated in advance.
 
The computer will power off for about 5 seconds or so and then turn itself back on, followed by a normal boot. When I say turn off the fans stop, the front LEDs extinguish, the disk spins down, etc.
EFI boot? Maybe this will help:
Code:
# sysctl -d hw.efi.poweroff
hw.efi.poweroff: If true, use EFI runtime services to power off in preference to ACPI
On some systems I have to switch it to ACPI (0) or it would turn itself on again after a shutdown.
 
Oh my! Provisionally Solved and made me laugh.

Took me quite a while to write the description to make sure it all made sense and the solution was so quick.

It has worked on one machine. I will thoroughly test tomorrow and mark this solved.

Although I did learn to search poweroff too. I had been running
sysctl -a | grep -i shutdown
 
Back
Top