Jump to content











Photo
- - - - -

Knoppix 6.7 with GRUB4DOS


  • Please log in to reply
13 replies to this topic

#1 aBs0lut3z33r0

aBs0lut3z33r0
  • Members
  • 9 posts
  •  
    United States

Posted 26 January 2012 - 12:16 AM

Has anyone found a way to boot KNOPPIX ISO or folder direct from USB drive with GRUB4DOS . Please post working Menu.lst entries . The existing method is not working for me.

I tried this and a couple of other variations : -

title Knoppix
kernel /knoppix6.7.1/boot/isolinux/linux vga=0x317 ramdisk_size=100000 lang=en vt.default_utf8=0 apm=power-off video=640x480 initrd=minirt.gz nomce libata.force=noncq hpsa.hpsa_allow_any=1 loglevel=1 tz=localtime adriane
initrd /knoppix6.7.1/boot/isolinux/minirt.gz

Edited by aBs0lut3z33r0, 26 January 2012 - 12:17 AM.


#2 ilko

ilko

    Silver Member

  • Advanced user
  • 500 posts
  •  
    Bulgaria

Posted 26 January 2012 - 06:07 AM

title Knoppix from ADRIANE-KNOPPIX_V6.7.0CD-2011-08-07-EN.iso

ls /ADRIANE-KNOPPIX_V6.7.0CD-2011-08-07-EN.iso > nul || find --set-root --devices=hf /ADRIANE-KNOPPIX_V6.7.0CD-2011-08-07-EN.iso

map /ADRIANE-KNOPPIX_V6.7.0CD-2011-08-07-EN.iso (0xff) || map --mem /ADRIANE-KNOPPIX_V6.7.0CD-2011-08-07-EN.iso (0xff)

map --hook

root (0xff)

kernel /boot/isolinux/linux bootfrom=ADRIANE-KNOPPIX_V6.7.0CD-2011-08-07-EN.iso ramdisk_size=100000 lang=en vt.default_utf8=0 apm=power-off nomce libata.force=noncq hpsa.hpsa_allow_any=1 loglevel=1 tz=localtime

initrd /boot/isolinux/minirt.gz

ADRIANE-KNOPPIX_V6.7.0CD-2011-08-07-EN.iso is in root of FAT32 formatted USB flash disk. Tested to desktop in QEMU.
bootfrom parameter expects a device too in front of the ISO file name, but put this way boot script will figure out the ISO name and emergency scan all devices for that ISO file.

For other kernel parameters look in /boot/isolinux/isolinux.cfg.
  • aBs0lut3z33r0 likes this

#3 aBs0lut3z33r0

aBs0lut3z33r0
  • Members
  • 9 posts
  •  
    United States

Posted 26 January 2012 - 08:29 AM

Thxs , tested on qemu its working while booting i am getting an error

Posted Image

In the second line i removed this
ls /ADRIANE-KNOPPIX_V6.7.0CD-2011-08-07-EN.iso > nul

what is ls for ? I was getting an error with >nul

#4 steve6375

steve6375

    Platinum Member

  • Developer
  • 7028 posts
  • Location:UK
  • Interests:computers, programming (masm,vb6,C,vbs), photography,TV,films,guitars, www.easy2boot.com
  •  
    United Kingdom

Posted 26 January 2012 - 09:54 AM

To get rid of the error, use the latest grub4dos (included in latest Beta of RMPrepUSB :good: ) should be > nul not >nul (i.e. <space> > <space> nul ).
The line

ls /ADRIANE-KNOPPIX_V6.7.0CD-2011-08-07-EN.iso > nul || find --set-root --devices=hf /ADRIANE-KNOPPIX_V6.7.0CD-2011-08-07-EN.iso

means 'list the iso directory entry on the current root device but do not display the result on the screen - if that didn't work (|| = OR ELSE), look for the iso file on all hard disk and floppy devices and set the root device to the same device'.
HTH
  • aBs0lut3z33r0 likes this

#5 ilko

ilko

    Silver Member

  • Advanced user
  • 500 posts
  •  
    Bulgaria

Posted 26 January 2012 - 09:56 AM

Must be talking about 2 different errors- first because of the line you mention- use newer grub4dos version where nul is implemented.
ls would list the file and output is send to nul. If cannot list it because root device is other- find the file and set root where the file is.

And the second, from the screenshot- ignore it, it boots fine, doesn't it?
As mentioned- bootfrom should be like /dev/sda1/iso_file.iso.
Boot script splits the two parts- /dev/sda1 and iso_file.iso and attempts to mount the iso using that path. That fails. We did not give path.
Next is emergency search for the iso file on all devices- success, file is found and mounted.

