/[gentoo]/xml/htdocs/doc/en/handbook/hb-install-ppc-disk.xml
Gentoo

Diff of /xml/htdocs/doc/en/handbook/hb-install-ppc-disk.xml

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

Revision 1.37 Revision 1.38
2<!DOCTYPE sections SYSTEM "/dtd/book.dtd"> 2<!DOCTYPE sections SYSTEM "/dtd/book.dtd">
3 3
4<!-- The content of this document is licensed under the CC-BY-SA license --> 4<!-- The content of this document is licensed under the CC-BY-SA license -->
5<!-- See http://creativecommons.org/licenses/by-sa/2.5 --> 5<!-- See http://creativecommons.org/licenses/by-sa/2.5 -->
6 6
7<!-- $Header: /var/cvsroot/gentoo/xml/htdocs/doc/en/handbook/hb-install-ppc-disk.xml,v 1.37 2006/11/02 20:49:38 nightmorph Exp $ --> 7<!-- $Header: /var/cvsroot/gentoo/xml/htdocs/doc/en/handbook/hb-install-ppc-disk.xml,v 1.38 2007/05/07 18:11:41 nightmorph Exp $ -->
8 8
9<sections> 9<sections>
10 10
11<version>7.1</version> 11<version>8.0</version>
12<date>2006-11-02</date> 12<date>2007-05-07</date>
13 13
14<section> 14<section>
15<title>Introduction to Block Devices</title> 15<title>Introduction to Block Devices</title>
16<subsection> 16<subsection>
17<title>Block Devices</title> 17<title>Block Devices</title>
18<body> 18<body>
19 19
20<p> 20<p>
21We'll take a good look at disk-oriented aspects of Gentoo Linux 21We'll start by taking a good look at disk-oriented aspects of Gentoo Linux
22and Linux in general, including Linux filesystems, partitions and block devices. 22and Linux in general, including Linux filesystems, partitions and block devices.
23Then, once you're familiar with the ins and outs of disks and filesystems, 23Then, once you're familiar with the ins and outs of disks and filesystems,
24you'll be guided through the process of setting up partitions and filesystems 24you'll be guided through the process of setting up partitions and filesystems
25for your Gentoo Linux installation. 25for your Gentoo Linux installation.
26</p> 26</p>
27 27
28<p> 28<p>
29To begin, we'll introduce <e>block devices</e>. The most common block device is 29To begin, we'll introduce <e>block devices</e>. The most common block device is
30the one that represents the first IDE drive in a Linux system, namely 30the one that represents the first IDE drive in a Linux system, namely
31<path>/dev/hda</path>. If you are installing onto SCSI, FireWire, USB or SATA 31<path>/dev/hda</path>. If you are installing onto SCSI, FireWire, USB or SATA
32drives, then your first hard drive would be <path>/dev/sda</path>. 32drives, then your first hard drive would be <path>/dev/sda</path>. Additional
33drives are enumerated by the next letter in the alphabet. As an example, the
34third IDE disk could be found at <path>/dev/hdc</path>.
33</p> 35</p>
34 36
35<p> 37<p>
36The block devices above represent an abstract interface to the disk. User 38The block devices above represent an abstract interface to the disk. User
37programs can use these block devices to interact with your disk without worrying 39programs can use these block devices to interact with the disk without worrying
38about whether your drives are IDE, SCSI or something else. The program can 40about whether the drives are IDE, SCSI or something else. The program can
39simply address the storage on the disk as a bunch of contiguous, 41simply address the storage on the disk as a bunch of contiguous,
40randomly-accessible 512-byte blocks. 42randomly-accessible 512-byte blocks.
41</p> 43</p>
42 44
43</body> 45</body>
62<title>Default Partitioning Scheme</title> 64<title>Default Partitioning Scheme</title>
63<body> 65<body>
64 66
65<p> 67<p>
66If you are not interested in drawing up a partitioning scheme for your system, 68If you are not interested in drawing up a partitioning scheme for your system,
67you can use the partitioning scheme we use throughout this book: 69you can use the partitioning scheme we use throughout this book. Choose the
70filesystem layout that best matches the type of PowerPC system you are
71installing on.
72</p>
73
74</body>
75</subsection>
76<subsection>
77<title>Apple New World</title>
78<body>
79
80<p>
81Apple New World machines are fairly straightforward to configure. The first
82partition is always an <e>Apple Partition Map</e>. This partition keeps track
83of the layout of the disk. You cannot remove this partition. The next
84partition should always be a bootstrap partition. This partition contains a
85small (800k) HFS filesystem that holds a copy of the bootloader Yaboot and its
86configuration file. This partition is <e>not</e> the same as a
87<path>/boot</path> partition as found on other architectures. After the boot
88partition, the usual Linux filesystems are placed, according to the scheme
89below. The swap partition is a temporary storage place for when your system
90runs out of physical memory. The root partition will contain the filesystem
91that Gentoo is installed on. If you wish to dual boot, the OSX partition
92can go anywhere after the bootstrap partition to insure that yaboot starts
93first.
94</p>
95
96<note>
97There may be "Disk Driver" partitions on your disk such as <path>Apple_Driver63,
98Apple_Driver_ATA, Apple_FWDriver, Apple_Driver_IOKit, Apple_Patches</path>.
99These are used to boot MacOS, so if you have no need for this, you can remove
100them by initializing the disk with mac-fdisk's <c>i</c> option. This will
101completely erase the disk! If you are in doubt, just let them be.
102</note>
103
104<note>
105If you partitioned this disk with Apple's Disk Utility, there may be
106128Mb spaces between partitions which Apple reserves for "future use". You
107can safely remove these.
108</note>
109
110<table>
111<tr>
112 <th>Partition</th>
113 <th>Size</th>
114 <th>Filesystem</th>
115 <th>Description</th>
116</tr>
117<tr>
118 <ti><path>/dev/hda1</path></ti>
119 <ti>32k</ti>
120 <ti>None</ti>
121 <ti>Apple Partition Map</ti>
122</tr>
123<tr>
124 <ti><path>/dev/hda2</path></ti>
125 <ti>800k</ti>
126 <ti>HFS</ti>
127 <ti>Apple Bootstrap</ti>
128</tr>
129<tr>
130 <ti><path>/dev/hda3</path></ti>
131 <ti>512Mb</ti>
132 <ti>Swap</ti>
133 <ti>Linux Swap</ti>
134</tr>
135<tr>
136 <ti><path>/dev/hda4</path></ti>
137 <ti>Rest of Disk</ti>
138 <ti>ext3, reiserfs, xfs</ti>
139 <ti>Linux Root</ti>
140</tr>
141</table>
142
143</body>
144</subsection>
145<subsection>
146<title>Apple Old World</title>
147<body>
148
149<p>
150Apple Old World machines are a bit more complicated to configure. The first
151partition is always an <e>Apple Partition Map</e>. This partition keeps track
152of the layout of the disk. You cannot remove this partition. If you are using
153BootX, the configuration below assumes that MacOS is installed on a seperate
154disk. If this is not the case, there will be additional partitions for "Apple
155Disk Drivers" such as <path>Apple_Driver63, Apple_Driver_ATA, Apple_FWDriver,
156Apple_Driver_IOKit, Apple_Patches</path> and the MacOS install. If you are
157using Quik, you will need to create a boot partition to hold the kernel, unlike
158other Apple boot methods. After the boot partition, the usual Linux filesystems
159are placed, according to the scheme below. The swap partition is a temporary
160storage place for when your system runs out of physical memory. The root
161partition will contain the filesystem that Gentoo is installed on.
68</p> 162</p>
69 163
70<note> 164<note>
71If you are using an OldWorld machine, you will need to keep MacOS available. 165If you are using an OldWorld machine, you will need to keep MacOS available.
72The layout here assumes MacOS is installed on a separate drive. 166The layout here assumes MacOS is installed on a separate drive.
73</note> 167</note>
74 168
75<table> 169<table>
76<tr> 170<tr>
77 <th>Partition NewWorld</th>
78 <th>Partition OldWorld</th>
79 <th>Partition Pegasos</th> 171 <th>Partition</th>
80 <th>Partition RS/6000</th> 172 <th>Size</th>
81 <th>Filesystem</th> 173 <th>Filesystem</th>
174 <th>Description</th>
175</tr>
176<tr>
177 <ti><path>/dev/hda1</path></ti>
178 <ti>32k</ti>
179 <ti>None</ti>
180 <ti>Apple Partition Map</ti>
181</tr>
182<tr>
183 <ti><path>/dev/hda2</path></ti>
184 <ti>32Mb</ti>
185 <ti>ext2</ti>
186 <ti>Quik Boot Partition (quik only)</ti>
187</tr>
188<tr>
189 <ti><path>/dev/hda3</path></ti>
190 <ti>512Mb</ti>
191 <ti>Swap</ti>
192 <ti>Linux Swap</ti>
193</tr>
194<tr>
195 <ti><path>/dev/hda4</path></ti>
196 <ti>Rest of Disk</ti>
197 <ti>ext3, reiserfs, xfs</ti>
198 <ti>Linux Root</ti>
199</tr>
200</table>
201
202</body>
203</subsection>
204<subsection>
205<title>Pegasos</title>
206<body>
207
208<p>
209The Pegaos partition layout is quite simple compared to the Apple layouts.
210The first partition is a Boot Partition, which contains kernels to be booted,
211along with an OpenFirmware script that presents a menu on boot. After the boot
212partition, the usual Linux filesystems are placed, according to the scheme
213below. The swap partition is a temporary storage place for when your system
214runs out of physical memory. The root partition will contain the filesystem
215that Gentoo is installed on.
216</p>
217
218<table>
219<tr>
220 <th>Partition</th>
82 <th>Size</th> 221 <th>Size</th>
222 <th>Filesystem</th>
83 <th>Description</th> 223 <th>Description</th>
84</tr> 224</tr>
85<tr> 225<tr>
86 <ti><path>/dev/hda1</path></ti> 226 <ti><path>/dev/hda1</path></ti>
227 <ti>32Mb</ti>
228 <ti>affs1 or ext2</ti>
229 <ti>Boot Partition</ti>
230</tr>
231<tr>
232 <ti><path>/dev/hda2</path></ti>
233 <ti>512Mb</ti>
234 <ti>Swap</ti>
235 <ti>Linux Swap</ti>
236</tr>
237<tr>
238 <ti><path>/dev/hda3</path></ti>
239 <ti>Rest of Disk</ti>
240 <ti>ext3, reiserfs, xfs</ti>
241 <ti>Linux Root</ti>
242</tr>
243</table>
244
245</body>
246</subsection>
247<subsection>
248<title>IBM PReP (RS/6000)</title>
249<body>
250
251<p>
252The Pegaos partition layout is quite simple compared to the Apple layouts.
253The first partition is a Boot Partition, which contains kernels to be booted,
254along with an OpenFirmware script that presents a menu on boot. After the boot
255partition, the usual Linux filesystems are placed, according to the scheme
256below. The swap partition is a temporary storage place for when your system
257runs out of physical memory. The root partition will contain the filesystem
258that Gentoo is installed on.
259</p>
260
261<table>
262<tr>
263 <th>Partition</th>
264 <th>Size</th>
265 <th>Filesystem</th>
266 <th>Description</th>
267</tr>
268<tr>
87 <ti><path>/dev/hda1</path></ti> 269 <ti><path>/dev/hda1</path></ti>
88 <ti>(Not applicable)</ti>
89 <ti>(Not applicable)</ti>
90 <ti>(Partition Map)</ti>
91 <ti>32k</ti> 270 <ti>800k</ti>
92 <ti>Apple_partition_map</ti> 271 <ti>None</ti>
272 <ti>PReP Boot Partition (Type 0x41)</ti>
93</tr> 273</tr>
94<tr> 274<tr>
95 <ti><path>/dev/hda2</path></ti> 275 <ti><path>/dev/hda2</path></ti>
96 <ti>(Not needed)</ti>
97 <ti>(Not applicable)</ti>
98 <ti>(Not applicable)</ti>
99 <ti>(bootstrap)</ti>
100 <ti>800k</ti>
101 <ti>Apple_Bootstrap</ti>
102</tr>
103<tr>
104 <ti>(Not applicable)</ti>
105 <ti>(Not applicable)</ti>
106 <ti>(Not applicable)</ti>
107 <ti><path>/dev/sda1</path></ti>
108 <ti>(PReP Boot)</ti>
109 <ti>800k</ti>
110 <ti>Type 0x41</ti>
111</tr>
112<tr>
113 <ti>(Not applicable)</ti>
114 <ti><path>/dev/hda2</path> (If using quik)</ti>
115 <ti><path>/dev/hda1</path></ti>
116 <ti>(Not applicable)</ti>
117 <ti>ext2</ti>
118 <ti>32MB</ti> 276 <ti>512Mb</ti>
119 <ti>Boot partition</ti> 277 <ti>Swap</ti>
278 <ti>Linux Swap (Type 0x82)</ti>
120</tr> 279</tr>
121<tr> 280<tr>
122 <ti><path>/dev/hda3</path></ti> 281 <ti><path>/dev/hda3</path></ti>
123 <ti><path>/dev/hda2</path> (<path>/dev/hda3</path> if using quik)</ti>
124 <ti><path>/dev/hda2</path></ti>
125 <ti><path>/dev/sda2</path></ti>
126 <ti>(swap)</ti>
127 <ti>512M</ti>
128 <ti>Swap partition, Type 0x82</ti>
129</tr>
130<tr>
131 <ti><path>/dev/hda4</path></ti>
132 <ti><path>/dev/hda3</path> (<path>/dev/hda4</path> if using quik)</ti>
133 <ti><path>/dev/hda3</path></ti>
134 <ti><path>/dev/sda3</path></ti>
135 <ti>ext3, xfs</ti>
136 <ti>Rest of the disk</ti> 282 <ti>Rest of Disk</ti>
137 <ti>Root partition, Type 0x83</ti> 283 <ti>ext3, reiserfs, xfs</ti>
284 <ti>Linux Root (Type 0x83)</ti>
138</tr> 285</tr>
139</table> 286</table>
140 287
141<note>
142There are some partitions named: <path>Apple_Driver63, Apple_Driver_ATA,
143Apple_FWDriver, Apple_Driver_IOKit, Apple_Patches</path>. If you are not
144planning to use MacOS 9 you can delete them, because MacOS X and Linux don't
145need them. To delete them, either use parted or erase the whole disk by
146initializing the partition map.
147</note>
148
149<warn> 288<warn>
150<c>parted</c> is able to resize partitions including HFS+. Unfortunately it is 289<c>parted</c> is able to resize partitions including HFS+. Unfortunately there
151not possible to resize HFS+ journaled filesystems, so switch off journaling in 290may be issues with resizing HFS+ journaled filesystems, so, for the best
152Mac OS X before resizing. Remember that any resizing operation is dangerous, 291results, switch off journaling in Mac OS X before resizing. Remember that any
153so attempt at your own risk! Be sure to always have a backup of your data 292resizing operation is dangerous, so attempt at your own risk! Be sure to always
154before resizing! 293have a backup of your data before resizing!
155</warn> 294</warn>
156 295
157<p> 296<p>
158If you are interested in knowing how big a partition should be, or even how many 297If you are interested in knowing how big a partition should be, or even how many
159partitions you need, read on. Otherwise continue now with 298partitions you need, read on. Otherwise continue now with
171<p> 310<p>
172The number of partitions is highly dependent on your environment. For instance, 311The number of partitions is highly dependent on your environment. For instance,
173if you have lots of users, you will most likely want to have your 312if you have lots of users, you will most likely want to have your
174<path>/home</path> separate as it increases security and makes backups easier. 313<path>/home</path> separate as it increases security and makes backups easier.
175If you are installing Gentoo to perform as a mailserver, your <path>/var</path> 314If you are installing Gentoo to perform as a mailserver, your <path>/var</path>
176should be separate as all mails are stored inside <path>/var</path>. A good 315should be separate as all received mail is stored in <path>/var</path>. A good
177choice of filesystem will then maximise your performance. Gameservers will have 316choice of filesystem will then maximise your performance. Game servers should
178a separate <path>/opt</path> as most gaming servers are installed there. The 317have a separate <path>/opt</path> as most game servers are installed there. The
179reason is similar for <path>/home</path>: security and backups. You will 318reason is similar for <path>/home</path>: security and backups. Whatever layout
180definitely want to keep <path>/usr</path> big: not only will it contain the 319you chose, you will definitely want to keep <path>/usr</path> large: not only
181majority of applications, the Portage tree alone takes around 500 Mbyte 320will it contain the majority of applications, the Portage tree alone takes
182excluding the various sources that are stored in it. 321more than 500Mb excluding the various sources that are stored in it.
183</p> 322</p>
184 323
185<p> 324<p>
186As you can see, it very much depends on what you want to achieve. Separate 325As you can see, it very much depends on what you want to achieve. Separate
187partitions or volumes have the following advantages: 326partitions or volumes have the following advantages:
227<pre caption="Starting mac-fdisk"> 366<pre caption="Starting mac-fdisk">
228# <i>mac-fdisk /dev/hda</i> 367# <i>mac-fdisk /dev/hda</i>
229</pre> 368</pre>
230 369
231<p> 370<p>
232First delete the partitions you have cleared previously to make room for your 371If you used Apple's Disk Utility to leave space for Linux, first delete the
233Linux partitions. Use <c>d</c> in <c>mac-fdisk</c> to delete those partition(s). 372partitions you have created previously to make room for your new install. Use
373<c>d</c> in <c>mac-fdisk</c> to delete those partition(s). It will ask for the
234It will ask for the partition number to delete. Usually the first partition on 374partition number to delete. Usually the first partition on NewWorld machines
235NewWorld machines (Apple_partition_map) could not be deleted. 375(Apple_partition_map) could not be deleted. If you would like to start with a
376clean disk, you can simply initialize the disk by pressing <c>i</c>. This
377will completely erase the disk, so use this with caution.
236</p> 378</p>
237 379
238<p> 380<p>
239Second, create an <e>Apple_Bootstrap</e> partition by using <c>b</c>. It will 381Second, create an <e>Apple_Bootstrap</e> partition by using <c>b</c>. It will
240ask for what block you want to start. Enter the number of your first free 382ask for what block you want to start. Enter the number of your first free
250<p> 392<p>
251Now create a swap partition by pressing <c>c</c>. Again <c>mac-fdisk</c> will 393Now create a swap partition by pressing <c>c</c>. Again <c>mac-fdisk</c> will
252ask for what block you want to start this partition from. As we used <c>2</c> 394ask for what block you want to start this partition from. As we used <c>2</c>
253before to create the Apple_Bootstrap partition, you now have to enter 395before to create the Apple_Bootstrap partition, you now have to enter
254<c>3p</c>. When you're asked for the size, enter <c>512M</c> (or whatever size 396<c>3p</c>. When you're asked for the size, enter <c>512M</c> (or whatever size
255you want -- 512MB is recommended though). When asked for a name, enter <c>swap</c> 397you want -- a minimum of 512MB is recommended, but 2 times your physical memory
256(mandatory). 398is the generally accepted size). When asked for a name, enter <c>swap</c>.
257</p> 399</p>
258 400
259<p> 401<p>
260To create the root partition, enter <c>c</c>, followed by <c>4p</c> to select 402To create the root partition, enter <c>c</c>, followed by <c>4p</c> to select
261from what block the root partition should start. When asked for the size, enter 403from what block the root partition should start. When asked for the size, enter
262<c>4p</c> again. <c>mac-fdisk</c> will interpret this as "Use all available 404<c>4p</c> again. <c>mac-fdisk</c> will interpret this as "Use all available
263space". When asked for the name, enter <c>root</c> (mandatory). 405space". When asked for the name, enter <c>root</c>.
264</p> 406</p>
265 407
266<p> 408<p>
267To finish up, write the partition to the disk using <c>w</c> and <c>q</c> to 409To finish up, write the partition to the disk using <c>w</c> and <c>q</c> to
268quit <c>mac-fdisk</c>. 410quit <c>mac-fdisk</c>.
269</p> 411</p>
270 412
271<note> 413<note>
272To make sure everything is ok, you should run mac-fdisk once more and check 414To make sure everything is ok, you should run <c>mac-fdisk -l</c> and check
273whether all the partitions are there. If you don't see any of the partitions 415whether all the partitions are there. If you don't see any of the partitions
274you created, or the changes you made, you should reinitialize your partitions 416you created, or the changes you made, you should reinitialize your partitions
275by pressing "i" in mac-fdisk. Note that this will recreate the partition map 417by pressing "i" in mac-fdisk. Note that this will recreate the partition map
276and thus remove all your partitions. 418and thus remove all your partitions.
277</note> 419</note>
278 420
279<p> 421<p>
280Now that your partitions are created, you can continue with <uri 422Now that your partitions are created, you can continue with
281link="#filesystems">Creating Filesystems</uri>. 423<uri link="#filesystems">Creating Filesystems</uri>.
282</p> 424</p>
283 425
284</body> 426</body>
285</section> 427</section>
286<section id="parted"> 428<section id="parted">
287<title>Using parted (especially Pegasos) to Partition your Disk</title> 429<title>Using parted to Partition your Disk (Pegasos and RS/6000)</title>
288<body> 430<body>
289 431
290<p> 432<p>
291<c>parted</c>, the Partition Editor, can now handle HFS+ partitions used by 433<c>parted</c>, the Partition Editor, can now handle HFS+ partitions used by
292Mac OS and Mac OS X. With this tool you can resize your Mac-partitions and 434Mac OS and Mac OS X. With this tool you can resize your Mac-partitions and
301<pre caption="Starting parted"> 443<pre caption="Starting parted">
302# <i>parted /dev/hda</i> 444# <i>parted /dev/hda</i>
303</pre> 445</pre>
304 446
305<p> 447<p>
306If the drive is unpartitioned, run <c>mklabel amiga</c> to create a new 448If the drive is unpartitioned, run <c>mklabel amiga</c> to create a new
307disklabel for the drive. 449disklabel for the drive.
308</p> 450</p>
309 451
310<p> 452<p>
311You can type <c>print</c> at any time in parted to display the current partition 453You can type <c>print</c> at any time in parted to display the current partition
313<c>Ctrl-c</c> to abort parted. 455<c>Ctrl-c</c> to abort parted.
314</p> 456</p>
315 457
316<p> 458<p>
317If you intend to also install MorphOS on your Pegasos create an affs1 filesystem 459If you intend to also install MorphOS on your Pegasos create an affs1 filesystem
318named "BI0" (BI zero) at the start of the drive. 32MB should be more than enough 460at the start of the drive. 32MB should be more than enough to store the MorphOS
319to store the MorphOS kernel. If you have a Pegasos I or intend to use reiserfs or 461kernel. If you have a Pegasos I or intend to use any filesystem besides ext2 or
320xfs, you will also have to store your Linux kernel on this partition (the 462ext3, you will also have to store your Linux kernel on this partition (the
321Pegasos II can only boot from ext2/ext3 or affs1 partitions). To create the partition run 463Pegasos II can only boot from ext2/ext3 or affs1 partitions). To create the
322<c>mkpart primary affs1 START END</c> where <c>START</c> and <c>END</c> should 464partition run <c>mkpart primary affs1 START END</c> where <c>START</c> and
323be replaced with the megabyte range (e.g. <c>0 32</c> creates a 32 MB partition 465<c>END</c> should be replaced with the megabyte range (e.g. <c>0 32</c> which
324starting at 0MB and ending at 32MB. 466creates a 32 MB partition starting at 0MB and ending at 32MB. If you chose to
325</p> 467create an ext2 or ext3 partition instead, substitute ext2 or ext3 for affs1 in
326 468the mkpart command.
327<p> 469</p>
328You need to create two partitions for Linux, one root filesystem for all your 470
329program files etc, and one swap partition. To create the root filesystem you
330must first decide which filesystem to use. Possible options are ext2, ext3,
331reiserfs and xfs. Unless you know what you are doing, use ext3. Run
332<c>mkpart primary ext3 START END</c> to create an ext3 partition. Again, replace
333<c>START</c> and <c>END</c> with the megabyte start and stop marks for the
334partition.
335</p> 471<p>
336 472You will need to create two partitions for Linux, one root filesystem and one
473swap partition. Run <c>mkpart primary START END</c> to create each partition,
474replacing <c>START</c> and <c>END</c> with the desired megabyte boundries.
337<p> 475</p>
476
477<p>
338It is generally recommended that you create a swap partition the same size as 478It is generally recommended that you create a swap partition that is two times
339the amount of RAM in your computer times two. You will probably get away with a 479bigger than the amount of RAM in your computer, but at least 512Mb is
340smaller swap partition unless you intend to run a lot of applications at the 480recommended. To create the swap partition, run
341same time (although at least 512MB is recommended). To create the swap 481<c>mkpart primary linux-swap START END</c> with START and END again denoting
342partition, run <c>mkpart primary linux-swap START END</c>. 482the partition boundries.
343</p>
344
345<p> 483</p>
346Write down the partition minor numbers as they are required during the 484
347installation process. To display the minor numbers run <c>print</c>. Your drives
348are accessed as <path>/dev/hdaX</path> where X is replaced with the minor number
349of the partition.
350</p> 485<p>
351
352<p>
353When you are done in parted simply run <c>quit</c>. 486When you are done in parted simply type <c>quit</c>.
354</p> 487</p>
355 488
356</body> 489</body>
357</section> 490</section>
358<section id="filesystems"> 491<section id="filesystems">
361<title>Introduction</title> 494<title>Introduction</title>
362<body> 495<body>
363 496
364<p> 497<p>
365Now that your partitions are created, it is time to place a filesystem on them. 498Now that your partitions are created, it is time to place a filesystem on them.
366If you don't care about what filesystem to choose and are happy with what we use 499If you're not sure which filesystems to choose and are happy with our defaults,
367as default in this handbook, continue with <uri 500continue with
368 link="#filesystems-apply">Applying a Filesystem to a Partition</uri>. 501<uri link="#filesystems-apply">Applying a Filesystem to a Partition</uri>.
369Otherwise read on to learn about the available filesystems... 502Otherwise, read on to learn about the available filesystems.
370</p> 503</p>
371 504
372</body> 505</body>
373</subsection> 506</subsection>
374<subsection> 507<subsection>
375<title>Filesystems?</title> 508<title>Filesystems?</title>
376<body> 509<body>
377 510
378<p> 511<p>
379Several filesystems are available. ext2, ext3, ReiserFS and XFS have been found 512Several filesystems are available for use on the PowerPC architecture including
380stable on the PPC architecture. 513ext2, ext3, ReiserFS and XFS, each with their strengths and faults.
381</p> 514</p>
382 515
383<p> 516<p>
384<b>ext2</b> is the tried and true Linux filesystem but doesn't have metadata 517<b>ext2</b> is the tried and true Linux filesystem but doesn't have metadata
385journaling, which means that routine ext2 filesystem checks at startup time can 518journaling, which means that routine ext2 filesystem checks at startup time can
386be quite time-consuming. There is now quite a selection of newer-generation 519be quite time-consuming. There is now quite a selection of journaled
387journaled filesystems that can be checked for consistency very quickly and are 520filesystems that can be checked for consistency very quickly and are thus
388thus generally preferred over their non-journaled counterparts. Journaled 521generally preferred over their non-journaled counterparts.
389filesystems prevent long delays when you boot your system and your filesystem
390happens to be in an inconsistent state.
391</p> 522</p>
392 523
393<p> 524<p>
394<b>ext3</b> is the journaled version of the ext2 filesystem, providing metadata 525<b>ext3</b> is the journaled version of the ext2 filesystem, providing metadata
395journaling for fast recovery in addition to other enhanced journaling modes 526journaling for fast recovery in addition to other enhanced journaling modes
396like full data and ordered data journaling. It uses a hashed B*-tree index that 527like full data and ordered data journaling. It uses a hashed B*-tree index that
397enables high performance in almost all situations. In short, ext3 is a very 528enables high performance in almost all situations. In short, ext3 is a very
398good and reliable filesystem. 529good and reliable filesystem and is highly recommended for most installs.
399</p> 530</p>
400 531
401<p> 532<p>
402<b>ReiserFS</b> is a B*-tree based filesystem that has very good overall 533<b>ReiserFS</b> is a B*-tree based filesystem that has very good overall
403performance and greatly outperforms both ext2 and ext3 when dealing with small 534performance and greatly outperforms both ext2 and ext3 when dealing with small
418deal of data if the system goes down unexpectedly. 549deal of data if the system goes down unexpectedly.
419</p> 550</p>
420 551
421</body> 552</body>
422</subsection> 553</subsection>
554<subsection>
555<title>Activating the Swap Partition</title>
556<body>
557
558<p>
559<c>mkswap</c> is the command that is used to initialize swap partitions:
560</p>
561
562<pre caption="Creating a swap signature">
563# <i>mkswap /dev/hda3</i>
564</pre>
565
566<p>
567To activate the swap partition, use <c>swapon</c>:
568</p>
569
570<pre caption="Activating the swap partition">
571# <i>swapon /dev/hda3</i>
572</pre>
573
574<p>
575Create and activate the swap now before creating other filesystems.
576</p>
577
578</body>
579</subsection>
423<subsection id="filesystems-apply"> 580<subsection id="filesystems-apply">
424<title>Applying a Filesystem to a Partition</title> 581<title>Applying a Filesystem to a Partition</title>
425<body> 582<body>
426 583
427<p> 584<p>
434 <th>Filesystem</th> 591 <th>Filesystem</th>
435 <th>Creation Command</th> 592 <th>Creation Command</th>
436</tr> 593</tr>
437<tr> 594<tr>
438 <ti>ext2</ti> 595 <ti>ext2</ti>
439 <ti><c>mkfs.ext2</c></ti> 596 <ti><c>mke2fs</c></ti>
440</tr> 597</tr>
441<tr> 598<tr>
442 <ti>ext3</ti> 599 <ti>ext3</ti>
443 <ti><c>mkfs.ext3</c></ti> 600 <ti><c>mke2fs -j</c></ti>
444</tr> 601</tr>
445<tr> 602<tr>
446 <ti>reiserfs</ti> 603 <ti>reiserfs</ti>
447 <ti><c>mkfs.reiserfs</c></ti> 604 <ti><c>mkreiserfs</c></ti>
448</tr> 605</tr>
449<tr> 606<tr>
450 <ti>xfs</ti> 607 <ti>xfs</ti>
451 <ti><c>mkfs.xfs</c></ti> 608 <ti><c>mkfs.xfs</c></ti>
452</tr> 609</tr>
453</table> 610</table>
454 611
455<p> 612<p>
456For instance, to have the root partition (<path>/dev/hda4</path> in our example) 613For instance, to make an ext3 filesystem on the root partition
457in ext3 (as in our example), you would use: 614(<path>/dev/hda4</path> in our example), you would use:
458</p> 615</p>
459 616
460<pre caption="Applying a filesystem on a partition"> 617<pre caption="Applying a filesystem on a partition">
461# <i>mkfs.ext3 /dev/hda4</i> 618# <i>mke2fs -j /dev/hda4</i>
462</pre> 619</pre>
463 620
464<p> 621<p>
465Now create the filesystems on your newly created partitions (or logical 622Now create the filesystems on your newly created partitions (or logical
466volumes). 623volumes).
467</p> 624</p>
468 625
469<note> 626<note>
470On the PegasosII your partition which holds the kernel must be ext2/ext3 or 627On the PegasosII your partition which holds the kernel must be ext2, ext3 or
471affs1. NewWorld machines can boot from any of ext2, ext3, XFS, ReiserFS or 628affs1. NewWorld machines can boot from any of ext2, ext3, XFS, ReiserFS or
472even HFS/HFS+ filesystems. On OldWorld machines booting with BootX, the kernel 629even HFS/HFS+ filesystems. On OldWorld machines booting with BootX, the kernel
473must be placed on an HFS partition, but this will be completed when you 630must be placed on an HFS partition, but this will be completed when you
474configure your bootloader. 631configure your bootloader.
475</note> 632</note>
476 633
477</body> 634</body>
478</subsection> 635</subsection>
479<subsection>
480<title>Activating the Swap Partition</title>
481<body>
482
483<p>
484<c>mkswap</c> is the command that is used to initialize swap partitions:
485</p>
486
487<pre caption="Creating a Swap signature">
488# <i>mkswap /dev/hda3</i>
489</pre>
490
491<p>
492To activate the swap partition, use <c>swapon</c>:
493</p>
494
495<pre caption="Activating the swap partition">
496# <i>swapon /dev/hda3</i>
497</pre>
498
499<p>
500Create and activate the swap now.
501</p>
502
503</body>
504</subsection>
505</section> 636</section>
506<section> 637<section>
507<title>Mounting</title> 638<title>Mounting</title>
508<body> 639<body>
509 640
517# <i>mount /dev/hda4 /mnt/gentoo</i> 648# <i>mount /dev/hda4 /mnt/gentoo</i>
518</pre> 649</pre>
519 650
520<note> 651<note>
521If you want your <path>/tmp</path> to reside on a separate partition, be sure to 652If you want your <path>/tmp</path> to reside on a separate partition, be sure to
522change its permissions after mounting: <c>chmod 1777 /mnt/gentoo/tmp</c>. This 653change its permissions after mounting and unpacking with
523also holds for <path>/var/tmp</path>. 654<c>chmod 1777 /mnt/gentoo/tmp</c>. This is also true for <path>/var/tmp</path>.
524</note> 655</note>
525
526<p>
527We will have to mount the proc filesystem (a virtual interface with the
528kernel) on <path>/proc</path>. But first we will need to place our files on the
529partitions.
530</p>
531 656
532<p> 657<p>
533Continue with <uri link="?part=1&amp;chap=5">Installing the Gentoo 658Continue with <uri link="?part=1&amp;chap=5">Installing the Gentoo
534Installation Files</uri>. 659Installation Files</uri>.
535</p> 660</p>

Legend:
Removed from v.1.37  
changed lines
  Added in v.1.38

  ViewVC Help
Powered by ViewVC 1.1.20