3 TIMESYNCARGS=(-rLa1000000)
6 mntgen -s slashn && chmod 666 /srv/slashn
8 # bind all likely devices (#S was bound in boot)
9 for(i in f t m v L P u U '$' Σ κ)
10 /bin/bind -a '#'^$i /dev >/dev/null >[2=1]
12 # set up any partitions
15 # start up local swapping
16 disk=`{ls /dev/sd*/swap >[2]/dev/null}
18 swap $disk(1) >/dev/null >[2=1]
21 # we do this before we have a name. we may need to do network
22 # setup so that we can get a name.
23 if(test -e /rc/bin/termrc.local)
24 . /rc/bin/termrc.local
26 # cs sets sysname (termrc.local may already have started it so check)
27 if(! test -e /srv/cs && ! test -e /net/cs)
29 sysname=`{cat /dev/sysname}
30 if (~ $#sysname 0 || ~ $sysname '') {
31 sysname = gnot # default
32 echo -n $sysname >/dev/sysname
35 # machine specific startup (e.g., for devices not probed)
36 if(test -e /cfg/$sysname/termrc)
37 . /cfg/$sysname/termrc
39 # start IP on the LAN, if not already configured. diskless terminals
40 # are already configured by now. It's commented out to avoid a long timeout
41 # on startup waiting for DHCP.
43 # If your site provides DHCP service,
45 #if(! test -e /net/ipifc/0/ctl)
48 # Otherwise, see /cfg/$sysname/termrc (/cfg/example/termrc is an example).
50 # start dns if we have an internet
51 if(test -e /net/ipifc/0/ctl && ! test -e /srv/dns)
54 if(! ~ $terminal *vx32*){
55 # start timesync if it isn't running and we weren't told not to
56 if(! ps|grep -s timesync)
57 if(! ~ $TIMESYNCARGS '')
58 aux/timesync $TIMESYNCARGS
60 # add the loop-back medium
61 if(! grep -s 127.0.0.1 /net/ipselftab)
62 ip/ipconfig loopback /dev/null 127.1
64 # set things up for vmware
65 if(! ~ `{cat /dev/user} none)
66 if(test -e /bin/aux/vmware)
70 # query user if terminal isn't adequately configured yet
72 echo -n 'mouseport is (ps2, ps2intellimouse, 0, 1, 2)[ps2]: '
78 echo -n 'vgasize [640x480x8]: '
84 echo -n 'monitor is [xga]: '
89 if(test -f /dev/mousectl){
91 case ps2 ps2intellimouse 0 1 2
93 # parse vgasize into fields
94 vgasize=`{echo $vgasize}
103 pipefile -dr /bin/aux/accupoint /dev/mouse
108 if (test -f /dev/apm)
111 dontkill '^(ipconfig|factotum|mntgen|fossil|cs|dns|listen|reboot)$'