We don't use linux26 but vmlinuz as kernel file name
and initrd.img instead of minirt26.gz for the initramfs nowadays.
Thanks: Ulrich Dangel for helping resolve the mess
#KERNEL_VERSION_=""
# this is the path where the grml image/cdrom is placed (mounted)
#KERNEL_VERSION_=""
# this is the path where the grml image/cdrom is placed (mounted)
#MOUNT_POINT_=""
# path + name of the linux kernel you would want to boot
#MOUNT_POINT_=""
# path + name of the linux kernel you would want to boot
-# default: /cdrom/boot/isolinux/linux26
+# default: /live/image/boot/$GRML_NAME/vmlinuz
#KERNEL_IMAGE_=""
# this is the initrd the grml-terminalserver-config edits
# if the file is not found, default will be used
#KERNEL_IMAGE_=""
# this is the initrd the grml-terminalserver-config edits
# if the file is not found, default will be used
-# default: /cdrom/boot/isolinux/minirt26.gz
+# default: /live/image/boot/$GRML_NAME/initrd.img
#ORIGINAL_INITRD_=""
# path + name of the memtest image
#ORIGINAL_INITRD_=""
# path + name of the memtest image
-# default: /cdrom/boot/isolinux/memtest
+# default: /live/image/boot/addons/memtest
#MEMTEST_IMAGE_=""
# path to pxelinux boot message
#MEMTEST_IMAGE_=""
# path to pxelinux boot message
-# default: /cdrom/boot/isolinux/boot.msg
+# default: /live/image/boot/isolinux/boot.msg
#PXE_BOOT_MSG_=""
# path to pxelinux boot logo
#PXE_BOOT_MSG_=""
# path to pxelinux boot logo
-# default: /cdrom/boot/isolinux/logo.16
+# default: /live/image/boot/isolinux/logo.16
#PXE_BOOT_LOGO_=""
# should the terminalserver activate snat for the clients to his default gateway?
#PXE_BOOT_LOGO_=""
# should the terminalserver activate snat for the clients to his default gateway?
KERNEL_VERSION_=`uname -r`
KERNEL_VERSION_=`uname -r`
-if [ -e '/live/cow' ]; then
+if [ -e '/live/image' ]; then
MOUNT_POINT_="/live/image"
else
MOUNT_POINT_="/cdrom"
MOUNT_POINT_="/live/image"
else
MOUNT_POINT_="/cdrom"
ADDONS_PATH_="$MOUNT_POINT_"
fi
ADDONS_PATH_="$MOUNT_POINT_"
fi
-if [[ "$(find $DATA_PATH_/ -maxdepth 2 -name linux26 |head -n1)" != "" ]] ; then
- MULTIBOOT_PATH_="$(dirname $(find $DATA_PATH_ -maxdepth 2 -name linux26 |head -n1))"
+if [[ "$(find $DATA_PATH_/ -maxdepth 2 -name vmlinuz |head -n1)" != "" ]] ; then
+ MULTIBOOT_PATH_="$(dirname $(find $DATA_PATH_ -maxdepth 2 -name vmlinuz |head -n1))"
else
MULTIBOOT_PATH_="$MOUNT_POINT_"
fi
else
MULTIBOOT_PATH_="$MOUNT_POINT_"
fi
MULTIBOOT_PATH_="$MOUNT_POINT_"
fi
MULTIBOOT_PATH_="$MOUNT_POINT_"
fi
-KERNEL_IMAGE_="$MULTIBOOT_PATH_/linux26"
+KERNEL_IMAGE_="$MULTIBOOT_PATH_/vmlinuz"
if [[ ! -f "$KERNEL_IMAGE_" ]] ; then
KERNEL_IMAGE_="/boot/vmlinuz-$KERNEL_VERSION_"
fi
if [[ ! -f "$KERNEL_IMAGE_" ]] ; then
KERNEL_IMAGE_="/boot/vmlinuz-$KERNEL_VERSION_"
fi
-ORIGINAL_INITRD_="$MULTIBOOT_PATH_/initrd.gz"
+ORIGINAL_INITRD_="$MULTIBOOT_PATH_/initrd.img"
MEMTEST_IMAGE_="$ADDONS_PATH_/memtest"
if [ ! -f "$MEMTEST_IMAGE_" ] ; then
MEMTEST_IMAGE_="$ADDONS_PATH_/memtest"
if [ ! -f "$MEMTEST_IMAGE_" ] ; then
execute "mkdir -p $TFTPD_DATA_DIR_/pxelinux.cfg" die
execute "install -m 644 /usr/lib/syslinux/pxelinux.0 $TFTPD_DATA_DIR_" die
execute "mkdir -p $TFTPD_DATA_DIR_/pxelinux.cfg" die
execute "install -m 644 /usr/lib/syslinux/pxelinux.0 $TFTPD_DATA_DIR_" die
- execute "install -m 644 $PATH_/minirt26.gz $TFTPD_DATA_DIR_" die
+ execute "install -m 644 $PATH_/initrd.img $TFTPD_DATA_DIR_" die
if [ -d "$MOUNT_POINT_"/boot/release ] ; then
cp -r "$MOUNT_POINT_"/boot/release "$TFTPD_DATA_DIR_"
else
if [ -d "$MOUNT_POINT_"/boot/release ] ; then
cp -r "$MOUNT_POINT_"/boot/release "$TFTPD_DATA_DIR_"
else
- execute "install -m 644 $KERNEL_IMAGE_ $TFTPD_DATA_DIR_/linux26" die
+ execute "install -m 644 $KERNEL_IMAGE_ $TFTPD_DATA_DIR_/vmlinuz" die
fi
[ -f "$MEMTEST_IMAGE" ] && execute "install -m 644 $MEMTEST_IMAGE_ $TFTPD_DATA_DIR_/memtest" die
execute "install -m 644 $PXE_BOOT_MSG_ $TFTPD_DATA_DIR_" die
fi
[ -f "$MEMTEST_IMAGE" ] && execute "install -m 644 $MEMTEST_IMAGE_ $TFTPD_DATA_DIR_/memtest" die
execute "install -m 644 $PXE_BOOT_MSG_ $TFTPD_DATA_DIR_" die
if [ $check_necessary_files_ == 'yes' ]; then
# test for files absolutly necessary for grml-terminalserver and created from -config
problem_=0
if [ $check_necessary_files_ == 'yes' ]; then
# test for files absolutly necessary for grml-terminalserver and created from -config
problem_=0
- for i in $PATH_/minirt26.gz; do
+ for i in $PATH_/initrd.img; do
isExistent $i warn || problem_=1
done
if [ $problem_ -eq 1 ]; then
isExistent $i warn || problem_=1
done
if [ $problem_ -eq 1 ]; then
# INITRD {{{
function actionMkInitrd
{
# INITRD {{{
function actionMkInitrd
{
- echo "Installing initrd $PATH_/minirt26.gz:"
+ echo "Installing initrd $PATH_/initrd.img:"
# until we have a stable file location API let's use
# an according heuristic
initrd_=initrd.img-"$(uname -r)"
# until we have a stable file location API let's use
# an according heuristic
initrd_=initrd.img-"$(uname -r)"
- cp /boot/"$initrd_" "$PATH_"/minirt26.gz || die "Could not copy /boot/$initrd_"
+ cp /boot/"$initrd_" "$PATH_"/initrd.img || die "Could not copy /boot/$initrd_"
- for i in dhcpd.conf minirt26.gz; do
+ for i in dhcpd.conf initrd.img; do
execute "rm -f $PATH_/$i*"
done
execute "rm -f $PATH_/$i*"
done
# GLOBAL_README_END
if grep -q live-media-path= /proc/cmdline 2>/dev/null ; then
# GLOBAL_README_END
if grep -q live-media-path= /proc/cmdline 2>/dev/null ; then
- live_media_path_="live-media-path=$(awk -F live-media-path= '{print $2}' /proc/cmdline)"
+ live_media_path_="live-media-path=$(awk -F live-media-path= '{print $2}' /proc/cmdline | awk '{print $1}')"
fi
if [ ! -d /live/image/boot ] ; then
live_media_path_="live-media-path=/"
fi
# default boot arguments used for both grub and pxelinux
fi
if [ ! -d /live/image/boot ] ; then
live_media_path_="live-media-path=/"
fi
# default boot arguments used for both grub and pxelinux
-if [ -e '/live/cow' ]; then
+if [ -e "$MOUNT_POINT_" ]; then
default_boot_args_="root=/dev/nfs rw nfsroot=$IP_:$MOUNT_POINT_ \
noprompt noeject"
else
default_boot_args_="root=/dev/nfs rw nfsroot=$IP_:$MOUNT_POINT_ \
noprompt noeject"
else
fi
# special boot arguments required by grub
fi
# special boot arguments required by grub
-grub_def_boot_args_="/linux26 $default_boot_args_ $live_media_path_"
+grub_def_boot_args_="/vmlinuz $default_boot_args_ $live_media_path_"
# special boot arguments required by pxelinux
pxe_def_boot_args_="$default_boot_args_"
# special boot arguments required by pxelinux
pxe_def_boot_args_="$default_boot_args_"
title GRML
root (nd)
kernel $grub_def_boot_args_ $def_fb_args_ $BOOT_ARGS_
title GRML
root (nd)
kernel $grub_def_boot_args_ $def_fb_args_ $BOOT_ARGS_
title GRML no framebuffer
root (nd)
title GRML no framebuffer
root (nd)
title GRML small
root (nd)
kernel $grub_def_boot_args_ small $def_fb_args_ $BOOT_ARGS_
title GRML small
root (nd)
kernel $grub_def_boot_args_ small $def_fb_args_ $BOOT_ARGS_
title GRML small nofb
root (nd)
kernel $grub_def_boot_args_ small $no_fb_args_ $BOOT_ARGS_
title GRML small nofb
root (nd)
kernel $grub_def_boot_args_ small $no_fb_args_ $BOOT_ARGS_
title GRML debuginit
root (nd)
kernel $grub_def_boot_args_ debuginitrd $def_fb_args_ $BOOT_ARGS_
title GRML debuginit
root (nd)
kernel $grub_def_boot_args_ debuginitrd $def_fb_args_ $BOOT_ARGS_
title GRML debuginit nofb
root (nd)
kernel $grub_def_boot_args_ debuginitrd $no_fb_args_ $BOOT_ARGS_
title GRML debuginit nofb
root (nd)
kernel $grub_def_boot_args_ debuginitrd $no_fb_args_ $BOOT_ARGS_
title GRML rescue
root (nd)
kernel $grub_def_boot_args_ $no_fb_args_
title GRML rescue
root (nd)
kernel $grub_def_boot_args_ $no_fb_args_
sed -i -e 's#\(.*\)/boot/\(.*\)#\1\2#' $config_files_
else
# remove normal kernel path and use our image
sed -i -e 's#\(.*\)/boot/\(.*\)#\1\2#' $config_files_
else
# remove normal kernel path and use our image
- sed -i -e 's/.*kernel.*linux26/kernel linux26/' $config_files_
- sed -i -e 's/\(initrd\)=[[:alnum:]/._-]*/\1=minirt26.gz/' $config_files_
+ sed -i -e 's/.*kernel.*vmlinuz/ kernel vmlinuz/' $config_files_
+ sed -i -e 's/\(initrd\)=[[:alnum:]/._-]*/\1=initrd.img/' $config_files_
# remove live-media-path per default
sed -i -e 's#live-media-path=[[:alnum:]/._-]*##' $config_files_
# remove live-media-path per default
sed -i -e 's#live-media-path=[[:alnum:]/._-]*##' $config_files_