Page MenuHomeFreeBSD

/etc/rc: Wait for init to shutdown after reboot sentinel
AbandonedPublic

Authored by feld on Feb 9 2018, 4:03 PM.
Tags
None
Referenced Files
Unknown Object (File)
Wed, Jun 26, 4:36 PM
Unknown Object (File)
Dec 20 2023, 7:22 AM
Unknown Object (File)
Nov 10 2023, 7:12 AM
Unknown Object (File)
Nov 6 2023, 10:21 PM
Unknown Object (File)
Aug 22 2023, 5:25 AM
Unknown Object (File)
Jul 24 2023, 11:20 AM
Unknown Object (File)
Jun 15 2023, 6:53 PM
Unknown Object (File)
Jun 3 2023, 1:42 AM
Subscribers
None

Details

Reviewers
imp
Summary

The firstboot / reboot logic sends init a SIGINT once the firstboot
scripts are complete, but because there is no sleep or wait_for_pids the
system tries to continue booting and starting more rc scripts. This
causes services to begin starting and then abruptly get shutdown which
is pointless and potentially harmful.

Diff Detail

Repository
rS FreeBSD src repository - subversion
Lint
Lint Passed
Unit
No Test Coverage
Build Status
Buildable 14897
Build 15009: arc lint + arc unit

Event Timeline

Only 7 more commits to this logic, and it might be right.

This revision is now accepted and ready to land.Feb 9 2018, 4:05 PM

I can't seem to make this work for me as I expected. I think the problem is that this is run after "run_rc_script" on line 129, so all of the rc scripts have already run before it checks this. I think without a major redesign of the logic in this file we cannot get the behavior I was expecting.