aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorBill Nottingham <notting@redhat.com>2000-06-15 18:56:54 +0000
committerBill Nottingham <notting@redhat.com>2000-06-15 18:56:54 +0000
commit60a0dcc9b21edc6777a4392daba44eaa06b1fc9f (patch)
treeafd1f617869f8eee36356c51653975da8db7f82a
parent855e91894a00e7f237427af5e0d2d96d0833d777 (diff)
downloadinitscripts-60a0dcc9b21edc6777a4392daba44eaa06b1fc9f.tar
initscripts-60a0dcc9b21edc6777a4392daba44eaa06b1fc9f.tar.gz
initscripts-60a0dcc9b21edc6777a4392daba44eaa06b1fc9f.tar.bz2
initscripts-60a0dcc9b21edc6777a4392daba44eaa06b1fc9f.tar.xz
initscripts-60a0dcc9b21edc6777a4392daba44eaa06b1fc9f.zip
/etc/rc.d/init.d -> /etc/init.d. Wheeeeee.
-rw-r--r--Makefile2
-rw-r--r--initscripts.spec42
-rw-r--r--inittab18
-rwxr-xr-xrc.d/init.d/halt2
-rwxr-xr-xrc.d/init.d/killall6
-rwxr-xr-xrc.d/init.d/netfs2
-rwxr-xr-xrc.d/init.d/network4
-rwxr-xr-xrc.d/init.d/random2
-rwxr-xr-xrc.d/init.d/single6
-rwxr-xr-xrc.d/rc14
-rwxr-xr-xrc.d/rc.sysinit14
-rwxr-xr-xservice2
-rw-r--r--src/Makefile2
-rwxr-xr-xsrc/testdinit2
-rw-r--r--sys-unconfig.82
-rw-r--r--sysvinitfiles10
16 files changed, 69 insertions, 61 deletions
diff --git a/Makefile b/Makefile
index ff43e76a..43f18653 100644
--- a/Makefile
+++ b/Makefile
@@ -28,7 +28,7 @@ install:
mkdir -p $(ROOT)/etc/sysconfig
mkdir -p $(ROOT)/etc/sysconfig/console
install -m644 sysconfig/init $(ROOT)/etc/sysconfig/init
- cp -af rc.d sysconfig ppp $(ROOT)/etc
+ cp -af rc.d/* sysconfig ppp $(ROOT)/etc
mkdir -p $(ROOT)/sbin
mv $(ROOT)/etc/sysconfig/network-scripts/ifup $(ROOT)/sbin
mv $(ROOT)/etc/sysconfig/network-scripts/ifdown $(ROOT)/sbin
diff --git a/initscripts.spec b/initscripts.spec
index 4b0a9c07..c277a465 100644
--- a/initscripts.spec
+++ b/initscripts.spec
@@ -40,24 +40,24 @@ mkdir -p $RPM_BUILD_ROOT/var/run/netreport
chmod u=rwx,g=rwx,o=rx $RPM_BUILD_ROOT/var/run/netreport
for i in 0 1 2 3 4 5 6 ; do
- file=$RPM_BUILD_ROOT/etc/rc.d/rc$i.d
+ file=$RPM_BUILD_ROOT/etc/rc$i.d
mkdir $file
# chown root.root $file
chmod u=rwx,g=rx,o=rx $file
done
# Can't store symlinks in a CVS archive
-ln -s ../init.d/killall $RPM_BUILD_ROOT/etc/rc.d/rc0.d/S00killall
-ln -s ../init.d/killall $RPM_BUILD_ROOT/etc/rc.d/rc6.d/S00killall
+ln -s ../init.d/killall $RPM_BUILD_ROOT/etc/rc0.d/S00killall
+ln -s ../init.d/killall $RPM_BUILD_ROOT/etc/rc6.d/S00killall
-ln -s ../init.d/halt $RPM_BUILD_ROOT/etc/rc.d/rc0.d/S01halt
-ln -s ../init.d/halt $RPM_BUILD_ROOT/etc/rc.d/rc6.d/S01reboot
+ln -s ../init.d/halt $RPM_BUILD_ROOT/etc/rc0.d/S01halt
+ln -s ../init.d/halt $RPM_BUILD_ROOT/etc/rc6.d/S01reboot
-ln -s ../init.d/single $RPM_BUILD_ROOT/etc/rc.d/rc1.d/S00single
+ln -s ../init.d/single $RPM_BUILD_ROOT/etc/rc1.d/S00single
-ln -s ../rc.local $RPM_BUILD_ROOT/etc/rc.d/rc2.d/S99local
-ln -s ../rc.local $RPM_BUILD_ROOT/etc/rc.d/rc3.d/S99local
-ln -s ../rc.local $RPM_BUILD_ROOT/etc/rc.d/rc5.d/S99local
+ln -s ../rc.local $RPM_BUILD_ROOT/etc/rc2.d/S99local
+ln -s ../rc.local $RPM_BUILD_ROOT/etc/rc3.d/S99local
+ln -s ../rc.local $RPM_BUILD_ROOT/etc/rc5.d/S99local
mkdir -p $RPM_BUILD_ROOT/var/{log,run}
touch $RPM_BUILD_ROOT/var/run/utmp
@@ -66,6 +66,14 @@ touch $RPM_BUILD_ROOT/var/log/wtmp
%pre
/usr/sbin/groupadd -g 22 -r -f utmp
+if [ -d /etc/rc.d -a -d /etc/init.d ]; then
+ echo "can't move /etc/rc.d/init.d -> /etc/init.d - bailing"
+ exit 1
+fi
+if [ -d /etc/rc.d ]; then
+ mv /etc/rc.d/* /etc
+ ln -snf /etc /etc/rc.d
+fi
%post
touch /var/log/wtmp
@@ -182,14 +190,14 @@ rm -rf $RPM_BUILD_ROOT
%config /etc/sysconfig/network-scripts/ifup-ipx
%config /etc/X11/prefdm
%config /etc/inittab
-%dir /etc/rc.d
-%config /etc/rc.d/rc.sysinit
-%dir /etc/rc.d/rc*.d
-%config(missingok) /etc/rc.d/rc*.d/*
-%dir /etc/rc.d/init.d
-%config(missingok) /etc/rc.d/init.d/*
-%config /etc/rc.d/rc
-%config(noreplace) /etc/rc.d/rc.local
+/etc/rc.d
+%config /etc/rc.sysinit
+%dir /etc/rc*.d
+%config(missingok) /etc/rc*.d/*
+%dir /etc/init.d
+%config(missingok) /etc/init.d/*
+%config /etc/rc
+%config(noreplace) /etc/rc.local
%config(noreplace) /etc/sysctl.conf
%config /etc/profile.d/lang.sh
%config /etc/profile.d/lang.csh
diff --git a/inittab b/inittab
index 4a9f63ba..09fc0acd 100644
--- a/inittab
+++ b/inittab
@@ -18,15 +18,15 @@
id:3:initdefault:
# System initialization.
-si::sysinit:/etc/rc.d/rc.sysinit
-
-l0:0:wait:/etc/rc.d/rc 0
-l1:1:wait:/etc/rc.d/rc 1
-l2:2:wait:/etc/rc.d/rc 2
-l3:3:wait:/etc/rc.d/rc 3
-l4:4:wait:/etc/rc.d/rc 4
-l5:5:wait:/etc/rc.d/rc 5
-l6:6:wait:/etc/rc.d/rc 6
+si::sysinit:/etc/rc.sysinit
+
+l0:0:wait:/etc/rc 0
+l1:1:wait:/etc/rc 1
+l2:2:wait:/etc/rc 2
+l3:3:wait:/etc/rc 3
+l4:4:wait:/etc/rc 4
+l5:5:wait:/etc/rc 5
+l6:6:wait:/etc/rc 6
# Things to run in every runlevel.
ud::once:/sbin/update
diff --git a/rc.d/init.d/halt b/rc.d/init.d/halt
index 738a6532..22f008c9 100755
--- a/rc.d/init.d/halt
+++ b/rc.d/init.d/halt
@@ -11,7 +11,7 @@
# Set the path.
PATH=/sbin:/bin:/usr/bin:/usr/sbin
-. /etc/rc.d/init.d/functions
+. /etc/init.d/functions
runcmd() {
echo -n "$1 "
diff --git a/rc.d/init.d/killall b/rc.d/init.d/killall
index 9d244119..0aff07ac 100755
--- a/rc.d/init.d/killall
+++ b/rc.d/init.d/killall
@@ -11,10 +11,10 @@ for i in /var/lock/subsys/*; do
subsys=${i#/var/lock/subsys/}
# Bring the subsystem down.
- if [ -f /etc/rc.d/init.d/$subsys.init ]; then
- /etc/rc.d/init.d/$subsys.init stop
+ if [ -f /etc/init.d/$subsys.init ]; then
+ /etc/init.d/$subsys.init stop
else
- /etc/rc.d/init.d/$subsys stop
+ /etc/init.d/$subsys stop
fi
done
diff --git a/rc.d/init.d/netfs b/rc.d/init.d/netfs
index 57cb462e..39e6ef76 100755
--- a/rc.d/init.d/netfs
+++ b/rc.d/init.d/netfs
@@ -15,7 +15,7 @@ if [ ! -f /etc/sysconfig/network ]; then
fi
# Source function library.
-. /etc/rc.d/init.d/functions
+. /etc/init.d/functions
. /etc/sysconfig/network
diff --git a/rc.d/init.d/network b/rc.d/init.d/network
index 30025a04..6c79c36b 100755
--- a/rc.d/init.d/network
+++ b/rc.d/init.d/network
@@ -8,7 +8,7 @@
# probe: true
# Source function library.
-. /etc/rc.d/init.d/functions
+. /etc/init.d/functions
if [ ! -f /etc/sysconfig/network ]; then
exit 0
@@ -88,7 +88,7 @@ case "$1" in
SMBMTAB=`grep -v '^#' /proc/mounts | awk '{ if ($3 ~ /^smbfs$/ ) print $2}'`
NCPMTAB=`grep -v '^#' /proc/mounts | awk '{ if ($3 ~ /^ncpfs$/ ) print $2}'`
if [ -n "$NFSMTAB" -o -n "$SMBMTAB" -o -n "$NCPMTAB" ] ; then
- /etc/rc.d/init.d/netfs stop
+ /etc/init.d/netfs stop
fi
fi
diff --git a/rc.d/init.d/random b/rc.d/init.d/random
index 87a91a8c..42dce627 100755
--- a/rc.d/init.d/random
+++ b/rc.d/init.d/random
@@ -9,7 +9,7 @@
# random number generation.
# Source function library.
-. /etc/rc.d/init.d/functions
+. /etc/init.d/functions
random_seed=/var/run/random-seed
diff --git a/rc.d/init.d/single b/rc.d/init.d/single
index e3ae2f74..6806d0c3 100755
--- a/rc.d/init.d/single
+++ b/rc.d/init.d/single
@@ -10,7 +10,7 @@
# Modified for RHS Linux by Damien Neil
#
-. /etc/rc.d/init.d/functions
+. /etc/init.d/functions
# Set the path.
PATH=/sbin:/bin:/usr/sbin:/usr/bin
@@ -39,7 +39,7 @@ if [ -f /proc/sys/kernel/modprobe ]; then
fi
# If they want to run something in single user mode, might as well run it...
-for i in /etc/rc.d/rc1.d/S[0-9][0-9]*; do
+for i in /etc/rc1.d/S[0-9][0-9]*; do
# Check if the script is there.
[ ! -f $i ] && continue
@@ -47,7 +47,7 @@ for i in /etc/rc.d/rc1.d/S[0-9][0-9]*; do
[ "${i%.rpmsave}" != "${i}" ] && continue
[ "${i%.rpmorig}" != "${i}" ] && continue
[ "${i%.rpmnew}" != "${i}" ] && continue
- [ "$i" = "/etc/rc.d/rc1.d/S00single" ] && continue
+ [ "$i" = "/etc/rc1.d/S00single" ] && continue
$i start
done
diff --git a/rc.d/rc b/rc.d/rc
index 13892672..58fef4bf 100755
--- a/rc.d/rc
+++ b/rc.d/rc
@@ -10,7 +10,7 @@
#
# Source function library.
-. /etc/rc.d/init.d/functions
+. /etc/init.d/functions
# Now find out what the current and what the previous runlevel are.
argv1="$1"
@@ -35,12 +35,12 @@ fi
[ "$1" != "" ] && runlevel="$argv1"
# Tell linuxconf what runlevel we are in
-[ -d /var/run ] && echo "/etc/rc.d/rc$runlevel.d" > /var/run/runlevel.dir
+[ -d /var/run ] && echo "/etc/rc$runlevel.d" > /var/run/runlevel.dir
# Is there an rc directory for this new runlevel?
-if [ -d /etc/rc.d/rc$runlevel.d ]; then
+if [ -d /etc/rc$runlevel.d ]; then
# First, run the KILL scripts.
- for i in /etc/rc.d/rc$runlevel.d/K*; do
+ for i in /etc/rc$runlevel.d/K*; do
# Check if the script is there.
[ ! -f $i ] && continue
@@ -50,7 +50,7 @@ if [ -d /etc/rc.d/rc$runlevel.d ]; then
[ "${i%.rpmnew}" != "${i}" ] && continue
# Check if the subsystem is already up.
- subsys=${i#/etc/rc.d/rc$runlevel.d/K??}
+ subsys=${i#/etc/rc$runlevel.d/K??}
[ ! -f /var/lock/subsys/$subsys ] && \
[ ! -f /var/lock/subsys/${subsys}.init ] && continue
@@ -63,7 +63,7 @@ if [ -d /etc/rc.d/rc$runlevel.d ]; then
done
# Now run the START scripts.
- for i in /etc/rc.d/rc$runlevel.d/S*; do
+ for i in /etc/rc$runlevel.d/S*; do
# Check if the script is there.
[ ! -f $i ] && continue
@@ -73,7 +73,7 @@ if [ -d /etc/rc.d/rc$runlevel.d ]; then
[ "${i%.rpmnew}" != "${i}" ] && continue
# Check if the subsystem is already up.
- subsys=${i#/etc/rc.d/rc$runlevel.d/S??}
+ subsys=${i#/etc/rc$runlevel.d/S??}
[ -f /var/lock/subsys/$subsys ] || \
[ -f /var/lock/subsys/${subsys}.init ] && continue
diff --git a/rc.d/rc.sysinit b/rc.d/rc.sysinit
index 01fe52b3..8c72cfc2 100755
--- a/rc.d/rc.sysinit
+++ b/rc.d/rc.sysinit
@@ -1,13 +1,13 @@
#!/bin/sh
#
-# /etc/rc.d/rc.sysinit - run once at boot time
+# /etc/rc.sysinit - run once at boot time
#
# Taken in part from Miquel van Smoorenburg's bcheckrc.
#
# Rerun ourselves through initlog
if [ -z "$IN_INITLOG" ]; then
- [ -f /sbin/initlog ] && exec /sbin/initlog $INITLOG_ARGS -r /etc/rc.d/rc.sysinit
+ [ -f /sbin/initlog ] && exec /sbin/initlog $INITLOG_ARGS -r /etc/rc.sysinit
fi
# If we're using devfs, start devfsd now - we need the old device names
@@ -30,7 +30,7 @@ else
fi
# Source functions
-. /etc/rc.d/init.d/functions
+. /etc/init.d/functions
# Print a banner. ;)
echo -en "\t\t\tWelcome to "
@@ -304,8 +304,8 @@ if [ -f /proc/sys/kernel/modprobe ]; then
fi
# Load modules (for backward compatibility with VARs)
-if [ -f /etc/rc.d/rc.modules ]; then
- /etc/rc.d/rc.modules
+if [ -f /etc/rc.modules ]; then
+ /etc/rc.modules
fi
# Add raid devices
@@ -492,8 +492,8 @@ swapon -a >/dev/null 2>&1
action "Enabling swap space" /bin/true
# Initialize the serial ports.
-if [ -f /etc/rc.d/rc.serial ]; then
- . /etc/rc.d/rc.serial
+if [ -f /etc/rc.serial ]; then
+ . /etc/rc.serial
fi
# If a SCSI tape has been detected, load the st module unconditionally
diff --git a/service b/service
index 0a6d297b..67fb3592 100755
--- a/service
+++ b/service
@@ -4,7 +4,7 @@ VERSION="`basename $0` ver. 0.91"
USAGE="Usage: `basename $0` < option > | --status-all | \
[ service_name [ command | --full-restart ] ]"
SERVICE=
-SERVICEDIR="/etc/rc.d/init.d"
+SERVICEDIR="/etc/init.d"
if [ $# -eq 0 ]; then
echo "${USAGE}" >&2
diff --git a/src/Makefile b/src/Makefile
index 654483e0..32d87b9b 100644
--- a/src/Makefile
+++ b/src/Makefile
@@ -39,7 +39,7 @@ install:
# not installed by default, only comes from sources.
install-test:
install -s -m 755 testd $(ROOT)/usr/sbin/testd
- install -m 755 testdinit $(ROOT)/etc/rc.d/init.d/testd
+ install -m 755 testdinit $(ROOT)/etc/init.d/testd
ipcalc: ipcalc.o
$(CC) $(LDFLAGS) -o $@ $< /usr/lib/libpopt.a
diff --git a/src/testdinit b/src/testdinit
index f2f4a85b..67ea8c37 100755
--- a/src/testdinit
+++ b/src/testdinit
@@ -5,7 +5,7 @@
#
# Source function library.
-. /etc/rc.d/init.d/functions
+. /etc/init.d/functions
# See how we were called.
case "$1" in
diff --git a/sys-unconfig.8 b/sys-unconfig.8
index 53f86688..1db1c85e 100644
--- a/sys-unconfig.8
+++ b/sys-unconfig.8
@@ -14,7 +14,7 @@ authconfig, and ntsysv.
.PD 0
.TP 20
\fI/.unconfigured\fR
-The presence of this file will cause /etc/rc.d/rc.sysinit to run
+The presence of this file will cause /etc/rc.sysinit to run
the programs mentioned above.
.PD
diff --git a/sysvinitfiles b/sysvinitfiles
index 9e9ddeb7..3a39ed43 100644
--- a/sysvinitfiles
+++ b/sysvinitfiles
@@ -1,7 +1,7 @@
Writing System V init scripts for Red Hat Linux
===============================================
-All System V init scripts are named /etc/rc.d/init.d/<servicename>
+All System V init scripts are named /etc/init.d/<servicename>
where <servicename> is the name of the service. There must be no
".init" suffix.
@@ -11,7 +11,7 @@ Sample Script
#!/bin/bash
#
-# /etc/rc.d/init.d/<servicename>
+# /etc/init.d/<servicename>
#
# <description of the *service*>
# <any general comments about this init script>
@@ -23,7 +23,7 @@ Sample Script
# mistaken for tags, should they happen to fit the pattern.>
# Source function library.
-. /etc/rc.d/init.d/functions
+. /etc/init.d/functions
<define any local shell functions used by the code that follows>
@@ -72,7 +72,7 @@ which you intend to be used interactively to the usage message.
-Functions in /etc/rc.d/init.d/functions
+Functions in /etc/init.d/functions
=======================================
daemon [+/-nicelevel] program [arguments] [&]
@@ -165,7 +165,7 @@ Tags
acheived by running these commands:
command=$(/etc/rd.d/init.d/SCRIPT probe)
- [ -n "$command" ] && /etc/rc.d/init.d/SCRIPT $command
+ [ -n "$command" ] && /etc/init.d/SCRIPT $command
where SCRIPT is the name of the service's sysv init script.