Better solution, although a bit cheating, than having to worry to provide a proper device path to the ISO. Let the boot script find it ;)
  • aBs0lut3z33r0 likes this

#6 aBs0lut3z33r0

aBs0lut3z33r0
  • Members
  • 9 posts
  •  
    United States

Posted 26 January 2012 - 10:39 AM

Thxs for all your responses . I am getting no display on my laptop with some iso's . The same ISO work fine on other PC's.

The ISO's which do not work are :

Parted Magic (More Info : http://forums.parted....php?f=2&t=1955 )
Knoppix 6.7
KAV

I am using HP Envy14 laptop with ATI 5650 switchable graphics .

The Menu.lst entries are correct since they are working on other PCs . Has anyone else reported a similar issue.

Edited by aBs0lut3z33r0, 26 January 2012 - 10:40 AM.


#7 aBs0lut3z33r0

aBs0lut3z33r0
  • Members
  • 9 posts
  •  
    United States

Posted 26 January 2012 - 02:02 PM

IS there any method i can change the path of the ISO . Setting it to custom path does not boot Knoppix

#8 davlak

davlak

    Frequent Member

  • Advanced user
  • 224 posts
  •  
    Italy

Posted 26 January 2012 - 03:18 PM

I use to boot Knoppix 6.7.1 ISO mapping as usual. Say that the iso is named knoppix.iso and stays in the root of any partition:


find --set-root /knoppix.iso

map /knoppix.iso (hd32)

map --hook

root (hd32)

chainloader (hd32)


and then at the knoppix prompt:


knoppix bootfrom=/knoppix.iso


it will search for the iso on the root of any partition and will boot.

#9 steve6375

steve6375

    Platinum Member

  • Developer
  • 7028 posts
  • Location:UK
  • Interests:computers, programming (masm,vb6,C,vbs), photography,TV,films,guitars, www.easy2boot.com
  •  
    United Kingdom

Posted 26 January 2012 - 03:35 PM

With latest grub4dos grldr file, you can use a variable for the ISO which makes it easier to change when a new version is used:
Just change the title line

iftitle [if exist /ADRIANE-KNOPPIX_V6.7.1CD-2011-09-14-EN.iso set K1109=/ADRIANE-KNOPPIX_V6.7.1CD-2011-09-14-EN.iso] Boot %K1109%

set ISO=%K1109%

ls %ISO% > nul || find --set-root --devices=hf %ISO%

map %ISO% (0xff) || echo %ISO% not contiguous - so need to load it all into memory... && map --mem %ISO% (0xff)

map --hook

root (0xff)

kernel /boot/isolinux/linux bootfrom=%ISO% noeject noprompt ramdisk_size=100000 lang=en vt.default_utf8=0 apm=power-off nomce libata.force=noncq hpsa.hpsa_allow_any=1 loglevel=1 tz=localtime

initrd /boot/isolinux/minirt.gz


ISO need to be in the root.
  • aBs0lut3z33r0 likes this

#10 steve6375

steve6375

    Platinum Member

  • Developer
  • 7028 posts
  • Location:UK
  • Interests:computers, programming (masm,vb6,C,vbs), photography,TV,films,guitars, www.easy2boot.com
  •  
    United Kingdom

Posted 26 January 2012 - 03:55 PM

You can have the iso in a folder, but you must specify the full boot path (which is not too convenient when wanting to boot from different systems) - e.g.

bootfrom=/dev/sda1/_iso/knoppix.iso

works, but


bootfrom=_iso/knoppix.iso or bootfrom=/_iso/knoppix.iso do not work.

The path and filename are Case Sensitive too.
  • aBs0lut3z33r0 likes this

#11 cdob

cdob

    Gold Member

  • Expert
  • 1438 posts

Posted 27 January 2012 - 08:33 PM

bootfrom=ADRIANE-KNOPPIX_V6.7.0CD-2011-08-07-EN.iso

Thank's for the head up.

IS there any method i can change the path of the ISO .

Use ././ as a device name. It's not supported, but seems to work by chance.

Klaus offers a boot only part in addition nowadays. http://www.knopper.net/
That's core boot data about 10mb, it's sufficient to RAM load this part only.

Files at USB drive:
\images\KNOPPIX_V6.7.1.iso
\images\KNOPPIX_V6.7.1bootonly.iso

title Knoppix 6.7.1

set ISOfile=/images/KNOPPIX_V6.7.1

ls %ISOfile%.iso > nul || find --set-root --devices=hf %ISOfile%.iso

map %ISOfile%.iso (0xff) || echo %ISO%.iso not contiguous - try file %ISOfile%bootonly.iso && map --mem %ISOfile%bootonly.iso (0xff)

map --hook

root (0xff)

kernel /boot/isolinux/linux bootfrom=././%ISOfile%.iso noeject noprompt ramdisk_size=100000 lang=en vt.default_utf8=0 apm=power-off nomce libata.force=noncq hpsa.hpsa_allow_any=1 loglevel=1 tz=localtime

initrd /boot/isolinux/minirt.gz

boot


#12 steve6375

steve6375

    Platinum Member

  • Developer
  • 7028 posts
  • Location:UK
  • Interests:computers, programming (masm,vb6,C,vbs), photography,TV,films,guitars, www.easy2boot.com
  •  
    United Kingdom

Posted 27 January 2012 - 09:37 PM

I tried ././ but it did not work, however /./somedir/isofile does work - e.g.

iftitle [if exist /_ISO/A.iso set K1109=/_ISO/A.iso] Boot %K1109%
set ISO=%K1109%
ls %ISO% > nul || find --set-root --devices=hf %ISO%
map %ISO% (0xff) || echo %ISO% not contiguous - so need to load it all into memory... && map --mem %ISO% (0xff)
map --hook
root (0xff)
kernel /boot/isolinux/linux bootfrom=/./%ISO% noeject noprompt ramdisk_size=100000 lang=en vt.default_utf8=0 apm=power-off nomce libata.force=noncq hpsa.hpsa_allow_any=1 loglevel=1 tz=localtime
initrd /boot/isolinux/minirt.gz


#13 ilko

ilko

    Silver Member

  • Advanced user
  • 500 posts
  •  
    Bulgaria

Posted 27 January 2012 - 09:59 PM

The applicable part of /boot/isolinux/minirt.gzminirtinit:
#@@@GvR Bootfrom Section start

BOOTSYS="/mnt-system"  

if [ ! -r "$BOOTSYS/$knoppix_dir/KNOPPIX" ]; then

# find BOOTFROM variable (/dev/sda1/boot/k620/*.iso)

BOOTFROM=""; bootfrom="";

for i in $CMDLINE; do case "$i" in [Bb][Oo][Oo][Tt][Ff][Rr][Oo][Mm]=*) eval $i;; esac; done

