Drop hurd specific dependency on libc0.3 (>= 2.3.2.ds1-12). It is
[sysvinit.git] / man / initscript.5
1 '\" -*- coding: UTF-8 -*-
2 .\" Copyright (C) 1998-2003 Miquel van Smoorenburg.
3 .\"
4 .\" This program is free software; you can redistribute it and/or modify
5 .\" it under the terms of the GNU General Public License as published by
6 .\" the Free Software Foundation; either version 2 of the License, or
7 .\" (at your option) any later version.
8 .\"
9 .\" This program is distributed in the hope that it will be useful,
10 .\" but WITHOUT ANY WARRANTY; without even the implied warranty of
11 .\" MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12 .\" GNU General Public License for more details.
13 .\"
14 .\" You should have received a copy of the GNU General Public License
15 .\" along with this program; if not, write to the Free Software
16 .\" Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
17 .\"
18 .TH INITSCRIPT 5 "July 10, 2003" "" "Linux System Administrator's Manual"
19 .SH NAME
20 initscript \- script that executes inittab commands.
21 .SH SYNOPSIS
22 /bin/sh /etc/initscript id runlevels action process
23 .SH DESCRIPTION
24 When the shell script \fI/etc/initscript\fP is present, \fBinit\fP
25 will use it to execute the commands from \fIinittab\fP.
26 This script can be used to set things like \fBulimit\fP and
27 \fBumask\fP default values for every process.
28 .SH EXAMPLES
29 This is a sample initscript, which might be installed on your
30 system as \fI/etc/initscript.sample\fP.
31 .RS
32 .sp
33 .nf
34 .ne 7
35
36 #
37 # initscript Executed by init(8) for every program it
38 # wants to spawn like this:
39 #
40 # /bin/sh /etc/initscript <id> <level> <action> <process>
41 #
42
43 # Set umask to safe level, and enable core dumps.
44 umask 022
45 ulimit -c 2097151
46 PATH=/bin:/sbin:/usr/bin:/usr/sbin
47 export PATH
48
49 # Increase the hard file descriptor limit for all processes
50 # to 8192. The soft limit is still 1024, but any unprivileged
51 # process can increase its soft limit up to the hard limit
52 # with "ulimit -Sn xxx" (needs a 2.2.13 or later Linux kernel).
53 ulimit -Hn 8192
54
55 # Execute the program.
56 eval exec "$4"
57
58 .sp
59 .RE
60 .SH NOTES
61 This script is not meant as startup script for daemons or somesuch.
62 It has nothing to do with a \fIrc.local\fP style script. It's just
63 a handler for things executed from \fB/etc/inittab\fP. Experimenting
64 with this can make your system un(re)bootable.
65 .RE
66 .SH FILES
67 /etc/inittab,
68 /etc/initscript.
69 .SH AUTHOR
70 Miquel van Smoorenburg ,<miquels@cistron.nl>
71 .SH "SEE ALSO"
72 init(8), inittab(5).