/[gentoo]/xml/htdocs/doc/en/altinstall.xml
Gentoo

Diff of /xml/htdocs/doc/en/altinstall.xml

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

Revision 1.75 Revision 1.85
1<?xml version='1.0' encoding="UTF-8"?> 1<?xml version='1.0' encoding="UTF-8"?>
2<!-- $Header: /var/cvsroot/gentoo/xml/htdocs/doc/en/altinstall.xml,v 1.75 2008/05/23 20:29:44 swift Exp $ -->
3<!DOCTYPE guide SYSTEM "/dtd/guide.dtd"> 2<!DOCTYPE guide SYSTEM "/dtd/guide.dtd">
3<!-- $Header: /var/cvsroot/gentoo/xml/htdocs/doc/en/altinstall.xml,v 1.85 2012/04/29 16:52:20 swift Exp $ -->
4 4
5<guide link="/doc/en/altinstall.xml"> 5<guide>
6
7<title>The Gentoo Linux alternative installation method HOWTO</title> 6<title>The Gentoo Linux alternative installation method HOWTO</title>
8 7
9<author title="Contributor"> 8<author title="Contributor">
10 <mail link="gerrynjr@gentoo.org">Gerald Normandin Jr.</mail> 9 <mail link="gerrynjr@gentoo.org">Gerald Normandin Jr.</mail>
11</author> 10</author>
42<author title="Editor"> 41<author title="Editor">
43 <mail link="bennyc@gentoo.org">Benny Chuang</mail> 42 <mail link="bennyc@gentoo.org">Benny Chuang</mail>
44</author> 43</author>
45<author title="Editor"> 44<author title="Editor">
46 <mail link="smithj@gentoo.org">Jonathan Smith</mail> 45 <mail link="smithj@gentoo.org">Jonathan Smith</mail>
46</author>
47<author title="Editor">
48 <mail link="nightmorph"/>
47</author> 49</author>
48 50
49<abstract> 51<abstract>
50This HOWTO is meant to be a repository of alternative Gentoo installation 52This HOWTO is meant to be a repository of alternative Gentoo installation
51methods, for those with special installation needs such as lack of a cdrom 53methods, for those with special installation needs such as lack of a cdrom
54 56
55<!-- The content of this document is licensed under the CC-BY-SA license --> 57<!-- The content of this document is licensed under the CC-BY-SA license -->
56<!-- See http://creativecommons.org/licenses/by-sa/2.5 --> 58<!-- See http://creativecommons.org/licenses/by-sa/2.5 -->
57<license/> 59<license/>
58 60
59<version>0.73</version> 61<version>10</version>
60<date>2008-01-09</date> 62<date>2012-04-29</date>
61 63
62<chapter> 64<chapter>
63<title>About this document</title> 65<title>About this document</title>
64<section> 66<section>
65<body> 67<body>
157</body> 159</body>
158</section> 160</section>
159</chapter> 161</chapter>
160 162
161<chapter> 163<chapter>
162<title>Knoppix Installation</title> 164<title>Installation from non-Gentoo LiveCDs</title>
163<section> 165<section>
166<title>Introduction</title>
164<body> 167<body>
165 168
166<note> 169<impo>
167Knoppix is only available for x86 users. 170The Gentoo developers cannot support you if something goes wrong with a
168</note> 171non-Gentoo LiveCD, as there's no way to fix, troubleshoot, or document every
172quirk of every LiveCD out there. Only Gentoo LiveCDs are officially supported.
173If you run into problems with alternative installation media, please visit the
174<uri link="http://forums.gentoo.org">Gentoo Forums</uri> for community help.
175</impo>
169 176
170<!-- this works with knoppix 3.6+ and gentoo 2004.3, 2005.0--> 177<p>
171 178It is possible to boot some other LiveCD besides the Gentoo-provided CDs. This
179will give you a functional environment to use while you're compiling and
180installing Gentoo. The instructions provided here should work in principle with
181just about any other LiveCD.
172<p> 182</p>
173Booting from the <uri link="http://www.knoppix.org/">Knoppix</uri> LiveCD is a 183
174way to have a fully functional system while you're compiling Gentoo. Tux Racer 184<p>
175will help you pass the time while you wait, and you can use OpenOffice for 185There are too many LiveCDs out there to <uri
176work. 186link="http://distrowatch.com/search.php">list</uri>, but you might try <uri
187link="http://www.knoppix.org/">Knoppix</uri>. It provides a full graphical
188desktop, with office applications, web browsers, and games to keep you busy.
189Knoppix is only available for x86 users, so depending on your needs you may need
190to find a different LiveCD.
177</p> 191</p>
178 192
179<warn> 193<warn>
180Be aware that if you save anything in Knoppix's home directory while waiting 194Be aware that if you save anything in your LiveCD's home directory while waiting
181for your Gentoo system to install, it will not be available when you reboot 195for your Gentoo system to install, it will not be available when you reboot
182into Gentoo. Be sure to save important files on the hard disk or on some other 196into Gentoo. Be sure to save important files on the hard disk or on some other
183computer! 197computer!
184</warn> 198</warn>
185 199
186<p> 200</body>
187Boot from the Knoppix CD. If you have Knoppix 3.6-3.8.2, you will need to 201</section>
188specify <c>knoppix26</c> as a boot option to load a 2.6 kernel. If you miss 202<section>
189this step, when you <c>chroot</c>, you will recieve an error saying that your 203<title>Installation instructions</title>
190kernel is too old. If, however, you have Knoppix 3.9+, this step is 204<body>
191unnecessary, since the 2.6 kernel is default. 205
192</p> 206<p>
193 207Boot from your LiveCD. Open a terminal and run <c>su -</c> so you can change your
194<p> 208password. This lets you set the root password for the CD. You can now configure
195By default Knoppix boots into a KDE desktop. Open a <c>konsole</c> and <c>su 209<c>sshd</c> for remote login, if you need to install Gentoo remotely. Next,
196-</c> so you can change your password. This lets you set the root password for 210you'll need to create the <path>/mnt/gentoo</path> mountpoint.
197Knoppix. You can now configure <c>sshd</c> for remote login, at your
198preference.
199</p> 211</p>
200 212
201<pre caption="Creating the /mnt/gentoo mountpoint"> 213<pre caption="Creating the /mnt/gentoo mountpoint">
202# <i>mkdir /mnt/gentoo</i> 214# <i>mkdir /mnt/gentoo</i>
203</pre> 215</pre>
212<pre caption="Bind-mounting the proc pseudo filesystem"> 224<pre caption="Bind-mounting the proc pseudo filesystem">
213# <i>mount -o bind /proc /mnt/gentoo/proc</i> 225# <i>mount -o bind /proc /mnt/gentoo/proc</i>
214</pre> 226</pre>
215 227
216<p> 228<p>
229When you're ready to unpack the stage tarball in <uri
230link="/doc/en/handbook/handbook-x86.xml?part=1&amp;chap=5#doc_chap2_sect2">part
2315</uri>, you will need to use a different <c>tar</c> command to ensure that
232proper group IDs are enforced on the unpacked stage:
233</p>
234
235<pre caption="Unpacking the stage tarball">
236# <i>tar --numeric-owner -xvjpf stage3-*.tar.bz2</i>
237</pre>
238
239<p>
240Once you're ready to chroot into your unpacked stage in <uri
241link="/doc/en/handbook/handbook-x86.xml?part=1&amp;chap=6#doc_chap1">part
2426</uri>, you will need to use a different chroot command sequence. This ensures
243that your environment variables are properly setup.
244</p>
245
246<pre caption="Chrooting into the new environment">
247<comment>(Some LiveCDs use a funny environment setup, hence the -i option for
248cleaning it up to a reasonable state.)</comment>
249# <i>chroot /mnt/gentoo /bin/env -i TERM=$TERM /bin/bash</i>
250# <i>env-update</i>
251# <i>source /etc/profile</i>
252# <i>export PS1="(chroot) $PS1"</i>
253</pre>
254
255<p>
217Also, know that some of Portage's FEATURES will not work in knoppix. Especially 256Finally, know that some Portage FEATURES may not work in your LiveCD. Especially
218watch out for <c>userpriv</c> and <c>usersandbox</c>. If you find yourself 257watch out for <c>userpriv</c> and <c>usersandbox</c>. If you find yourself
219getting errors, it might be wise to disable some or all of the optional 258getting errors, it might be wise to disable some or all of the optional
220features. 259FEATURES.
221</p> 260</p>
222 261
223<!-- 262<!--
224 Commenting out due to #78716. If it needs to be restated again, note 263 Commenting out due to #78716. If it needs to be restated again, note
225 that some will require to bind-mount it, others don't, and that you have 264 that some will require to bind-mount it, others don't, and that you have
278# <i>mkdir /diskless/eta/boot</i> 317# <i>mkdir /diskless/eta/boot</i>
279</pre> 318</pre>
280 319
281<p> 320<p>
282DHCP and TFTP setup: The client will get boot informations using DHCP and 321DHCP and TFTP setup: The client will get boot informations using DHCP and
283download all the required files using TFTP. Just emerge DHCP and configure it 322download all the required files using TFTP.
284for your basic needs. Then, add the following on 323</p>
324
325<p>
326For dhcpd, just run <c>emerge dhcp</c> (or any other DHCP server of your
327choice). Make sure that the correct interface is selected in
328<path>/etc/conf.d/dhcpd</path>, and configure it for your basic needs. Then, add
285<path>/etc/dhcp/dhcpd.conf</path>. 329the following on <path>/etc/dhcp/dhcpd.conf</path>.
286</p> 330</p>
287 331
288<note> 332<note>
289This provide a static IP address for the client and the path of a PXE boot 333This provides a static IP address for the client and the path of a PXE boot
290image, here <path>pxegrub</path>. You have to replace the MAC address of the 334image, here <path>pxegrub</path>. You have to replace the MAC address of the
291Ethernet card of the client and the directory where you will put the client 335ethernet card of the client and the directory where you will put the client
292files with the one you use. 336files with the one you use.
293</note> 337</note>
294
295<p>
296For DHCPd, run <c>emerge dhcp</c> (or any other DHCP server of your choice).
297Make sure that the correct interface is selected in
298<path>/etc/conf.d/dhcpd</path>.
299</p>
300 338
301<pre caption="dhcpd.conf"> 339<pre caption="dhcpd.conf">
302option option-150 code 150 = text ; 340option option-150 code 150 = text ;
303ddns-update-style none ; 341ddns-update-style none ;
304host eta { 342host eta {
309} 347}
310</pre> 348</pre>
311 349
312<p> 350<p>
313Next you'll need to configure your interface in <path>/etc/conf.d/net</path> so 351Next you'll need to configure your interface in <path>/etc/conf.d/net</path> so
314that it doesn't get cleared at bootup. See <path>/etc/conf.d/net.example</path> 352that it doesn't get cleared at bootup. See
315for more information. 353<path>/usr/share/doc/openrc-*/net.example.bz2</path> for more information.
316</p> 354</p>
317 355
318<pre caption="/etc/conf.d/net"> 356<pre caption="/etc/conf.d/net">
319<comment>(Replace eth0 with the correct interface)</comment> 357<comment>(Replace eth0 with the correct interface)</comment>
320config_eth0=( "noop" ) 358config_eth0=( "noop" )
389You might want to reboot the server with a Gentoo Install CD, although you can 427You might want to reboot the server with a Gentoo Install CD, although you can
390very well continue immediately if you know how to proceed with the Gentoo 428very well continue immediately if you know how to proceed with the Gentoo
391Installation Instructions from an existing installation. Follow the standard 429Installation Instructions from an existing installation. Follow the standard
392install procedure as explained in the <uri link="/doc/en/handbook/">Gentoo 430install procedure as explained in the <uri link="/doc/en/handbook/">Gentoo
393Handbook</uri> BUT with the following differences: 431Handbook</uri> BUT with the following differences:
394When you mount the file system, do the following (where <path>hdaX</path> is 432When you mount the file system, do the following (where <path>sdaX</path> is
395the partition where you created the <path>/diskless</path> directory). You do 433the partition where you created the <path>/diskless</path> directory). You do
396not need to mount any other partitions as all of the files will reside in the 434not need to mount any other partitions as all of the files will reside in the
397<path>/diskless/eta</path> directory. 435<path>/diskless/eta</path> directory.
398</p> 436</p>
399 437
400<pre caption="Mounting the filesystem"> 438<pre caption="Mounting the filesystem">
401#<i> mount /dev/hdaX /mnt/gentoo</i> 439#<i> mount /dev/sdaX /mnt/gentoo</i>
402</pre> 440</pre>
403 441
404<p> 442<p>
405Stage tarballs and chroot: This example uses a stage3 tarball. Mount 443Stage tarballs and chroot: This example uses a stage3 tarball. Mount
406<path>/proc</path> to your diskless directory and chroot into it to continue 444<path>/proc</path> to your diskless directory and chroot into it to continue
455</p> 493</p>
456 494
457<pre caption="/etc/fstab"> 495<pre caption="/etc/fstab">
458# <i>nano -w /etc/fstab</i> 496# <i>nano -w /etc/fstab</i>
459/dev/cdroms/cdrom0 /mnt/cdrom iso9660 noauto,ro 0 0 497/dev/cdroms/cdrom0 /mnt/cdrom iso9660 noauto,ro 0 0
460proc /proc proc defaults 0 0
461tmpfs /dev/shm tmpfs nodev,nosuid,noexec 0 0
462</pre> 498</pre>
463 499
464<p> 500<p>
465You also need to prevent the client to run a filesystem check: 501You also need to prevent the client to run a filesystem check:
466</p> 502</p>
555that later. 591that later.
556</p> 592</p>
557 593
558<pre caption="Filesystem information"> 594<pre caption="Filesystem information">
559# <i>mount</i> 595# <i>mount</i>
560/dev/hdb2 on / type ext3 (rw) 596/dev/sdb2 on / type ext3 (rw)
561none on /proc type proc (rw) 597none on /proc type proc (rw)
562none on /dev/pts type devpts (rw,gid=5,mode=620) 598none on /dev/pts type devpts (rw,gid=5,mode=620)
563none on /dev/shm type tmpfs (rw,nodev,nosuid,noexec) 599none on /dev/shm type tmpfs (rw,nodev,nosuid,noexec)
564# <i>df -h </i> 600# <i>df -h </i>
565Filesystem Size Used Avail Use% Mounted on 601Filesystem Size Used Avail Use% Mounted on
566/dev/hdb2 4.0G 1.9G 2.4G 82% / 602/dev/sdb2 4.0G 1.9G 2.4G 82% /
567none 38M 0 38M 0% /dev/shm 603none 38M 0 38M 0% /dev/shm
568</pre> 604</pre>
569 605
570<p> 606<p>
571As we can see, the partition mounted as <path>/</path> named 607As we can see, the partition mounted as <path>/</path> named
572<path>/dev/hdb2</path> has 2.4 gigabytes free. In my case, I think I will 608<path>/dev/sdb2</path> has 2.4 gigabytes free. In my case, I think I will
573resize it as to leave 400Megs free of space, therefore allocating 2 gigabytes 609resize it as to leave 400Megs free of space, therefore allocating 2 gigabytes
574for Gentoo. Not bad, I could have quite some stuff installed. However, I think 610for Gentoo. Not bad, I could have quite some stuff installed. However, I think
575that even one gigabyte is enough for most users. So let's partition this thing! 611that even one gigabyte is enough for most users. So let's partition this thing!
576</p> 612</p>
577 613
659we have created above and type <c>mount /dev/fd0 /floppy</c> to have parted 695we have created above and type <c>mount /dev/fd0 /floppy</c> to have parted
660under <path>/floppy</path>. There you go. Run parted and you will be able to 696under <path>/floppy</path>. There you go. Run parted and you will be able to
661resize your partition. Once this lenghty process done, we are ready to have the 697resize your partition. Once this lenghty process done, we are ready to have the
662real fun, by installing Gentoo. Reboot back into your old Linux system for now. 698real fun, by installing Gentoo. Reboot back into your old Linux system for now.
663The drive you wish to operate on is the drive containing the partition we want 699The drive you wish to operate on is the drive containing the partition we want
664to resize. For example, if we want to resize /dev/hda3, the drive is /dev/hda. 700to resize. For example, if we want to resize /dev/sda3, the drive is /dev/sda.
665</p> 701</p>
666 702
667<pre caption="Commands to run once logged into mininux system"> 703<pre caption="Commands to run once logged into mininux system">
668# <i>mount /dev/fd0 /floppy </i> 704# <i>mount /dev/fd0 /floppy </i>
669# <i>cd /floppy; ./parted [drive you wish to operate on]</i> 705# <i>cd /floppy; ./parted [drive you wish to operate on]</i>
670(parted) <i> print </i> 706(parted) <i> print </i>
671Disk geometry for /dev/hdb: 0.000-9787.148 megabytes 707Disk geometry for /dev/sdb: 0.000-9787.148 megabytes
672Disk label type: msdos 708Disk label type: msdos
673Minor Start End Type Filesystem Flags 709Minor Start End Type Filesystem Flags
6741 0.031 2953.125 primary ntfs 7101 0.031 2953.125 primary ntfs
6753 2953.125 3133.265 primary linux-swap 7113 2953.125 3133.265 primary linux-swap
6762 3133.266 5633.085 primary ext3 7122 3133.266 5633.085 primary ext3

Legend:
Removed from v.1.75  
changed lines
  Added in v.1.85

  ViewVC Help
Powered by ViewVC 1.1.20