X-Git-Url: http://git.grml.org/?a=blobdiff_plain;f=scripts%2Fboot.sh;h=eeaa4dce305271377742249cd1d0ac01df466bb1;hb=dc6d1a0b26dae2b2197631bb4f94738a289e7b8a;hp=5d4a20dfd7f604251e6e3f85460febabe17a5ce0;hpb=c48696a0ebe9ffc938b84b921db90ac620339a52;p=live-boot-grml.git diff --git a/scripts/boot.sh b/scripts/boot.sh index 5d4a20d..eeaa4dc 100755 --- a/scripts/boot.sh +++ b/scripts/boot.sh @@ -2,6 +2,12 @@ # set -e +if [ -e /scripts/functions ] +then + # initramfs-tools specific (FIXME) + . /scripts/functions +fi + for _SCRIPT in /lib/live/boot/* do if [ -e "${_SCRIPT}" ] @@ -35,7 +41,28 @@ then touch /etc/mtab fi -. /scripts/live-helpers +if [ ! -x "/bin/fstype" ] +then + # klibc not in path -> not in initramfs + export PATH="${PATH}:/usr/lib/klibc/bin" +fi + +# handle upgrade path from old udev (using udevinfo) to +# recent versions of udev (using udevadm info) +if [ -x /sbin/udevadm ] +then + udevinfo='/sbin/udevadm info' +else + udevinfo='udevinfo' +fi + +old_root_overlay_label="live-rw" +old_home_overlay_label="home-rw" +custom_overlay_label="custom-ov" +root_snapshot_label="live-sn" +old_root_snapshot_label="live-sn" +home_snapshot_label="home-sn" +persistence_list="live-persistence.conf" if [ ! -f /live.vars ] then @@ -441,11 +468,18 @@ mountroot () tail -f boot.log >&7 & tailpid="${!}" - # Ensure 'panic' function is overridden - . /scripts/live-functions + . /live.vars Arguments + # make sure all harddisk devices are read-only + # this is important for forensic investigations + case "${READ_ONLY}" in + true) + Read_only + ;; + esac + maybe_break live-premount log_begin_msg "Running /scripts/live-premount" run_scripts /scripts/live-premount