Page MenuHomeFreeBSD

Add kern.reboot_wait_time sysctl
ClosedPublic

Authored by cperciva on Jul 13 2022, 12:43 AM.
Tags
None
Referenced Files
Unknown Object (File)
Fri, May 3, 9:38 AM
Unknown Object (File)
Mar 18 2024, 9:42 PM
Unknown Object (File)
Mar 18 2024, 9:42 PM
Unknown Object (File)
Mar 18 2024, 9:42 PM
Unknown Object (File)
Mar 18 2024, 9:30 PM
Unknown Object (File)
Jan 14 2024, 10:21 AM
Unknown Object (File)
Dec 24 2023, 3:18 AM
Unknown Object (File)
Dec 20 2023, 7:38 AM
Subscribers

Details

Summary

Historic FreeBSD behaviour (dating back to 1994-04-02) when rebooting
is to print "Rebooting..." and then
/* wait 1 sec for printf's to complete and be read */

Prior to April 1994, there was a 100 ms delay (added 1993-11-12).

Since (a) most users will already be aware that the system is rebooting
and do not need to take time to read an additional message to that
effect, and (b) most FreeBSD systems don't have anyone actively looking
at the console anyway, this delay no longer serves much purpose.

This commit adds a kern.reboot_wait_time sysctl which defaults to 0;
historic behaviour can be regained by setting it to 1.

Sponsored by: https://www.patreon.com/cperciva

Diff Detail

Repository
rG FreeBSD src repository
Lint
Lint Not Applicable
Unit
Tests Not Applicable

Event Timeline

This revision is now accepted and ready to land.Jul 13 2022, 12:53 AM

Not sure if it's worth mentioning in UPDATING -- it's not exactly a breaking change.

Maybe worth adding a Relnotes: header, although it does feel a bit odd writing "if you want your system to reboot slowly...".

Not sure if it's worth mentioning in UPDATING -- it's not exactly a breaking change.

As far as you know... But keeping it as just relnote is fine unless we get a lot of support traffic I suppose (a lot here would be > 1 or 2 since I suspect this will burn that number of people).

Maybe worth adding a Relnotes: header, although it does feel a bit odd writing "if you want your system to reboot slowly...".

True, but many of these weird quirks we have to 'slow things down' are there so we 'just work' on some weird system someone had back in the day. It's hard to know if that's a common or uncommon need today, but documenting will allow the edge case crowd a chance to set this value if by some weird chance their systems need it. I can imagine that a monitoring system might need the whole 'rebooting' message to know the system was cleanly rebooted, for example... But that too is likely an edge case given then size of FIFOs on UARTS these days...

This revision was automatically updated to reflect the committed changes.