|
DataMuseum.dkPresents historical artifacts from the history of: Regnecentalen RC-900 |
This is an automatic "excavation" of a thematic subset of
See our Wiki for more about Regnecentalen RC-900 Excavated with: AutoArchaeologist - Free & Open Source Software. |
top - metrics - download
Length: 2223 (0x8af) Types: TextFile Notes: UNIX file Names: »inskern«
└─⟦69f23ffa1⟧ Bits:30004042/kconfig2.imd SW95705I 386/ix Multi-user Release 1.2 └─⟦69f23ffa1⟧ UNIX Filesystem └─⟦this⟧ »kc/new/etc/inskern«
# # Copyrighted as an unpublished work. # (c) Copyright 1987 INTERACTIVE Systems Corporation # All rights reserved. # # RESTRICTED RIGHTS # # These programs are supplied under a license. They may be used, # disclosed, and/or copied only as permitted under such license # agreement. Any copy must contain the above copyright notice and # this restricted rights notice. Use, copying, and/or disclosure # of the programs is strictly prohibited unless otherwise provided # in the license agreement. # #ident "@(#)inskern.sh 1.5 - 88/07/18" # copy a kernel to the root directory and set up rc0 script # to link new kernel grace=0; CONF=${CONF:-$ROOT/etc/atconf} while [ "$1" != "" ] do case $1 in -g[0-9]* ) grace=`expr "$1" : '-g\(.*\)'`;shift;; -c) shift; CONF=$1; shift;; *) if [ ! -f "$CONF/kernels/$1" -o "$kern" != "" ] then echo "USAGE: inskern [-c confdir] [-g<shutdown-grace-period>] kernelname" exit 1 fi kern=$1;shift;; esac done echo This procedure will execute a shutdown to reboot the new kernel $kern. if [ -x /usr/bin/id ] then eval `id | sed 's/[^a-z0-9=].*//'` else uid=0 fi if [ "$uid" -ne 0 -o `pwd` != / ] then echo You must be user root in directory / to run shutdown. exit 1 fi resp= while [ -z "$resp" ] do echo Enter y to continue, n to terminate:" \c" read resp case "$resp" in y|Y) ;; n|N) exit 1;; *) resp=;; esac done # verify room to copy current kernel newsize=`ls -s $CONF/kernels/$kern` set $newsize newsize=$1 set `df /` freesize=$4 if [ "$freesize" -le "$newsize" ] then echo "\n"Not enough disk free space to copy kernel to / echo Free some disk space in the root file system and try again. exit 1 fi # if same name kernel exists in /, remove it if [ -r /$kern ] then resp= while [ -z "$resp" ] do echo /$kern exists. Ok to remove /$kern" (y or n):\c" read resp case "$resp" in y|Y) if rm /$kern then resp=1 fi;; n|N) echo $kern not installed;exit 1;; *) resp=;; esac done fi if cp $CONF/kernels/$kern / then echo $kern >/etc/atconf/kernels/.newkernel /etc/shutdown -g$grace -i0 else echo $kern copy failed. Unable to install $kern exit 1 fi