https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=284892
Bug ID: 284892 Summary: rc(8) is not clear that /usr/local/etc/rc.d/ files are not run until after $early_late_divider Product: Documentation Version: Latest Hardware: Any OS: Any Status: New Severity: Affects Some People Priority: --- Component: Manual Pages Assignee: b...@freebsd.org Reporter: jeff+free...@wagsky.com CC: d...@freebsd.org The man page leads off with Typically, the /usr/local/etc/rc.d/ mechanism is used instead of rc.local these days but if you want to use rc.local, it is still supported. In this case, it should source /etc/rc.conf and contain additional custom startup code for your system. The best way to handle rc.local, however, is to separate it out into rc.d/ style scripts and place them under /usr/local/etc/rc.d/. While this is functional for scripts that run after FILESYSTEMS ($early_late_divider), it does not work for scripts that need to run earlier. `rcorder /etc/rc.d/* /usr/local/etc/rc.d/my_script` shows the expected order, based on the BEFORE and REQUIRED statements. However, the reality is that it will not be run until after FILESYSTEMS. >From /etc/rc # Do a first pass to get everything up to $early_late_divider so that # we can do a second pass that includes $local_startup directories # unset system_rc find_system_scripts files=`rcorder ${skip} ${skip_firstboot} ${system_rc} 2>/dev/null` _rc_elem_done=' ' for _rc_elem in ${files}; do run_rc_script ${_rc_elem} ${_boot} _rc_elem_done="${_rc_elem_done}${_rc_elem} " case "$_rc_elem" in */${early_late_divider}) break ;; esac done -- You are receiving this mail because: You are the assignee for the bug.