summaryrefslogtreecommitdiff
path: root/i/pc104/initrd/conf/update_initrd.sh
diff options
context:
space:
mode:
authordufourj2006-01-30 23:04:52 +0000
committerdufourj2006-01-30 23:04:52 +0000
commitdbffb2d3ecfa4483099e8e888f1541706d5bd54d (patch)
tree510cbf8d0f746891c8c2e2d0c4ece8900b72d5ce /i/pc104/initrd/conf/update_initrd.sh
parentbabbeb8dfe6083ae08e61d0624c9eb7b62b8eeb8 (diff)
PC104:
- passage en init plutôt que linuxrc - enfin un mécanisme qui marchotte pour chrooter sur le système réel et rebooter proprement.
Diffstat (limited to 'i/pc104/initrd/conf/update_initrd.sh')
-rwxr-xr-xi/pc104/initrd/conf/update_initrd.sh18
1 files changed, 11 insertions, 7 deletions
diff --git a/i/pc104/initrd/conf/update_initrd.sh b/i/pc104/initrd/conf/update_initrd.sh
index b06057c..4a76956 100755
--- a/i/pc104/initrd/conf/update_initrd.sh
+++ b/i/pc104/initrd/conf/update_initrd.sh
@@ -10,7 +10,8 @@ ifconfig eth0 up
# Get the configuration of the network via dhcp
udhcpc -i eth0 -s /etc/udhcpc.script
# Wait here for a connection. I do not know if it is a feature or a bug, but
-# when nc receive a connection, it is end here.
+# when nc receive a connection, it is end here. Maybe it is because of the
+# missing library (warmed by gcc at compiled time)
nc -l -p 1234
# Mount the real system
@@ -19,15 +20,18 @@ mount /mnt/localsys
# XXX It is a good idea to pivot_root ? Chroot is better ?
cd /mnt/localsys
pivot_root . old_root
-exec chroot . sh <dev/console >dev/console 2>&1
+# FIXME: I do not sure this is the good solution... Why make a exec and a
+# chroot ? I am not sure it is a good idea...
+exec chroot . sh -c '/etc/init.d/mountvirtfs; /etc/init.d/ssh start;' \
+<dev/console >dev/console 2>&1
# This part sux : what's about the old process ?
# Kill them ?
-umount /old_root
+#umount /old_root
# We should call all the script
# TODO : find a better way to call it.
-/etc/init.d/mountvirtfs start
-/etc/init.d/mountall.sh start
-/etc/init.d/networking start
-/etc/init.d/ssh start
+#/etc/init.d/mountvirtfs start
+##/etc/init.d/mountall.sh start
+#/etc/init.d/networking start
+#/etc/init.d/ssh start
# XXX And for the end ?
# The FS has enough errors so do it well ! Umount everything !