Merge branch 'syslinux-3.7x'
[profile/ivi/syslinux.git] / doc / extlinux.txt
1 EXTLINUX is a new Syslinux derivative, which boots from a Linux
2 ext2/ext3 filesystem.
3
4 It works the same way as SYSLINUX (see doc/syslinux.txt), with a few
5 slight modifications.
6
7 1. The installer is run on a *mounted* filesystem.  Run the extlinux
8    installer on the directory in which you want extlinux installed:
9
10         extlinux --install /boot
11
12    Specify --install (-i) to install for the first time, or
13    --update (-U) to upgrade a previous installation.
14
15    NOTE: this doesn't have to be the root directory of a filesystem.
16    If /boot is a filesystem, you can do:
17
18         mkdir -p /boot/extlinux
19         extlinux --install /boot/extlinux
20
21    ... to create a subdirectory and install extlinux in it.
22    /boot/extlinux is the recommended location for extlinux.
23
24
25 2. The configuration file is called "extlinux.conf", and is expected
26    to be found in the same directory as extlinux is installed in.
27
28
29 3. Pathnames can be absolute or relative; if absolute (with a leading
30    slash), they are relative to the root of the filesystem on which
31    extlinux is installed (/boot in the example above), if relative,
32    they are relative to the extlinux directory.
33
34    extlinux supports subdirectories, but the total path length is
35    limited to 511 characters.
36
37
38 4. EXTLINUX now supports symbolic links.  However, extremely long
39    symbolic links might hit the pathname limit.  Also, please note
40    that absolute symbolic links are interpreted from the root *of the
41    filesystem*, which might be different from how the running system
42    would interpret it (e.g. in the case of a separate /boot
43    partition.)  Therefore, use relative symbolic links if at all
44    possible.
45
46
47 5. EXTLINUX now has "boot-once" support.  The boot-once information is
48    stored in an on-disk datastructure, part of extlinux.sys, called
49    the "Auxillary Data Vector".  The Auxilliary Data Vector is also
50    available to COMBOOT/COM32 modules that want to store small amounts
51    of information.
52
53    To set the boot-once information, do:
54
55         extlinux --once 'command' /boot/extlinux
56
57    where 'command' is any command you could enter at the Syslinux
58    command line.  It will be executed on the next boot and then
59    erased.
60
61    To clear the boot-once information, do:
62
63         extlinux --clear-once /boot/extlinux
64
65    If EXTLINUX is used on a RAID-1, this is recommended, since under
66    certain circumstances a RAID-1 rebuild can "resurrect" the
67    boot-once information otherwise.
68
69    To clear the entire Auxillary Data Vector, do:
70
71         extlinux --reset-adv /boot/extlinux
72
73    This will erase all data stored in the ADV, including boot-once.
74
75    The --once, --clear-once, and --reset-adv commands can be combined
76    with --install or --update, if desired.  The ADV is preserved
77    across updates, unless --reset-adv is specified.
78
79
80 Note that EXTLINUX installs in the filesystem partition like a
81 well-behaved bootloader :)  Thus, it needs a master boot record in the
82 partition table; the mbr.bin shipped with Syslinux should work well.
83 To install it just do:
84
85         cat mbr.bin > /dev/XXX
86
87 ... where /dev/XXX is the appropriate master device, e.g. /dev/hda,
88 and make sure the correct partition in set active.
89
90
91 If you have multiple disks in a software RAID configuration, the
92 preferred way to boot is:
93
94 - Create a separate RAID-1 partition for /boot.  Note that the Linux
95   RAID-1 driver can span as many disks as you wish.
96
97 - Install the MBR on *each disk*, and mark the RAID-1 partition
98   active.
99
100 - Run "extlinux -i /boot" to install extlinux.  This will install it on
101   all the drives in the RAID-1 set, which means you can boot any
102   combination of drives in any order.
103
104
105
106 It is not required to re-run the extlinux installer after installing
107 new kernels.  If you are using ext3 journalling, however, it might be
108 desirable to do so, since running the extlinux installer will flush
109 the log.  Otherwise a dirty shutdown could cause some of the new
110 kernel image to still be in the log.  This is a general problem for
111 boot loaders on journalling filesystems; it is not specific to
112 extlinux.  The "sync" command does not flush the log on the ext3
113 filesystem.
114
115
116 The Syslinux Project boot loaders support chain loading other
117 operating systems via a separate module, chain.c32 (located in
118 com32/modules/chain.c32).  To use it, specify a LABEL in the
119 configuration file with KERNEL chain.c32 and APPEND [hd|fd]<number>
120 [<partition>]
121
122 For example:
123
124 # Windows CE/ME/NT, a very dense operating system.
125 # Second partition (2) on the first hard disk (hd0);
126 # Linux would *typically* call this /dev/hda2 or /dev/sda2.
127 LABEL cement
128         KERNEL chain.c32
129         APPEND hd0 2
130
131 See also doc/menu.txt.
132