mirror of the now-defunct rocklinux.org
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

59 lines
1.8 KiB

  1. #!/bin/sh
  2. exec < /dev/console > /dev/console 2> /dev/console ; cd /
  3. export PATH="/sbin:/bin:/usr/sbin:/usr/bin:/usr/local/bin"
  4. umount /old_root/dev /old_root/proc /old_root ; rmdir /old_root
  5. grep -v "^rootfs " /proc/mounts > /etc/mtab
  6. freeramdisk /dev/rd/* 2> /dev/null
  7. mkdir -p /lib/modules/$( uname -r )
  8. echo -n >> /lib/modules/$( uname -r )/modules.dep
  9. cd /dev ; rm -f fd
  10. ln -sf /proc/kcore core
  11. ln -sf /proc/self/fd fd
  12. ln -sf fd/0 stdin
  13. ln -sf fd/1 stdout
  14. ln -sf fd/2 stderr
  15. cd /
  16. echo
  17. echo ' ******************************************************************'
  18. echo ' * Welcome to the ROCK Linux 2nd stage boot disk. *'
  19. echo ' ******************************************************************'
  20. echo
  21. echo 'This is a small linux distribution, loaded into your PCs memory. It has'
  22. echo 'everything needed to install ROCK Linux, restore an old installation or'
  23. echo 'perform some administrative tasks.'
  24. for x in /etc/setup-*.sh /setup/setup.sh ; do
  25. if [ -f "$x" ] ; then
  26. echo ; echo "Running $x ..." ; sh $x
  27. echo "Setup script $x finished."
  28. fi
  29. done
  30. echo
  31. echo "Enter the names of all terminal devices (e.g. 'vc/1' or 'tts/0')."
  32. echo -n "An empty text stands for vc/1 - vc/6: " ; read ttydevs
  33. [ -z "$ttydevs" ] && ttydevs="vc/1 vc/2 vc/3 vc/4 vc/5 vc/6"
  34. echo
  35. echo 'Just type "stone" now if you want to make a normal installation of a ROCK'
  36. echo -n 'Linux build '
  37. if type -p dialog > /dev/null ; then
  38. echo '(or type "stone -text" if you prefer non-dialog based menus).'
  39. else
  40. echo '(only the text interface is available).'
  41. fi
  42. echo -e '#!/bin/sh\ncd ; exec /bin/sh --login' > /sbin/login-shell
  43. chmod +x /sbin/login-shell
  44. for x in $ttydevs ; do
  45. ( ( while : ; do agetty -i 38400 $x -n -l /sbin/login-shell ; done ) & )
  46. done
  47. exec < /dev/null > /dev/null 2>&1
  48. while : ; do sleep 1 ; done