[syslinux] syslinux booting from a third partion of ipod.

Nazo nazosan at gmail.com
Mon Apr 30 23:52:07 PDT 2007


On 4/29/07, Adrian T <syslinux at g-ss.com> wrote:
> Hello,
> I hope that somebody can help me, I am trying to boot Knoppix from the third
> parition of an ipod nano with out loosing the player capabilities. After
> fdisk I have the following partitions:
>
> slr ~ # fdisk -l /dev/sda
>
> Disk /dev/sda: 4095 MB, 4095737344 bytes
> 255 heads, 63 sectors/track, 497 cylinders
> Units = cylinders of 16065 * 512 = 8225280 bytes
>
>    Device Boot      Start         End      Blocks   Id  System
> /dev/sda1               1          10       80293+   0  Empty           (ipod firmware)
> /dev/sda2              11         339     2642692+   b  W95 FAT32       (music data)
> /dev/sda3   *         340         497     1269135    6  FAT16           (knoppix files)
>
> It seems that every usb-linux guide uses the first partition as the boot
> partition, on the ipod nano the first partition contains the firmware of the
> device rendering it inoperable if it is removed.
>
> After paritioning and formating with "mkdosfs -F 16 /dev/sda3" I copied the
> contents of a knoppix cd to the third partition, so with ls I get the
> following
>
> slr /mnt/usb # ls
> autorun.bat  balder.img  cdrom.ico  german.kbd  ldlinux.sys  memtest
> autorun.inf  boot.cat    f2         index.html  linux        minirt.gz
> autorun.pif  boot.msg    f3         knoppix     logo.16      syslinux.cfg
>
>
> after that I ran "syslinux -fs /dev/sda3"
>
>
> Is it possible to to boot like tihs? Am I missing something?
>
>
>
> The contents of syslinux.cfg follows
> ------------------------------------------------------
> DEFAULT linux
> APPEND ramdisk_size=100000 init=/etc/init lang=us apm=power-off vga=791
> initrd=minirt.gz nomce loglevel=0 quiet BOOT_IMAGE=knoppix
> TIMEOUT 300
> PROMPT 1
> DISPLAY boot.msg
> F1 boot.msg
> F2 f2
> F3 f3
> LABEL knoppix
> KERNEL linux
> APPEND ramdisk_size=100000 init=/etc/init lang=us apm=power-off vga=791
> initrd=minirt.gz nomce loglevel=0 quiet BOOT_IMAGE=knoppix
> LABEL expert
> KERNEL linux
> APPEND ramdisk_size=100000 init=/etc/init lang=us apm=power-off vga=791
> initrd=minirt.gz nomce BOOT_IMAGE=expert
> LABEL memtest
> KERNEL memtest
> APPEND foo
> LABEL knoppix-txt
> KERNEL linux
> APPEND ramdisk_size=100000 init=/etc/init lang=us apm=power-off vga=normal
> initrd=minirt.gz nomce loglevel=0 quiet BOOT_IMAGE=knoppix
> LABEL debug
> KERNEL linux
> APPEND ramdisk_size=100000 init=/etc/init lang=us apm=power-off vga=normal
> initrd=minirt.gz debug BOOT_IMAGE=debug
> LABEL fb1280x1024
> KERNEL linux
> APPEND ramdisk_size=100000 init=/etc/init lang=us apm=power-off vga=794
> xmodule=fbdev initrd=minirt.gz nomce loglevel=0 quiet BOOT_IMAGE=knoppix
> LABEL fb1024x768
> KERNEL linux
> APPEND ramdisk_size=100000 init=/etc/init lang=us apm=power-off vga=791
> xmodule=fbdev initrd=minirt.gz nomce loglevel=0 quiet BOOT_IMAGE=knoppix
> LABEL fb800x600
> KERNEL linux
> APPEND ramdisk_size=100000 init=/etc/init lang=us apm=power-off vga=788
> xmodule=fbdev initrd=minirt.gz nomce loglevel=0 quiet BOOT_IMAGE=knoppix
> LABEL dos
> KERNEL balder.img
> LABEL failsafe
> KERNEL linux
> APPEND ramdisk_size=100000 init=/etc/init lang=us vga=normal atapicd nosound
> noapic noacpi pnpbios=off acpi=off nofstab noscsi nodma noapm nousb nopcmcia
> nofirewire noagp nomce nodhcp xmodule=vesa initrd=minirt.gz
> BOOT_IMAGE=knoppix
> LABEL userdef
> KERNEL linux
> APPEND
> ##############################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################
>
> _______________________________________________
> SYSLINUX mailing list
> Submissions to SYSLINUX at zytor.com
> Unsubscribe or set options at:
> http://www.zytor.com/mailman/listinfo/syslinux
> Please do not send private replies to mailing list traffic.
>
>

First of all, Knoppix may require some configuration to get it to boot
off of a USB drive as it's originally intended to boot from CD.  From
what I can tell on the project site, this appears not to have changed.
 If it does not, you would have to modify the initial ramdrive to add
in USB mass storage drivers and anything else you need to support the
use of those for this purpose as well as modify the startup scripts to
look for partitions since you don't typically check partitions on a CD
(also, if it doesn't look for SCSI drives at all, further modification
would be necessary.)  I think you would be better served by finding a
live distro that better supports USB than to try to do all this.  For
example, Finnix is similar to Knoppix in some of the way it is
designed to be a "toolchest" of sorts and supports USB booting, so
requires very minimal effort to get working on a USB drive, however it
is a little more minimal and does not have X, so you may need to
search around for one that suits your needs best.  I know that Ubuntu
can be installed to a partition on a USB drive (I'm running it this
way on my laptop since the internal IDE keeps frying whatever I plug
in) but I haven't tried it to see if it handles hardware detection on
every bootup or if the installer writes it for the current system (the
latter is a lot more likely -- especially considering how fast it
starts for me -- so you may not have any luck with this.)  The
requirement of 2GB free bare minimum for installation (and the fact
that it will hit 3GB very quickly unless you remove more than you add)
makes it a little less than ideal for many situations, but since you
are working with an actual harddrive perhaps it's not so bad.

Another thing of note.  You might try creating that boot partition as
partition 4 instead of 3.  It won't help much, but it might slightly
increase BIOS support by making a few that support the USB-ZIP option
but not USB-HDD work.  Again, it would not help much because geometry
is a bit more important than partition number, but if it boots on even
one more machine that you could need it on it could be helpful.  If
you are feeling really brave you might try backing up the entire iPod
harddrive to an image, making a backup of the individual partitions
via partimage or even just dd if you can get the sizes and all exactly
the same (or at least the first one certainly since that firmware
partition may have something unusual to it that needs to be duplicated
exactly,) and using the mkdiskimage script to format and partition the
drive much like a zip disk, then resizing the partition it creates and
putting the old partitions back in.  This would probably in theory
work, but at the same time it could brick your iPod for all that I
know (at least it's not something I'd try on such expensive hardware
certainly) so while I think you could safely restore by using the
harddrive image, I wouldn't be willing to bet on it were it my iPod.
Having a drive that meets USB-ZIP specs does greatly increase
compatibility however as it should still work on BIOSes that support
USB-HDD while also working on many that do not (never all
unfortunately.)




More information about the Syslinux mailing list