diff options
author | Dirk von Suchodoletz | 2009-01-28 19:46:38 +0100 |
---|---|---|
committer | Dirk von Suchodoletz | 2009-01-28 19:46:38 +0100 |
commit | c649d16867e717d9d123ad96b29b560ed1a53018 (patch) | |
tree | 0c18521be84af6395ce599c0c106624a4b8be591 | |
parent | * worked simple WAN-booting into a working state (diff) | |
download | core-c649d16867e717d9d123ad96b29b560ed1a53018.tar.gz core-c649d16867e717d9d123ad96b29b560ed1a53018.tar.xz core-c649d16867e717d9d123ad96b29b560ed1a53018.zip |
Fix to pass on dns server ip from preboot to stage3.
git-svn-id: http://svn.openslx.org/svn/openslx/openslx/trunk@2547 95ad53e4-c205-0410-b2fa-d234c58c8868
-rwxr-xr-x | boot-env/preboot/init | 9 | ||||
-rwxr-xr-x | boot-env/preboot/preboot.sh | 7 |
2 files changed, 9 insertions, 7 deletions
diff --git a/boot-env/preboot/init b/boot-env/preboot/init index 7b908ea5..f2e4f50e 100755 --- a/boot-env/preboot/init +++ b/boot-env/preboot/init @@ -20,8 +20,11 @@ for i in 1 2 ; do if grep "ip=" /tmp/ipstuff >/dev/null 2>&1 ; then . /tmp/ipstuff for i in $dns ; do - echo "nameserver $i" >> /etc/resolv.conf + echo "nameserver $i" >>/etc/resolv.conf done + # simply add a single dns server for passing via kernel cmdline to stage3 + # (quickhack, just the last, list of dns might be better ...) + echo "dnssrv=$i" >>/tmp/ipstuff return else if [ $i -eq 1 ] ; then @@ -136,8 +139,8 @@ tar -xzf /tmp/preboot.env -C /preboot if [ "${DEBUGLEVEL}" -gt 0 ] ; then /bin/ash else - quiet=quiet - echo -e "\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n" + # no debugging output for stage3 run + echo "quiet=quiet" >>/etc/initramfs-setup fi # run the preboot interactive part which finally will execute kexec cd /preboot diff --git a/boot-env/preboot/preboot.sh b/boot-env/preboot/preboot.sh index 1d7c77fb..c6d10b1a 100755 --- a/boot-env/preboot/preboot.sh +++ b/boot-env/preboot/preboot.sh @@ -21,16 +21,15 @@ dialog --file bootmenu.dialog 2>result # $label) . ./$(cat result) -echo $kernel - +# fetch kernel and initramfs of selected system wget -O /tmp/kernel $boot_uri/$kernel wget -O /tmp/initramfs $boot_uri/$initramfs # read primary IP configuration to pass it on . /tmp/ipstuff -# start the new kernel with initialramfs and cmdline +# start the new kernel with initialramfs and composed cmdline echo "Booting OpenSLX client $label ..." kexec -l /tmp/kernel --initrd=/tmp/initramfs \ - --append="$append file=$boot_uri debug=3" + --append="ip=$ip:$siaddr:$router:$subnet:$dnssrv $append file=$boot_uri $quiet" kexec -e |