aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMatthew Dillon <dillon@FreeBSD.org>1998-12-12 23:04:21 +0000
committerMatthew Dillon <dillon@FreeBSD.org>1998-12-12 23:04:21 +0000
commitd27356d803641b3b14df31c86ac474225170a06d (patch)
treebf41da68f65e11f50346d5c623c730ff905891c7
parent73c84e252e545851a8a9086b9d019ebcbddc3da7 (diff)
Notes
-rw-r--r--etc/rc34
-rw-r--r--etc/rc.conf3
-rw-r--r--etc/rc.local29
3 files changed, 43 insertions, 23 deletions
diff --git a/etc/rc b/etc/rc
index af614ea7a6f0..38a937b1900c 100644
--- a/etc/rc
+++ b/etc/rc
@@ -1,5 +1,5 @@
#!/bin/sh
-# $Id: rc,v 1.161 1998/12/10 08:06:59 jb Exp $
+# $Id: rc,v 1.162 1998/12/11 08:25:12 jb Exp $
# From: @(#)rc 5.27 (Berkeley) 6/5/91
# System startup script run by init on autoboot
@@ -352,11 +352,39 @@ if [ "X${local_startup}" != X"NO" ]; then
echo .
fi
+if [ "X${update_motd}" != X"NO" ]; then
+ T=/tmp/_motd
+ rm -f $T
+ uname -v | sed -e 's,^\([^#]*\) #\(.* [1-2][0-9][0-9][0-9]\).*/\([^\]*\) $,\1 (\3) #\2,' > $T
+ awk '{if (NR == 1) {if ($1 == "FreeBSD") {next} else {print "\n"$0}} else {print}}' < /etc/motd >> $T
+ cp $T /etc/motd
+ chmod 644 /etc/motd
+ rm -f $T
+fi
+
# Run rc.devfs if present to customify devfs
[ -f /etc/rc.devfs ] && sh /etc/rc.devfs
-# Do traditional (but rather obsolete) rc.local file if it exists.
-[ -f /etc/rc.local ] && sh /etc/rc.local
+# Do traditional (but rather obsolete) rc.local file if it exists. If you
+# use this file and want to make it programmatic, source /etc/rc.conf in
+# /etc/rc.local and add your custom variables to /etc/rc.conf.local, as
+# shown below. Please do not put local extensions into /etc/rc itself.
+# Use /etc/rc.local
+#
+# ---- rc.local ----
+# if [ -f /etc/rc.conf ]; then
+# . /etc/rc.conf
+# fi
+#
+# ... additional startup conditionals ...
+# ---- rc.local ----
+#
+
+if [ -f /etc/rc.local ]; then
+ echo -n 'starting local daemons:'
+ sh /etc/rc.local
+ echo '.'
+fi
# Raise kernel security level. This should be done only after `fsck' has
# repaired local file systems if you want the securelevel to be greater than 1.
diff --git a/etc/rc.conf b/etc/rc.conf
index cd0a4cb303a0..0bf9f1fb2543 100644
--- a/etc/rc.conf
+++ b/etc/rc.conf
@@ -6,7 +6,7 @@
#
# All arguments must be in double or single quotes.
#
-# $Id: rc.conf,v 1.63 1998/11/25 21:16:43 msmith Exp $
+# $Id: rc.conf,v 1.64 1998/12/01 21:36:32 dillon Exp $
##############################################################
### Important initial Boot-time options #####################
@@ -170,6 +170,7 @@ ldconfig_paths="/usr/lib/compat /usr/X11R6/lib /usr/local/lib" # shared library
ldconfig_paths_aout="/usr/lib/compat/aout /usr/X11R6/lib/aout /usr/local/lib/aout" # a.out shared library search paths
kern_securelevel_enable="NO" # kernel security level (see init(8)),
kern_securelevel="-1" # range: -1..2 ; `-1' is the most insecure
+update_motd="YES" # update version info in /etc/motd (or NO)
##############################################################
### Allow local configuration override at the very end here ##
diff --git a/etc/rc.local b/etc/rc.local
index 5e6584402803..9a5706111125 100644
--- a/etc/rc.local
+++ b/etc/rc.local
@@ -1,24 +1,15 @@
#
# site-specific startup actions, daemons
#
-# $Id: rc.local,v 1.24 1997/06/25 12:17:17 ache Exp $
+# $Id: rc.local,v 1.25 1997/06/25 15:15:13 ache Exp $
#
+# put your local stuff here or in /usr/local/etc/rc.d. If you put stuff
+# here and want to make it programmer, bring in /etc/rc.conf and add
+# your custom variables to /etc/rc.conf.local
+#
+# if [ -f /etc/rc.conf ]; then
+# . /etc/rc.conf
+# fi
+#
+# ... additional startup conditionals ...
-# If there is a global system configuration file, suck it in.
-#if [ -f /etc/rc.conf ]; then
-# . /etc/rc.conf
-#fi
-
-T=/tmp/_motd
-rm -f $T
-uname -v | sed -e 's,^\([^#]*\) #\(.* [1-2][0-9][0-9][0-9]\).*/\([^\]*\) $,\1 (\3) #\2,' > $T
-awk '{if (NR == 1) {if ($1 == "FreeBSD") {next} else {print "\n"$0}} else {print}}' < /etc/motd >> $T
-cp $T /etc/motd
-chmod 644 /etc/motd
-rm -f $T
-
-echo -n 'starting local daemons:'
-
-# put your local stuff here
-
-echo '.'