]> pilppa.org Git - familiar-h63xx-build.git/blob - org.handhelds.familiar/packages/initscripts/initscripts-1.0/bootmisc.sh
OE tree imported from monotone branch org.openembedded.oz354fam083 at revision 8b12e3...
[familiar-h63xx-build.git] / org.handhelds.familiar / packages / initscripts / initscripts-1.0 / bootmisc.sh
1 #
2 # bootmisc.sh   Miscellaneous things to be done during bootup.
3 #
4
5 . /etc/default/rcS
6 #
7 # Put a nologin file in /etc to prevent people from logging in before
8 # system startup is complete.
9 #
10 if test "$DELAYLOGIN" = yes
11 then
12   echo "System bootup in progress - please wait" > /etc/nologin
13   cp /etc/nologin /etc/nologin.boot
14 fi
15
16 #
17 # Set pseudo-terminal access permissions.
18 #
19 if ( ! grep -q devfs /proc/mounts ) && test -c /dev/ttyp0
20 then
21         chmod 666 /dev/tty[p-za-e][0-9a-f]
22         chown root:tty /dev/tty[p-za-e][0-9a-f]
23 fi
24
25 #
26 # Apply /proc settings if defined
27 #
28 SYSCTL_CONF="/etc/sysctl.conf"
29 if [ -f "${SYSCTL_CONF}" ]
30 then
31         if [ -x "/sbin/sysctl" ]
32         then
33                 /sbin/sysctl -p "${SYSCTL_CONF}"
34         else
35                 echo "To have ${SYSCTL_CONF} applied during boot, install package <procps>."
36         fi
37 fi
38
39 #
40 # Update /etc/motd.
41 #
42 if test "$EDITMOTD" != no
43 then
44         uname -a > /etc/motd.tmp
45         sed 1d /etc/motd >> /etc/motd.tmp
46         mv /etc/motd.tmp /etc/motd
47 fi
48
49 #
50 # This is as good a place as any for a sanity check
51 # /tmp should be a symlink to /var/tmp to cut down on the number
52 # of mounted ramdisks.
53 if test ! -L /tmp && test -d /var/tmp
54 then
55         rm -rf /tmp
56         ln -sf /var/tmp /tmp
57 fi
58
59 #
60 # Update dynamic library cache
61 #
62 /sbin/ldconfig
63
64
65 # Recover the time, if there is a time file                 
66 #
67 if test -e /etc/timestamp
68 then
69         date -s `cat /etc/timestamp`
70 fi
71 : exit 0