Distribution Watch: Gentoo Linux - page 3
Introducing Gentoo Linux 1.1a
Installing Gentoo Linux 1.1a is an involved process if it goes wrong, and just a step by step by the numbers if it goes right. You'll see what I mean as I walk you through my own experience. I started of course by choosing which installation route I wanted to take. As I mentioned before, I like to try the methods that the target market are most likely to use, so I decided that I'd go through the whole build process. Perhaps that was my mistake.
The Gentoo CD-ROM images are fairly small since so much code is downloaded. The instructions seem pretty complicated at first, especially for those of us too used to nicely automated installations, but when you take them one step at a time they're pretty clear.
I started with the old standards. Popped the CD-ROM into my test machine's CD-ROM drive, rebooted, changed the BIOS to boot from CD-ROM, and rebooted again. I press Enter at the boot prompt and then again for PCI autodetection (a nice luxury), and soon I'm at the Install/Rescue screen and I press Enter to get the command prompt.
So far, so good. Since my PCI Ethernet card was autodetected, it turns out that I didn't have to manually deal with the network card module. A quick lsmod confirmed that the module was loaded automatically once it was detected, so I proceeded past the PCMCIA and SCSI sections since my test machine doesn't have either of those, and connecting with DHCP from there was a breeze.
If you've ever wondered about the pluses and minuses of ext2, ext3, ReiserFS, and XFS, the Gentoo Linux installation document has an excellent writeup. I chose ext3 for my boot and root partitions, and of course swap for the swap partition, not much choice there. Fortunately I can use fdisk in my sleep, because creating the partitions involves navigating this lovely tool without instructions. I don't even forget to press t before saving out and set the swap partition to type 82 (Linux swap).
Building the filesystems definitely reminds me of "the old days," aside from the ext3 journalling flag. Made the swap filesystem on the swap partition, the ext3 filesystem on the /boot and root filesystems, and then activated the swap partition. Now I've got to add the mount points and actually pull these partitions onto the filesystem, and the order in the instructions is important. First I create /mnt/gentoo and mount /dev/hdb3 as /mnt/gentoo. The reason the instructions say to do do both of these first is that it's a bit hard to create /mnt/gentoo/boot in /mnt/gentoo if you haven't actually mounted /mnt/gentoo. So, then I create mount points, mount the partitions, and then mount the Gentoo CD-ROM. From here I can untar its contents (the stage 1 tbz file in my case), making sure to use the flags specified in the installation document, mount the proc filesystem, and copy the /etc/resolv.conf created when I made my DHCP connection into the Gentoo filesystem.
Next the instructions say to do a chroot, which means telling Linux to use a new spot as the root of its filesystem, so I make /mnt/gentoo my new base point before running env-update, a custom tool that re-loads your shell and other configuration files in case any changes were made by other software.
I finally hit my first snag when I type source /etc/profile. I get a make.profile error that suggests running emerge sync, so I do that and wait while lots of text scrolls by (techie-speak for I think it downloaded something but I can't quite remember), re-run env-update for my own comfort levels, and then execute the master user profile. But, the prompt doesn't change like the instructions say it should.
Well, nothing to do but move on and see if the rest of the process works from here. I type emerge rsync like the instructions say but emerge sync did most of the work already, so rather than taking a while downloading and compiling software, I just get a summary printout. That's okay. Next step is to edit the master compile configuration file with the nano editor, which (no surprise) turns out to be much like the pico editor. I'm not a programmer by trade so it takes me a moment to mentally process the options, and I select one that should be pretty flexible. Once I save out the file I change to the proper directory and type the big command: scripts/bootstrap.sh. Since the instructions say it's time to go find something to do, I naively walk away and figure I'll check back in an hour or two. Big mistake, but I won't realize why for a few days. Seems I get to deal with a particularly annoying bug that only one other person had mentioned in the Gentoo Bugzilla entries: the installation locking up. I came back to a blank screen and had to reboot the machine from the tower, Ctrl-Alt-Del did not work.
I got held up for quite a while on this one. I tried a number of different settings in /etc/make.conf, thinking that perhaps some of the configuration options just weren't compatible with my hardware set. About five times through and every time it hung in about the same place, hard to tell exactly where, but sometime during the bootstrap process. Finally, I decided to compile for a 586 instead of a 686, and sat and watched over the process like a hawk without allowing it to get idle enough to black out the screen. Oddly, it worked. This was a relief since Bugzilla had no solutions to suggest!
Now I was finally able to proceed to the next step, which led to the next long download and build process, this time for the main system. After a couple of hours of not letting the system go idle too long, this step ends with a segmentation fault. That's a bit unnerving! But, I plod on, typing emerge sys-kernel/linux-sources. That proceeds just fine so I reason that I must be okay.
So now I've got the kernel sources. I change to /usr/src/linux and type make menuconfig to go to the ol familiar kernel configuration curses menu interface. Once I make a few changes and save out of that, I type the convoluted item mentioned in the instructions:
make dep && make clean bzImage modules modules_install
This sequence is just all of the kernel compilation options in a row on
the same command line. Once again, as this process ends I get a set of
errors, but I'll keep going since none of the errors have been fatal yet.
I don't have an original /boot/bzImage so I don't have to move that file,
I just have to copy the new bzImage into place. Uh oh, no bzImage at all,
so this last error really was a problem.
I go in and edit the kernel options again (superstition) and then retype
the long set of compile instructions from earlier--well, okay, I use the
up arrow to pull them back up. Phew, this looks like it finished properly.
Sure enough, I'm able to copy bzImage over. I decide to go with metalog
since I haven't tried that one yet, so I emerge it, and then use rc-update
to add metalog to the boot routine.
Things go downhill pretty fast from here. I get some more configuration files edited, GRUB gives me attitude and refuses to cooperate, the machine can't boot properly because somehow the mount command never got installed (oops, perhaps one of those failed commands from earlier), but there's a nice maintenance login so I log in as root. Oddly I have the mount man page, so I use find to see where the mount command is to see if this is just a path problem, but it's really not there. Then it turns out I have a read-only filesystem.
Okay, I'm an adventurous sort, I rebooted with the rescue CD-ROM, found that mount was in the util-linux package, used emerge to install and compile mount, rebooted, found myself in a much better state, but ... no. After a week of fussing on and off with this distribution, I just am not going to be able to get it installed in time for this review. While I'll likely turn around and try out the lessons I've learned along the way to give it another go, for now I have to say that not being able to get this sucker installed has been a frustrating experience, to say the least.