1 |
#!/bin/bash |
#!/bin/bash |
2 |
|
# $Header: /home/cvsd/magellan-cvs/magellan-src/magellan-initscripts/etc/rc.d/init.d/mountfslivecd,v 1.3 2005-03-15 19:07:56 niro Exp $ |
3 |
|
|
4 |
#%rlevels: 7:s 0:k 6:k |
#%rlevels: 7:s 0:k 6:k |
5 |
#%start: 40 |
#%start: 40 |
25 |
start) |
start) |
26 |
echo -e ${COLOREDSTAR}"Recording existing mounts in /etc/mtab ..." |
echo -e ${COLOREDSTAR}"Recording existing mounts in /etc/mtab ..." |
27 |
> /etc/mtab |
> /etc/mtab |
28 |
|
|
29 |
#fake mount rootfs (taken from /.bootdev) |
#fake mount rootfs (taken from /.bootdev) |
30 |
if [ -e /.bootdev ] |
if [ -e /.bootdev ] |
31 |
then |
then |
35 |
#wanna check if usbstorage or not |
#wanna check if usbstorage or not |
36 |
#rm /.bootdev |
#rm /.bootdev |
37 |
fi |
fi |
38 |
|
|
39 |
#fake mount cloop, loop or sqsh |
#fake mount cloop, loop or sqsh |
40 |
if [ -f /mnt/cdrom/livecdrootfs.loop ] |
if [ -f /mnt/cdrom/livecdrootfs.loop ] |
41 |
then |
then |
48 |
elif [ -f /mnt/cdrom/livecdrootfs.sqsh ] |
elif [ -f /mnt/cdrom/livecdrootfs.sqsh ] |
49 |
then |
then |
50 |
mount -f /mnt/cdrom/livecdrootfs.sqsh /mnt/cloop -t ext2 -o ro |
mount -f /mnt/cdrom/livecdrootfs.sqsh /mnt/cloop -t ext2 -o ro |
51 |
fi |
fi |
52 |
|
|
53 |
#records devfs if mounted |
#records devfs if mounted |
54 |
if [ "$(get_mounted devfs)" == devfs ] |
if [ "$(get_mounted devfs)" == devfs ] |
73 |
then |
then |
74 |
mount -f -t ramfs none /dev |
mount -f -t ramfs none /dev |
75 |
fi |
fi |
76 |
|
|
77 |
#fake mount tmpfs |
#fake mount tmpfs |
78 |
mount -f tmpfs / -t tmpfs -o rw |
mount -f tmpfs / -t tmpfs -o rw |
79 |
|
|