Difference between revisions of "Comboot/chain.c32"

From Syslinux Wiki
Jump to: navigation, search
(New page: ( Included in syslinux 3.71 ) (from chain.c comment) Chainload a hard disk (currently rather braindead.) <pre> Usage: chain hd<disk#> [<partition>] [options] chain fd<disk#> [op...)
 
(only format)
Line 20: Line 20:
 
   
 
   
 
Options:
 
Options:
* <tt>file=<loader></tt>: loads the file <loader> **from the SYSLINUX filesystem** instead of loading the boot sector.
+
* <tt>file=<loader></tt>: loads the file ''<loader>'' **from the SYSLINUX filesystem** instead of loading the boot sector.
* <tt>seg=<segment></tt>: loads at and jumps to <seg>:0000 instead of 0000:7C00.
+
* <tt>seg=<segment></tt>: loads at and jumps to ''<seg>:0000'' instead of ''0000:7C00''.
* <tt>ntldr=<loader></tt>: equivalent to -seg 0x2000 -file <loader>, used with WinNT's loaders
+
* <tt>ntldr=<loader></tt>: equivalent to ''-seg 0x2000 -file <loader>'', used with WinNT's loaders
* <tt>freedos=<loader></tt>: equivalent to -seg 0x60 -file <loader>, used with FreeDOS kernel.sys.
+
* <tt>freedos=<loader></tt>: equivalent to ''-seg 0x60 -file <loader>'', used with FreeDOS ''kernel.sys''.
 
* <tt>msdos=<loader></tt>:  
 
* <tt>msdos=<loader></tt>:  
* <tt>pcdos=<loader></tt>: equivalent to -seg 0x70 -file <loader>, used with DOS' io.sys.
+
* <tt>pcdos=<loader></tt>: equivalent to ''-seg 0x70 -file <loader>'', used with DOS ''io.sys''.
 
* <tt>swap</tt>: if the disk is not fd0/hd0, install a BIOS stub which swaps the drive numbers.
 
* <tt>swap</tt>: if the disk is not fd0/hd0, install a BIOS stub which swaps the drive numbers.
* <tt>hide</tt>: change type of primary partitions with IDs 01, 04, 06, 07, 0b, 0c, or 0e to 1x, except for the selected partition, which is converted the other way.
+
* <tt>hide</tt>: change type of primary partitions with IDs ''01, 04, 06, 07, 0b, 0c, or 0e to 1x'', except for the selected partition, which is converted the other way.

Revision as of 09:02, 26 June 2009

( Included in syslinux 3.71 )

(from chain.c comment)


Chainload a hard disk (currently rather braindead.)

Usage: chain hd<disk#> [<partition>] [options]
       chain fd<disk#> [options]
       chain mbr:<id> [<partition>] [options]
       chain boot [<partition>] [options]

... e.g. "chain hd0 1" will boot the first partition on the first hard disk.


The mbr: syntax means search all the hard disks until one with a specific MBR serial number (bytes 440-443) is found.

Partitions 1-4 are primary, 5+ logical, 0 = boot MBR (default.)

Options:

  • file=<loader>: loads the file <loader> **from the SYSLINUX filesystem** instead of loading the boot sector.
  • seg=<segment>: loads at and jumps to <seg>:0000 instead of 0000:7C00.
  • ntldr=<loader>: equivalent to -seg 0x2000 -file <loader>, used with WinNT's loaders
  • freedos=<loader>: equivalent to -seg 0x60 -file <loader>, used with FreeDOS kernel.sys.
  • msdos=<loader>:
  • pcdos=<loader>: equivalent to -seg 0x70 -file <loader>, used with DOS io.sys.
  • swap: if the disk is not fd0/hd0, install a BIOS stub which swaps the drive numbers.
  • hide: change type of primary partitions with IDs 01, 04, 06, 07, 0b, 0c, or 0e to 1x, except for the selected partition, which is converted the other way.