Jump to content











Photo
- - - - -

kexec-loader rewrite


  • This topic is locked This topic is locked
37 replies to this topic

#26 mr_

mr_

    Frequent Member

  • Members
  • 355 posts
  •  
    Germany

Posted 08 February 2009 - 04:40 PM

It's still hard for me to express what I mean...

Here is again the config, speaking for itself.
# Example kexec-loader configuration file



# Timeout is specified in seconds

#

timeout 5



# Load device.map/menu.lst from a GRUB installation

#

#grub-path (hda2)/grub



#not working

grub-path (sda3)/boot/grub



# Map GRUB device names

# This overrides any mappings in device.map

#

# grub-map hd0 sda

# grub-map hd1,,a hda5



# Specify arguments for kernel modules

# All modules in /modules/ are loaded automatically

#

# kmod foomod name=value name

# kmod barmod name=value name



#working

title Ubuntu 8.04.2, kernel 2.6.24-23-generic - root uuid

root UUID=2bbadde7-2464-4276-ae55-a1c5079c3e12

kernel /boot/vmlinuz-2.6.24-23-generic

initrd /boot/initrd.img-2.6.24-23-generic

cmdline root=UUID=2bbadde7-2464-4276-ae55-a1c5079c3e12 ro quiet splash



#working

title Ubuntu 8.04.2, kernel 2.6.24-23-generic - root LABEL

root LABEL=ubuntu

kernel /boot/vmlinuz-2.6.24-23-generic

initrd /boot/initrd.img-2.6.24-23-generic

cmdline root=UUID=2bbadde7-2464-4276-ae55-a1c5079c3e12 ro quiet splash



#working

title Ubuntu 8.04.2, kernel 2.6.24-23-generic - sda3

root /dev/sda3

kernel /boot/vmlinuz-2.6.24-23-generic

initrd /boot/initrd.img-2.6.24-23-generic

cmdline root=UUID=2bbadde7-2464-4276-ae55-a1c5079c3e12 ro quiet splash



#working

# Boot this floppy (For debugging)

title	kexec-loader

root	LABEL=kexecloader

kernel	/linux.upx

error message: http://img26.imagesh...98260763kq2.png

error reason: http://img201.images...12525533xg1.png

grub-path goes into action before all partitions are detected. Therefore I can not inherit form my original menu.lst in (sda3)/boot/grub/menu.lst.

#27 mr_

mr_

    Frequent Member

  • Members
  • 355 posts
  •  
    Germany

Posted 08 February 2009 - 04:49 PM

You will need to compile a kernel with CD and ISO support, the modules are no use since you need to be able to mount the CD to load the modules :poke:
Once you've done that, kexec-loader searches for a disk with the volume name 'kexecloader' to use as the boot disk


A "stripped down" and a "full bown" version seems to me like a good compromise. :poke:

People wanting "intermediate" builds may well work their way to build them. :poke:

jaclaz


Now I have a even other idea to solve this "which BIOS boot devices should be supported" thing.

Basically I can not use a superfloppy with kexec and boot it with grub4dos because linux will try to read the floppy without BIOS and it's own driver. (there is none)

Could solemnwarning write a linux kernel driver which is able to takeover the virtual (super)floppy? I have no idea how hard this would be for a programmer.

After the linux kernel driver for virtual floppy disks is done there will be no need for anything, but a floppy and superfloppy version.
- a harddisk version would never be needed
- a iso version would never be needed
- no need to support any other boot medium supported by BIOS/grub4dos
- grub4dos could be used as bootloader in a iso and emulate the kexec-bootloader-superfloppy image

#28 solemnwarning

solemnwarning

    Member

  • Members
  • 73 posts
  •  
    United Kingdom

Posted 08 February 2009 - 04:51 PM

error message: http://img26.imagesh...98260763kq2.png

error reason: http://img201.images...12525533xg1.png

grub-path goes into action before all partitions are detected. Therefore I can not inherit form my original menu.lst in (sda3)/boot/grub/menu.lst.


There's not much I can do about that, I don't think there's any way of identifying when Linux has detected all devices, all I can do is add a directive to wait X seconds after loading stuff from boot floppy.

#29 mr_

mr_

    Frequent Member

  • Members
  • 355 posts
  •  
    Germany

Posted 08 February 2009 - 04:57 PM

all I can do is add a directive to wait X seconds after loading stuff from boot floppy.

Yes, this would help.

And/or grub-path as shell command for kexec-loader.conf, I could simply tell kexec-loader to try again and again until the kernel is done.

#30 solemnwarning

solemnwarning

    Member

  • Members
  • 73 posts
  •  
    United Kingdom

Posted 08 February 2009 - 04:58 PM

Could solemnwarning write a linux kernel driver which is able to takeover the virtual (super)floppy? I have no idea how hard this would be for a programmer.


You mean a floppy driver which accesses the floppy through INT13h instead of directly accessing it? I doubt it, I'm not a kernel developer.

#31 mr_

mr_

    Frequent Member

  • Members
  • 355 posts
  •  
    Germany

Posted 08 February 2009 - 05:05 PM

You mean a floppy driver which accesses the floppy through INT13h instead of directly accessing it?

Yes.

Either this or directly taking over the virtual floppy from memory.

Both implementation styles would have advantages and disadvantages. The BIOS call way would provide support for any emulated device, like Windows 9x still had a compatibility mode, that's what we are missing now in WinNT and Linux.

#32 solemnwarning

solemnwarning

    Member

  • Members
  • 73 posts
  •  
    United Kingdom

Posted 08 February 2009 - 06:48 PM

OK, I've updated the GRUB loading code to use the same mount method as the boot disk, in other words it will wait until there is a disk matching that in grub-path instead of only trying once.

#33 solemnwarning

solemnwarning

    Member

  • Members
  • 73 posts
  •  
    United Kingdom

Posted 12 February 2009 - 12:17 AM

I've moved the rewrite branch to trunk, there's unlikely to be any more changes apart from bugfixes and doc updates
Here's a new disk image!

kexec-loader-r487-floppy.img.gz

#34 mr_

mr_

    Frequent Member

  • Members
  • 355 posts
  •  
    Germany

Posted 12 February 2009 - 03:07 PM

Error loading 'jdb': invalid module format

I am still using http://www.solemnwar...2.6.25-1.tar.gz which worked with the release before.

Which modules must be used now?

#35 solemnwarning

solemnwarning

    Member

  • Members
  • 73 posts
  •  
    United Kingdom

Posted 12 February 2009 - 03:45 PM

Error loading 'jdb': invalid module format

I am still using http://www.solemnwar...2.6.25-1.tar.gz which worked with the release before.

Which modules must be used now?


The nightly images are still built using 2.6.13-1, as shown by the Linux version

#36 mr_

mr_

    Frequent Member

  • Members
  • 355 posts
  •  
    Germany

Posted 12 February 2009 - 04:13 PM

http://img17.imagesh...12171235zj6.png

How comes this error then?

How to fix?

#37 solemnwarning

solemnwarning

    Member

  • Members
  • 73 posts
  •  
    United Kingdom

Posted 12 February 2009 - 05:13 PM

http://img17.imagesh...12171235zj6.png

How comes this error then?

How to fix?


Use the 2.6.13-1 modules package...

#38 was_jaclaz

was_jaclaz

    Finder

  • Advanced user
  • 7100 posts
  • Location:Gone in the mist
  •  
    Italy

Posted 17 February 2009 - 08:47 AM

New version here:
http://www.boot-land...?showtopic=7124

Thread closed for good.

jaclaz




0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users