Gentoo Install Guide
By: Kevin • Research Paper • 2,649 Words • March 30, 2010 • 841 Views
Gentoo Install Guide
Gentoo
Gentoo-http://www.gentoo.org/
Gentoo is a distribution that has 3 different install methods. You can just install from the CDs known as stage 3. You can install the base system from CD known as stage 2 and then custom compile the rest of the OS from scratch to bring it to stage 3. This makes the system faster and more responsive but takes some time. Last is the stage 1 install where EVERYTHING is built from scratch. This makes for an EXTREMELY customized and streamlined system. However this method can take DAYS depending on the speed of your computer. A broadband connection would be recommened for a stage 2 or 1 install. Gentoo does all this with what is called Portage. you can basically type "emerge nameofprogram" and it will download, configure and compile the software for you. This makes maintaining the system very easy. Gentoo also has a great support base and is available for the MAC platform as well.
install guide
Note-The following guide is EXACTLY what I did for my install and it was adapted from the official gentoo installation handbook here.-http://www.gentoo.org/doc/en/handbook/index.xml
1. Download and burn the x86 minimal ISO and boot from the CD.
2. You will see a boot prompt where you can choose different kernels or view other options. We'll just hit enter since we don't need anything special.
3. You will then see a splash screen with a purple cow and the system will boot in the background.
4. When it's done you will have the standard linux command prompt. You will do everything for the install from here. No GUIs for you .
5. For this guide I will use an internet connection for everything. It is possible to install from CDs as well but including that info here would make it WAY too long. As such we need to maek sure networking is working correctly. To check use the "ifconfig" command. There should be an entry for eth0. If so run this command "dhcpcd eth0" that will request an ip address from the router. If you don't see anything with ifconfig try "ifconfig -a" if there is no ethx entry then the network card did get the correct driver loaded at boot. You will have to look up what kind of network card you have and find the appropriate module (driver) and load it using the modprobe command. I had to do this myself "modprobe pcnet32" to load the correct driver. I could then run "dhcpcd eth0" to get my ip address.
6. To get the best disk performance during the installation we will set some safe settings for the hard drive. Type in the following command "hdparm -d 1 -A 1 -m 16 -u 1 -a 64 /dev/hda" assuming /dev/hda is the disk you want to install to.
7. Now you need to partition the disk. There are a lot
of different partition schemes you can use. The gentoo install guide suggests 3. One for /, one for /boot and one for swap. I set mine up with 2 to keep it simple. one for / and one for swap. You will use the fdisk program to partition your drive like this "fdisk /dev/hda" you can then press "p" and enter to view the partition table use "d" to delete partitions and "n" to create new ones. I created a new partition with a capacity of 128MB on /dev/hda1 for swap and a new partiton on /dev/hda2 that used the rest fo the space for /. Don't forget to use "t" to specify the type of partition for the swap partition it should be set to 82. When you have things the way you want hit "w" and enter to write the changes and quit.
8. Now we have to create the filesystems for the partitions. You need to know
what type of filesystem you want first so that you use the appropriate tool. In my case I'm using reiserfs so I type in "mkreiserfs /dev/hda2" and it will format the partition, "mkswap /dev/hda1" will format the first partition as a swap partition.
9. Now we will turn on the swap partition like so "swapon /dev/hda1"
10. Now we are going to mount the / partition "mount /dev/hda2 /mnt/gentoo" and then make a boot directory "mkdir /mnt/gentoo/boot"
11. We need to check the date before we do anything else the "date" command will accomplish this. If it's wrong "date MMDDhhmmYYYY" will fix it.
12. So now we get to download the stage 1 installation files. go to the /mnt/gentoo directory and type "links www.gentoo.org/main/en/mirrors.xml". Welcome to command line web browsing. This will bring up the list of Gentoo mirrors in the browser.