nut-triggered shutdown reboots instead
-
I am using the nut package to shut down pfSense on power failure. However, instead of shutting down and staying shut the box immediately boots up again.
Aug 4 22:52:00 upsmon 44917 UPS ups@192.168.170.10: forced shutdown in progress Aug 4 22:52:00 upsmon 44917 UPS ups@192.168.170.10 battery is low Aug 4 22:52:00 upsmon 44917 Executing automatic power-fail shutdown Aug 4 22:52:00 upsmon 44917 Auto logout and shutdown proceeding Aug 4 22:52:05 shutdown 44584 power-down by root: Aug 4 22:52:05 syslogd exiting on signal 15 Aug 4 22:52:13 syslogd kernel boot file is /boot/kernel/kernel Aug 4 22:52:13 kernel ---<<BOOT>>--- Aug 4 22:52:13 kernel Copyright (c) 1992-2021 The FreeBSD Project. Aug 4 22:52:13 kernel Copyright (c) 1979, 1980, 1983, 1986, 1988, 1989, 1991, 1992, 1993, 1994 Aug 4 22:52:13 kernel The Regents of the University of California. All rights reserved.
When I shutdown using the Halt System console option, it shuts down and stays shut. Both scripts rely on shutdown -p so that's a little confusing. Please advise, thanks.
-
@fandabrabec Is your UPS power cycling?
-
@dennypage The power wasn't flickering, the power was out from 10p through 1a. The nut server is not configured to turn the UPS proactively so the UPS just shuts down once the battery is completely depleted a few minutes after every client was supposed to shut down ("low battery" when nut clients are being turned off is set to 10%). I understand the behavior in the log could be explained if the UPS turned the power to pfSense off and then back on between 22:52:05 and 22:52:13 but I don't think it was the case. Based on the timestamps alone it would seem pfSense went from shutdown to boot immediately while the system remained powered by the UPS.