]> git.sur5r.net Git - bacula/rescue/blob - rescue/linux/cdrom/roottree/etc/sysinit
da71ecaf35dff95aff445524cd9fc30d830a95d3
[bacula/rescue] / rescue / linux / cdrom / roottree / etc / sysinit
1 #!/bin/sh
2
3 echo "Start sysinit ..."
4
5 PATH="/sbin:/usr/sbin:/bin:/usr/bin:/usr/X11R6/bin"
6 export PATH
7
8 echo "Remounting root filesystem read-write"
9 mount -o remount,rw /dev/root /
10
11 mount -t proc none /proc
12 mount -t devpts none /dev/pts
13 [ -d /proc/bus/usb ] && mount -n -t usbfs /proc/bus/usb /proc/bus/usb
14 mount -n -t sysfs /sys /sys >/dev/null 2>&1
15
16 [ -x /sbin/start_udev ] && /sbin/start_udev
17
18 # Clear mtab
19 (> /etc/mtab) &> /dev/null
20
21 # Enter root, /proc and (potentially) /proc/bus/usb and devfs into mtab.
22 mount -f /
23 mount -f /proc
24 mount -f /sys >/dev/null 2>&1
25 mount -f /dev/pts
26 [ -f /proc/bus/usb/devices ] && mount -f -t usbfs usbfs /proc/bus/usb
27 [ -e /dev/.devfsd ] && mount -f -t devfs devfs /dev
28
29
30 touch  /var/run/utmp /var/run/wtmp /var/log/wtmp
31 chgrp utmp /var/run/utmp /var/log/wtmp
32 chmod 0664 /var/run/utmp /var/log/wtmp
33
34 syslogd -m 0
35 klogd -x 
36
37 echo "Attempting to mount CDDOM..."
38 /etc/mount_cdrom
39
40 echo "Loading the ethernet driver module"
41 /etc/load_eth0
42
43 ifconfig lo 127.0.0.1 netmask 255.0.0.0 up
44
45 /bin/hostname RescueCD
46
47 echo "Boot complete."
48 sleep 3 # give time to read messages