/[gentoo]/xml/htdocs/doc/en/gentoo-x86-tipsntricks.xml
Gentoo

Contents of /xml/htdocs/doc/en/gentoo-x86-tipsntricks.xml

Parent Directory Parent Directory | Revision Log Revision Log


Revision 1.1 - (show annotations) (download) (as text)
Sun Apr 11 14:37:39 2004 UTC (10 years, 3 months ago) by swift
Branch: MAIN
File MIME type: application/xml
#44273 - Adding Software RAID to Tips n Tricks document for installations

1 <?xml version='1.0' encoding="UTF-8"?>
2 <!DOCTYPE guide SYSTEM "/dtd/guide.dtd">
3
4 <guide link="/doc/en/gentoo-x86-tipsntricks.xml">
5 <title>Gentoo/x86 Installation Tips &amp; Tricks</title>
6 <author title="Author">
7 <mail link="swift@gentoo.org">Sven Vermeulen</mail>
8 </author>
9
10 <abstract>
11 The Gentoo installation allows for very flexible approaches to the various
12 installation methods. As it is almost impossible to insert every single tip or
13 trick in the installation instructions this document tries to deal with all
14 submitted tips and tricks for reference purposes.
15 </abstract>
16
17 <license/>
18
19 <version>1.0</version>
20 <date>April 11, 2004</date>
21
22 <chapter>
23 <title>Introduction</title>
24 <section>
25 <title>Preliminary</title>
26 <body>
27
28 <p>
29 This document contains various tips and tricks for the Gentoo/x86 installation.
30 Most of them are discussed in a dense way - they are meant as an addendum to the
31 installation instructions and not as a replacement.
32 </p>
33
34 </body>
35 </section>
36 <section>
37 <title>Contents</title>
38 <body>
39
40 <ul>
41 <li><uri link="#software-raid">Software RAID</uri></li>
42 </ul>
43
44 </body>
45 </section>
46 </chapter>
47 <chapter>
48 <title>Advanced Installations</title>
49 <section id="software-raid">
50 <title>Software RAID</title>
51 <body>
52
53 <note>
54 If you are not known to software raid, please read the <uri
55 link="http://tldp.org/HOWTO/Software-RAID-HOWTO.html">Software-RAID-HOWTO</uri>.
56 </note>
57
58 <p>
59 Once you are booted from the LiveCD, load the appropriate RAID modules. For
60 instance, if you plan on using RAID-1:
61 </p>
62
63 <pre caption="Loading the RAID-1 module">
64 # <i>modprobe raid1</i>
65 </pre>
66
67 <p>
68 When you partition your disks, make sure that your partitions use <c>fd</c>
69 (Linux raid autodetect) as Partition Type instead of <c>83</c> (Linux native).
70 You can alter the partition type using the <c>t</c> command in <c>fdisk</c>.
71 </p>
72
73 <p>
74 After partitioning, create the <path>/etc/raidtab</path> file (yes, indeed, on
75 the LiveCD environment) and insert the necessary commands for your RAID setup.
76 For instance, to have your boot, swap and root partition mirrored (RAID-1)
77 covering <path>/dev/sda</path> and <path>/dev/sdb</path>, you can use:
78 </p>
79
80 <pre caption="/etc/raidtab for RAID-1 setup">
81 raiddev /dev/md0
82 raid-level 1
83 nr-raid-disks 2
84 chunk-size 32
85 persistent-superblock 1
86 device /dev/sda1
87 raid-disk 0
88 device /dev/sdb1
89 raid-disk 1
90
91 raiddev /dev/md1
92 raid-level 1
93 nr-raid-disks 2
94 chunk-size 32
95 persistent-superblock 1
96 device /dev/sda2
97 raid-disk 0
98 device /dev/sdb2
99 raid-disk 1
100
101 raiddev /dev/md2
102 raid-level 1
103 nr-raid-disks 2
104 chunk-size 32
105 persistent-superblock 1
106 device /dev/sda3
107 raid-disk 0
108 device /dev/sdb3
109 raid-disk 1
110 </pre>
111
112 <p>
113 Now create the necessary RAID devices for each RAID device you listed in
114 <path>/etc/raidtab</path>:
115 </p>
116
117 <pre caption="Creating RAID devices">
118 # <i>mkraid /dev/md0</i>
119 # <i>mkraid /dev/md1</i>
120 # <i>mkraid /dev/md2</i>
121 </pre>
122
123 <p>
124 The Linux Software RAID driver will start creating the metadevices. You can see
125 its progress in <path>/proc/mdstat</path>. Wait until the metadevices are
126 completely finished before proceeding.
127 </p>
128
129 <p>
130 From now onwards, use <path>/dev/md0</path> for the boot partition,
131 <path>/dev/md1</path> for the swap partition and <path>/dev/md2</path> for the
132 root partition.
133 </p>
134
135 <p>
136 After mounting <path>/dev/md2</path> on <path>/mnt/gentoo</path>, don't forget
137 to copy over <path>/etc/raidtab</path> to <path>/mnt/gentoo/etc</path>.
138 </p>
139
140 <p>
141 When you're configuring your kernel, make sure you have the appropriate RAID
142 support <e>in</e> your kernel and not as module.
143 </p>
144
145 <p>
146 When installing extra tools, emerge <c>raidtools</c> as well. Note that this
147 isn't available on all LiveCDs so you might not be able to install Gentoo on a
148 Software RAID when using a networkless installation!
149 </p>
150
151 <p>
152 When configuring your bootloader, make sure it gets installed in the MBR of
153 <e>both</e> disks if you use mirroring.
154 </p>
155
156 </body>
157 </section>
158 </chapter>
159 </guide>

  ViewVC Help
Powered by ViewVC 1.1.20