[ -n "$bootfrom" ] && BOOTFROM="$bootfrom"

if [ -n "$BOOTFROM" ]; then

  # we may have an ISO file, try mounting it

  BOOTISO="/mnt-iso"; BOOTDEV=""; BOOTFILE=""

  mkdir -p $BOOTISO $BOOTSYS

  [ -b /dev/loop1 ] || mknod -m 755 /dev/loop1 b 7 1

  if [ -n "$NFSDIR" ]; then

   umount $BOOTSYS; MOUNTED=""

   message nfs remount "${NFSDIR}" "${BOOTISO}" -o ro,rsize=8192,wsize=8192,hard,nolock,intr$SECUREOPTIONS

   mount "${NFSDIR}" "${BOOTISO}" -o ro,rsize=8192,wsize=8192,hard,nolock,intr$SECUREOPTIONS > /dev/null 2>&1 && MOUNTED="yes"

   if [ -z "$MOUNTED" ]; then

	umount $BOOTISO >/dev/null 2>&1

	if [ -x /static/mount.cifs ]; then

	 message cifs remount "${NFSDIR}" "${BOOTISO}" -r  -o guest,noserverino,nounix

	 /static/mount.cifs   "${NFSDIR}" "${BOOTISO}" -r  -o guest,noserverino,nounix > /dev/null 2>&1  && MOUNTED="yes"

	 [ -z "$MOUNTED" ] && umount $BOOTISO > /dev/null 2>&1

	fi

   fi

   BOOTFILE=$BOOTFROM

  else

   BOOTDEV=$(echo "$BOOTFROM" | awk -F/ '{print $1"/"$2"/"$3}')

   BOOTFILE="${BOOTFROM#*/}"; BOOTFILE="${BOOTFILE#*/}"; BOOTFILE="${BOOTFILE#*/}"

   message -n "${CRE}${BLUE}Trying to mount the ISO partition ${MAGENTA}$BOOTDEV${BLUE}...${NORMAL}"

   trymount "$BOOTDEV" "$BOOTISO" >/dev/null 2>&1

  fi

  if [ ! -r "$BOOTISO/$BOOTFILE" ]; then umount $BOOTISO >/dev/null 2>&1

   message "${CRE}${RED}Cannot mount the partition ${MAGENTA}$BOOTDEV${NORMAL} (cannot find: ${RED}${BOOTISO}/${BOOTFILE}${NORMAL})"

   ls -al "$BOOTISO"

  else

   message -n "${CRE}${BLUE}Trying to mount CD image on ${MAGENTA}${BOOTFILE}${BLUE}...${NORMAL}"

   losetup /dev/loop1 "$BOOTISO/$BOOTFILE" && mount -r /dev/loop1 $BOOTSYS >/dev/null 2>&1

   if [ ! -r "$BOOTSYS/$knoppix_dir/KNOPPIX" ]; then umount $BOOTSYS >/dev/null 2>&1

	message -n "${CRE}${RED}Cannot mount CD image on ${MAGENTA}${BOOTFILE}${NORMAL}"

	umount "$BOOTSYS" >/dev/null 2>&1

	losetup -d /dev/loop1 >/dev/null 2>&1

   else

	message -e "r${CRE}${GREEN}$DISTRO ${FOUNDAT}: ${MAGENTA}${BOOTDEV}/$(cd $BOOTISO; ls -a $BOOTFILE)${NORMAL}	   "

   fi

  fi

  # try to find ISO in an alternate locations using the same path

  if [ ! -r "$BOOTSYS/$knoppix_dir/KNOPPIX" ]; then

   message -n "${CRE}${MAGENTA}Trying to find the ISO image in an other partition...${NORMAL}"

   # If USB storage device, wait for USB...

   if [ -d /sys/bus/usb/drivers/usb-storage ]; then WUSB="1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20"; else WUSB="1"; fi

   for i in $WUSB ; do

	for BOOTDEV in $(listpartitions 'hd[a-z]' 'hd[a-z][0-9]*' 'scd[0-9]*' 'sr[0-9]*' 'sd[a-z]' 'sd[a-z][0-9]*'); do

	 if [ -b "$BOOTDEV" ]; then

	  message -n -e "r${CRE}${BLUE}Searching for ISO in: ${MAGENTA}${BOOTDEV}${NORMAL}   "

	  trymount "$BOOTDEV" "$BOOTISO" > /dev/null 2>&1

	  if [ ! -r "$BOOTISO/$BOOTFILE" ]; then umount $BOOTISO >/dev/null 2>&1; else

	   message -n "${CRE}${BLUE}Trying to mount CD image on ${MAGENTA}${BOOTFILE}${BLUE}...${NORMAL}"

	   losetup /dev/loop1 "$BOOTISO/$BOOTFILE" && mount -r /dev/loop1 $BOOTSYS >/dev/null 2>&1

	   if [ ! -r "$BOOTSYS/$knoppix_dir/KNOPPIX" ]; then

		umount $BOOTSYS >/dev/null 2>&1

		losetup -d /dev/loop1 >/dev/null 2>&1

	   else

		message -e "r${CRE}${GREEN}$DISTRO ${FOUNDAT}: ${MAGENTA}${BOOTDEV}/$(cd $BOOTISO; ls -a $BOOTFILE)${NORMAL}	   "

	   fi

	  fi

	 fi

	done

	if [ -r "$BOOTSYS/$knoppix_dir/KNOPPIX" ]; then

	 break

	else

	 message -n -e "r${CRE}${BLUE}${WAITFORUSB}${NORMAL} $i ";

	 sleep 1

	fi

   done

  fi

