summaryrefslogtreecommitdiff
path: root/en/install-methods/usb-setup/x86.xml
blob: 50f2d51ae419ce06d734f908fd18f2f081224d72 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
<!-- retain these comments for translator revision tracking -->
<!-- $Id$ -->

   <sect3 arch="x86">
   <title>USB stick partitioning on &arch-title;</title>
<para>

We will show how to setup the memory stick to use the first partition,
instead of the entire device.

</para><note><para>

Since most USB sticks come pre-configured with a single FAT16
partition, you probably won't have to repartition or reformat the
stick.  If you have to do that anyway, use <command>cfdisk</command>
or any other partitioning tool to create a FAT16 partition, and then
create the filesystem using:

<informalexample><screen>
# mkdosfs /dev/<replaceable>sda1</replaceable>
</screen></informalexample>

Take care that you use the correct device name for your USB stick. The
<command>mkdosfs</command> command is contained in the
<classname>dosfstools</classname> Debian package.

</para></note><para>

In order to start the kernel after booting from the USB stick, we will
put a boot loader on the stick. Although any boot loader
(e.g. <command>LILO</command>) should work, it's convenient to use
<command>SYSLINUX</command>, since it uses a FAT16 partition and can
be reconfigured by just editing a text file. Any operating system
which supports the FAT file system can be used to make changes to the
configuration of the boot loader.

</para><para>

To put <command>SYSLINUX</command> on the FAT16 partition on your USB
stick, install the <classname>syslinux</classname> and
<classname>mtools</classname> packages on your system, and do:

<informalexample><screen>
# syslinux /dev/<replaceable>sda1</replaceable>
</screen></informalexample>

Again, take care that you use the correct device name. The partition
must not be mounted when starting <command>SYSLINUX</command>. This
procedure writes a boot sector to the partition and creates the file
<filename>ldlinux.sys</filename> which contains the boot loader code.

</para><para>

Mount the partition (<userinput>mount /dev/sda1 /mnt</userinput>) and
copy the following files from the Debian archives to the stick:

<itemizedlist>
<listitem><para>

<filename>vmlinuz</filename> (kernel binary)

</para></listitem>
<listitem><para>

<filename>initrd.gz</filename> (initial ramdisk image)

</para></listitem>
<listitem><para>

<filename>syslinux.cfg</filename> (SYSLINUX configuration file)

</para></listitem>
<listitem><para>

Optional kernel modules

</para></listitem>
</itemizedlist>

If you want to rename the files, please note that
<command>SYSLINUX</command> can only process DOS (8.3) file names.

</para><para>

The <filename>syslinux.cfg</filename> configuration file should
contain the following two lines:

<informalexample><screen>
default vmlinuz
append initrd=initrd.gz
</screen></informalexample>

</para>
   </sect3>