Deleted Added
full compact
rc.subr.8 (160615) rc.subr.8 (161530)
1.\" $NetBSD: rc.subr.8,v 1.12 2004/01/06 00:52:24 lukem Exp $
2.\"
3.\" Copyright (c) 2002-2004 The NetBSD Foundation, Inc.
4.\" All rights reserved.
5.\"
6.\" This code is derived from software contributed to The NetBSD Foundation
7.\" by Luke Mewburn.
8.\"

--- 20 unchanged lines hidden (view full) ---

29.\" BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
30.\" CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
31.\" SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
32.\" INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
33.\" CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
34.\" ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
35.\" POSSIBILITY OF SUCH DAMAGE.
36.\"
1.\" $NetBSD: rc.subr.8,v 1.12 2004/01/06 00:52:24 lukem Exp $
2.\"
3.\" Copyright (c) 2002-2004 The NetBSD Foundation, Inc.
4.\" All rights reserved.
5.\"
6.\" This code is derived from software contributed to The NetBSD Foundation
7.\" by Luke Mewburn.
8.\"

--- 20 unchanged lines hidden (view full) ---

29.\" BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
30.\" CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
31.\" SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
32.\" INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
33.\" CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
34.\" ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
35.\" POSSIBILITY OF SUCH DAMAGE.
36.\"
37.\" $FreeBSD: head/share/man/man8/rc.subr.8 160615 2006-07-24 10:07:27Z yar $
37.\" $FreeBSD: head/share/man/man8/rc.subr.8 161530 2006-08-22 11:17:29Z flz $
38.\"
39.Dd June 21, 2006
40.Dt RC.SUBR 8
41.Os
42.Sh NAME
43.Nm rc.subr
44.Nd functions used by system shell scripts
45.Sh SYNOPSIS

--- 281 unchanged lines hidden (view full) ---

327.Fl e .
328By default, the module is assumed to have the same name as
329.Ar file ,
330which is not always the case.
331.It Ic load_rc_config Ar name
332Source in the configuration files for
333.Ar name .
334First,
38.\"
39.Dd June 21, 2006
40.Dt RC.SUBR 8
41.Os
42.Sh NAME
43.Nm rc.subr
44.Nd functions used by system shell scripts
45.Sh SYNOPSIS

--- 281 unchanged lines hidden (view full) ---

327.Fl e .
328By default, the module is assumed to have the same name as
329.Ar file ,
330which is not always the case.
331.It Ic load_rc_config Ar name
332Source in the configuration files for
333.Ar name .
334First,
335.Pa /etc/defaults/rc.conf
336and
337.Pa /etc/rc.conf
335.Pa /etc/rc.conf
338are sourced if they have not yet been read in.
336is sourced if it has not yet been read in.
339Then,
337Then,
340.Va etcdir
341is set to
342.Pa /etc
343if
344.Va command Ap s
345prefix (or
346.Va ${name} Ns Va _program Ap s
347if it is defined) is
348.Pa /
349or
350.Pa /usr ,
351otherwise
352.Va etcdir
353is set to
354.Pa ${prefix} Ns Pa /etc .
355Once those variables are set accordingly,
356.Pa /etc/rc.conf.d/ Ns Va ${name}
357is sourced if the file exists (but it is deprecated if
358.Va etcdir
359is different than
360.Pa /etc )
361and then
362.Pa ${etcdir} Ns Pa /defaults/ Ns Va ${name}
363and
364.Va ${etcdir} Ns Pa /rc.conf.d/ Ns Va ${name}
365are sourced if these files exist.
366All these files may also contain other variable assignments to override
338.Pa /etc/rc.conf.d/ Ns Ar name
339is sourced if it is an existing file.
340The latter may also contain other variable assignments to override
367.Ic run_rc_command
368arguments defined by the calling script, to provide an easy
369mechanism for an administrator to override the behaviour of a given
370.Xr rc.d 8
371script without requiring the editing of that script.
372.It Ic load_rc_config_var Ar name Ar var
373Read the
374.Xr rc.conf 5

--- 531 unchanged lines hidden ---
341.Ic run_rc_command
342arguments defined by the calling script, to provide an easy
343mechanism for an administrator to override the behaviour of a given
344.Xr rc.d 8
345script without requiring the editing of that script.
346.It Ic load_rc_config_var Ar name Ar var
347Read the
348.Xr rc.conf 5

--- 531 unchanged lines hidden ---