blob: bf5fa11cb465ef4a90eb17e51f02fcb52c9f682d [file] [log] [blame]
# rc.local file for The Linux BOGUS Release, version 1.0.1
echo -n "Local initialization: "
# Set the host name. You will probably want to change this.
echo -n "hostname "
hostname winter
# Update the system time from the CMOS clock.
# This assume that the CMOS clock is in local time, and that you have the
# correct links in /usr/src/zoneinfo (see zic(8) for details. (For example,
# for the east coast of the US, do: zic -l US/Eastern -p America/NewYork)
# Note: mount /usr BEFORE running rc.local!
echo -n "clock "
clock -a
# Set screen blanker to 5 minutes.
echo -n "screen-blanking "
setterm -blank 5
# Set modem for 57600 bps
if [ -e /dev/modem ]
then
echo -n "high-speed-modem "
setserial /dev/modem spd_hi
fi
# Make CTRL-ALT-DEL do a controlled reboot (i.e., call reboot(8))
echo -n "reboot "
ctrlaltdel soft
# Preserve elvis files in case of a crash
echo -n "vi-files "
elvprsv "-the system went down" /tmp/elv_*.*
echo
echo -n "Starting daemons: "
# Make sure log files exist
if [ -d /var/adm ]; then
if [ ! -e /var/adm/kernlog ]; then touch /var/adm/kernlog; fi
if [ ! -e /var/adm/syslog ]; then touch /var/adm/syslog; fi
if [ ! -e /var/adm/maillog ]; then touch /var/adm/maillog; fi
if [ ! -e /var/adm/authlog ]; then touch /var/adm/authlog; fi
if [ ! -e /var/adm/news ]; then touch /var/adm/news; fi
if [ ! -e /var/adm/daemon ]; then touch /var/adm/daemon; fi
if [ ! -e /var/adm/lpd-errs ]; then touch /var/adm/lpd-errs; fi
if [ ! -e /var/adm/sysdebug ]; then touch /var/adm/sysdebug; fi
# start up syslogd if it exists, but wait until AFTER HOSTNAME SET
if [ -f /usr/sbin/syslogd ]; then
echo -n "syslogd "
/usr/sbin/syslogd
fi
fi
# Start up cron if it exists
if [ -f /usr/sbin/cron ]
then
echo -n "cron "
/usr/sbin/cron
fi
echo
# If you want networking turned on, then uncomment the following lines.
if [ -f /etc/NETWORKING_IS_ON ]
then
if [ -f /etc/rc.net ]
then
/bin/sh /etc/rc.net
fi
fi
echo "Mounting foreign file systems"
mount -avt nfs,msdos,hpfs
# Create a new issue file
echo > /etc/issue
echo "Welcome to `hostname`, an `uname -m` running BOGUS Release 1.0.1 `uname` `uname -r`" >> /etc/issue
echo >> /etc/issue