fi

fi

if [ -r "$BOOTSYS/$knoppix_dir/KNOPPIX" ]; then MOUNTED="yes"; FOUND_KNOPPIX="true"; fi

#@@@GvR Bootfrom Section end

Use ././ as a device name. It's not supported, but seems to work by chance.

Please note:
BOOTDEV=$(echo "$BOOTFROM" | awk -F/ '{print $1"/"$2"/"$3}')

BOOTFILE="${BOOTFROM#*/}"; BOOTFILE="${BOOTFILE#*/}"; BOOTFILE="${BOOTFILE#*/}"


#14 cdob

cdob

    Gold Member

  • Expert
  • 1438 posts

Posted 29 January 2013 - 08:28 PM

Use ././ as a device name. It's not supported, but seems to work by chance.

Another notation : /dev/*
This reminds to cheat code http://www.knopper.n...o/index-en.html
ftp://ftp.uni-kl.de/pub/linux/knoppix/knoppix-cheatcodes.txt
knoppix bootfrom=/dev/sda1/KNX.iso Access image, boot from ISO-Image. ***)

Search logic dosn't use /dev/* on purpose. ISO image is found nontheless.
 
title Knoppix 7
set lang=en
set ISOfile=/images/KNOPPIX_V7.0.5.iso
cat --length=0 %ISOfile% > nul || find --set-root --devices=hf %ISOfile%
map %ISOfile% (0xff)
map --hook
root (0xff)
kernel /boot/isolinux/linux bootfrom=/dev/*%ISOfile% noeject noprompt ramdisk_size=100000 lang=%lang% vt.default_utf8=0 apm=power-off nomce libata.force=noncq hpsa.hpsa_allow_any=1 loglevel=1 tz=localtime
initrd /boot/isolinux/minirt.gz





0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users