Kuro5hin.org: technology and culture, from the trenches
create account | help/FAQ | contact | links | search | IRC | site news
[ Everything | Diaries | Technology | Science | Culture | Politics | Media | News | Internet | Op-Ed | Fiction | Meta | MLP ]
We need your support: buy an ad | premium membership

[P]
Installing Gentoo Linux

By Anonymous American in Technology
Thu Apr 04, 2002 at 10:06:36 PM EST
Tags: Software (all tags)
Software

I was looking for a flexible, powerful distribution that makes it easy to build a "custom" Linux box that meets my exacting specifications. I think I found it. Gentoo Linux has just released version 1.0 of their innovative meta-distribution and to celebrate I decided to throw it on my laptop and write this article based on my experiences.


Gentoo solved many problems for me. Some distros install everything, whether you really need it or not. Not Gentoo; other than the base packages required for Linux to run, the only software installed on the system is the software you put there. Gentoo resolves dependancies automatically, eliminating RPM prerequisite hell. As an added bonus I got something I wasn't even expecting. Speed. Blinding, blazing, incredible speed.

The main advantage to the Gentoo distribution is Portage, a python based ports system similar to BSD ports. For those of you unfamiliar with BSD ports, Portage is a package management tool that downloads and installs source instead of precompiled packages. When I need a program I download, install and compile it with one command:

emerge nmap

The above will download the nmap source code, compile and install it. Of course this method is slow, but it has it's rewards. You can also opt to use prebuilt binaries if you are not extremely patient. It took me five hours to get the base Gentoo installed on my PIII with 128 meg of ram. It wasn't a big deal as I had other things to do, but I would like to see the installation process optimized so that it doesn't require any babysitting.

Gentoo is running two of my mission critical servers right now, I consider it to be stable and mature. A warning though, this is not a distribution for dummies. This is bare metal Linux, powerful and dangerous. If you do something without thinking you may fall into a bucket of pain.

Let's begin my story.

I download the iso from http://www.ibiblio.org/gentoo/releases/build /. There is a choice of install images here. My favorite way of installing Gentoo is to compile everything, a time consuming process. This method requires a slim 16 meg iso. You may want to grab an iso with pre-built binaries to speed things up, however. This fat iso weighs in at 103 meg. I download the big one with the prebuilt binaries even though I won't use them - just in case.

I boot my laptop with my shiny new Gentoo CD. The Gentoo install uses isolinux by Peter Anvin. I like the fact that they don't obscure it, giving credit where it is due. It boots quickly and there is a PCI autodetection process, it shouldn't find much on my laptop. Interesting, it loads a scsi module. Perhaps it has detected my IDE cd burner. Usually this will detect any PCI nic cards that are installed, but it does not detect my PCMCIA device (of course). After the PCI detection I get a command prompt. I use nano (a small text editor) to open up install.txt, the excellent install doc. Usually these docs are sufficient but the latest ones can be found here:

http://www.gentoo.org/doc/build.html

Keeping the install doc open in this virtual terminal, I hit alt-f2 to open a new one. I begin by loading the pcmcia drivers and installing networking. This is all done at the command line ( insmod, ifconfig, route, dhcpcd, etc.). I use nano to add my DNS servers to /etc/resolv.conf. A word of caution; get in the habit of always using the -w switch with nano. If you do not use the -w switch nano's word wrap feature will jack up your config files. I ping a reliable site, networking is up!

Next I partition my system using fdisk. I choose a simple layout with a swap partition, a root partition and a small boot partition. The boot partition remains unmounted during use, a nice precaution. For filesystems you have a choice of ext2, ext3, ReiserFS and XFS. In my personal experience I've noticed that Reiser performance really rocks when combined with SCSI drives, but as this is an IDE system I think I'll go with XFS. Besides the XFS tools seem to be a lot more mature than the offerings from Reiser. I format and mount the partitions from the command line creating a /mnt/gentoo directory. I then untar the root filesystem, here I have the choice of the small tarball that requires you to compile everything or a larger tarball that contains pre-built binaries. If you untar the big guy you are almost finished with your install at this point. Using chroot and some scripts you chroot the /mnt/gentoo directory. From this point on you are operating under your new gentoo system.

The first thing I do under my chrooted system is issue this command:

emerge rsync

This downloads the latest version of the portage tree. The portage tree is found under /usr/portage and contains the ebuild scripts used to compile/install programs. Currently there are over 1000 up to date emerge sripts. Next I edit /etc/make.conf, here I can choose compiler settings. I optimize everything for i686. Now it's time to build the GNU compiler and libraries. I run the bootstrap script and leave for lunch. On my PIII 500 the boostrap process takes 2 hours and 2 minutes.

The second emerge command I issue is:

emerge system

Now emerge downloads, compiles and installs my base system packages. I sit back, relax and take the time to fax my legislators a rant about the DCMA. 1 hour and 30 minutes later it is finished.

Now it is time to download and install the kernel. First I make a link updating my timezone, and then I issue another emerge command:

emerge linux-sources

This grabs the latest kernel, 2.4.19, and drops the source in /usr/src/linux. Ten minutes have elapsed. Now comes the fun, compiling your kernel. That's right, everyone who installs Gentoo compiles they're own kernel as a matter of process. I like this. There are some distributions out there that actually say you should never compile your own kernel. Shame on them. I use make menuconfig and the standard commands to compile my kernel. Since Gentoo uses devfs I select /dev file system support and I am also careful to compile in support for XFS. I don't have the kernel mount devfs automatically at boot as the Gentoo startup scripts take care of this for me. Virtual Memory file system support is also enabled.

At this point in time I get to choose a logger. My choices are sysklogd, syslog-ng or metalog. I choose metalog, because it's got the coolest name. I download, compile and install it using a single command:

emerge metalog

XFS has some nice utilities, I better install those. I have some other essential programs to install, and I'm feeling a bit lazy so I chain them all in one big command.

emerge xfsprogs;emerge bitchx;emerge vim;emerge links

At this point I'm feeling pretty 7 up. I edit my /etc/fstab file, my /etc/hostname file and /etc/hosts. The passwd command is run to set the root passwd. I add my nic card module to the file /etc/modules.autoload and edit /etc/conf.d/net. conf.d/net allows me to configure my ip address and settings, default gateway and alias. I take a look at /etc/init.d/net.eth0, even though I don't need to edit it. I can then add it to the startup script using this command:

rc-update add net.eth0 default

This adds the script to the default runlevel to be executed at startup. Startup scripts are another place Gentoo really shines. The startup scripts have a system of dependancies. For example net.eth0 can depend on pcmcia. The pcmcia drivers get loaded before net.eth0 - this is good.

Next I install grub. If you haven't used grub before it's nice. You can boot to a kernel directly from the grub shell, without having to edit a config file. lilo is still available, for those of you that prefer it. Gentoo likes to let you make the decisions.

I exit my chrooted shell and unmount all directories. Reboot! Gentoo comes up and the install process is complete.

The Gentoo install process has taught me a lot about Linux, and I like the fact that the command line is embraced, instead of hidden behind gui or scripts. I also like the speed (which is debatable since all I can supply is anecdotal evidence). I wasn't too happy about waiting 5 hours for everything to compile, but I think it was worth it. I can tell you it compiles and greps noticeably faster than other distros I have run on the exact same machines. I really enjoy using portage, and the packages seem to stay up to date - if not bleeding edge. This is not a conservative distribution like Debian, however I like the aggressive and intelligent direction gentoo is taking.

If you are considering trying out Gentoo I highly suggest #gentoo on irc.openprojects.net. Also subscribe to the mailing lists found at www.gentoo.org. The Gentoo community has helped me out of several jams in the past, I think they will treat you good too.

While writing this, I recieved help from a lot of people. However I would like to personally thank the people I ripped off word for word. Thanks notafurry of www.kuro5hin.org for your pointed help with the stilted second paragraph and thank you Ween from #gentoo on openprojects.net for your clean description of portage.

Sponsors

Voxel dot net
o Managed Hosting
o VoxCAST Content Delivery
o Raw Infrastructure

Login

Related Links
o Kuro5hin
o http://www .ibiblio.org/gentoo/releases/build /
o isolinux by Peter Anvin
o http://www .gentoo.org/doc/build.html
o reliable site
o over 1000 up to date emerge sripts
o a rant about the DCMA
o irc.openpr ojects.net
o www.gentoo .org
o notafurry
o www.kuro5h in.org
o openprojec ts.net
o Also by Anonymous American


Display: Sort:
Installing Gentoo Linux | 68 comments (62 topical, 6 editorial, 0 hidden)
Debian is good for me, but Gentoo could be useful (3.50 / 2) (#1)
by grout on Thu Apr 04, 2002 at 08:33:45 PM EST

I could see Gentoo as the base for a fully customized turnkey system. Good to read about alternatives.
--
Chip Salzenberg, Free-Floating Agent of Chaos

Quick note (2.50 / 4) (#6)
by qpt on Thu Apr 04, 2002 at 09:50:21 PM EST

You misspelled "turkey".

Domine Deus, creator coeli et terrae respice humilitatem nostram.
[ Parent ]

Nope (3.00 / 4) (#18)
by carbon on Thu Apr 04, 2002 at 11:31:58 PM EST

You misspelled "turkey".

No, I believe that you mispelled "turnkey", as in 'turn the key'.


Wasn't Dr. Claus the bad guy on Inspector Gadget? - dirvish
[ Parent ]
You did it again! (2.66 / 3) (#33)
by synaesthesia on Fri Apr 05, 2002 at 06:42:25 AM EST

No, I believe that you mispelled "turnkey", as in 'turn the key'.

Oops - you misspelled "turkey" again, and then proceeded to misspell 'turbot the kipper' in the very same sentence!



Sausages or cheese?
[ Parent ]
Twice! (4.00 / 2) (#39)
by Gully Foyle on Fri Apr 05, 2002 at 10:08:51 AM EST

He also misspelled Grout as Carbon!

If you weren't picked on in school you were doing something wrong - kableh
[ Parent ]

And you... (2.00 / 2) (#42)
by synaesthesia on Fri Apr 05, 2002 at 11:08:01 AM EST

...misspelled "I" as "he", etc., etc.

Sausages or cheese?
[ Parent ]
I love Reviews & Howtos (4.00 / 2) (#2)
by Adam Theo on Thu Apr 04, 2002 at 08:43:01 PM EST

I love reading about this sort of thing. Reviews and HOWTOs on tech stuff. Especially when it comes to Linux distros and other open source app stuff.

And on this topic: I have been planning to try out Rock Linux in the next couple of days, and will write about my experience here as you have. But you've also convinced me to try out Gentoo after that. I'd like to compare the two eventually, and see the weaknesses of each.

Is the 5 hour compile time the only thing you found wrong or lacking with it? If you think of anything else, please tell me so I can take note of it when I try it out.

Thanks! :-)

-- "A computer geek free-market socialist patriotic American Buddhist."

For more of this... (2.75 / 4) (#9)
by E r i c on Thu Apr 04, 2002 at 10:13:44 PM EST

try monolinux.com (no, really).

I blame my past transgressions on Eminem's music. Reform number five is currently in progress.
[ Parent ]
Ports (3.00 / 1) (#7)
by PresJPolk on Thu Apr 04, 2002 at 09:59:25 PM EST

I say, if you want something like Ports, just go get FreeBSD and use the original! The FreeBSD Ports collection is huge and mature. I don't see how some upstart can beat it overnight.

If you're going to restrict yourself to linux, just make sure you're doing it for the right reasons. Don't reject FreeBSD just because it's not linux.

(Speaking as a Slackware user, not a FreeBSD user.)

Hardware Support (4.50 / 2) (#13)
by brunes69 on Thu Apr 04, 2002 at 10:29:00 PM EST

The main reason I and I suspsect alot of others stick with Linux is the hardware support. It has always (on the x86 platform) anyways had much better hardware support than xBSD, and with all the press it has been getting, hardware companies are even themselves making drivers for Linux now (example, NVidia). Until these companies / others start churning out drivers for the latest-and-greatest for xBSD, there will always be a smaller following.



---There is no Spoon---
[ Parent ]
There is in fact, (4.00 / 1) (#16)
by binaryalchemy on Thu Apr 04, 2002 at 11:01:26 PM EST

a project working with NVidia to make FreeBSD drivers. It can be found here. (Nvidia is actually helping them, look in the recent news section.)

Note: I use Slackware. I refuse to use FreeBSD just to annoy my *BSD zealot friends. (NetBSD is really cool though, just don't tell them I said that.)
------
Defending the GPL from a commercial perspective is like defending the Microsft EULA from a moral perspective. - quartz
[ Parent ]

a slackware and FBSD user (4.00 / 1) (#14)
by tfogal on Thu Apr 04, 2002 at 10:52:16 PM EST

the system im writing this from is a dual boot slackware and FreeBSD box.. so you know.

i'd agree, /usr/ports/ is awesome. unfortunately, on freebsd, its required. the desktop software just doesn't work on BSD. for example, i couldnt get any version of enlightenment to compile. nor blackbox. mesa compiled fine, but gcc would give me really weird errors when i compiled my OGL apps.
/usr/local/include isnt in the default include path for egcs, and /usr/local/lib isnt in the default library path. this is VERY annoying, and caused me to be constantly hacking configure scripts and makefiles.
/usr/ports/ and similar systems are excellent; in my opinion, its RPM done right. but when you get down to it, i like to do everything myself. and this is a REAL hassle when half the things you compile require 1 or more patches. this also precludes using cvs for much of anything :(

on the other side, all the 'large' packages compile fine. better perhaps - X 4.2.0 compiled w/o a hitch on BSD; ive yet to successfully compile XF86 on linux. Apache, BIND, qmail, openssh, and so on all compile great. for this reason, and also with the arguments that FreeBSD is faster than linux (i wont support/denounce that in _this_ post), i would highly recommend BSD on production server systems.

not to rule out linux; its great. this gentoo sounds really slick, too; LFS but w/o as much hand-holding and documentation that talks down to you, is what it sounds like. i think ill definitely install gentoo on my next comp.

thanks for the heads up about gentoo.. and post your thoughts on BSD :).


I think kuro5hin will gradually turn into a forum for the discussion of professional wrestling. -- antizeus
[ Parent ]
slack + LFS here... (4.00 / 1) (#17)
by KiTaSuMbA on Thu Apr 04, 2002 at 11:14:58 PM EST

slack is great because of its flexibility and stability but still most packages are i386 (of course you could substitute them with beehive's i686 ones). LFS is even more flexible (you make a linux box out of it yourself) and provides that full optimization that compiling from source offers you but can give you some serious pains when it comes to complex interdependent packages. Gentoo's portage system combines the advantages of a distro with those of an all-source system. On my other post, about our "wannabe-distro" experiment I address the trouble of having to manage your way manualy on confs and patches. Up to now, we managed to script out our way for automatic patching (patches provided alongside with the original package) and basic .conf files creating but we are still pretty much in the dark on some installer issues (that means the project is still far away from being user-ready).
To give a rating, I say:
slack is really ok if you keep those HOW-TOs handy
LFS kicks *ss if you don't mind struggling a bit with documentation, patches, retrying again and again till you get what you want...
(that is, if you have both the mood and the time)
Gentoo, I'm going to try this ASAP but sounds like a very interesting thing.
FreeBSD: great choice if you don't care about those few extras that come linux-only and not POSIX
OpenBSD: if security becomes a passion... ;-)
other BSDs: haven't tried them, I abstain...
There is no Dopaminergic Pepperoni Kabal!
[ Parent ]
compiling XF86 - works for me? (4.00 / 1) (#50)
by gps on Fri Apr 05, 2002 at 01:35:52 PM EST

strange, i've compiled XFree86 3.x and 4.x without any problems at all on linux (using redhat 6.x and debian slink, potato and woody systems).

sure, it doesn't have a gnu autoconf but you don't really need to edit the *site.cf files for most installs other than pointing it to an alternate directory to install under to avoid clobbering your own distributions prebuild version.

[note: i avoid redhat 7.x as it doesn't include a stable compiler]

as for compiling on other OSes, X started out extreemly portable. XFree86 is used on -all- free unixes; it has nothing to do with linux; many of its developers use various BSDs, OS/2, etc.

[ Parent ]
RedHat (none / 0) (#60)
by sgp on Fri Apr 05, 2002 at 09:23:01 PM EST

Use the kgcc not gcc - they seem to include a stable compiler for building the kernel (under 7.2, anyway), IIRC (though I now use LinuxFromScratch, with gcc2.95.3)

There are 10 types of people in the world:
Those who understand binary, and those who don't.

[ Parent ]

From someone who has used both (4.66 / 3) (#21)
by regeya on Fri Apr 05, 2002 at 12:12:36 AM EST

In my opinion, in the areas that count, Portage is more mature.

Now, FreeBSD has more packages, yes, but Portage shows all the signs of being capable of surpassing Ports within a year. Not to mention that Ports relies largely on Python, while FreeBSD's Ports relies on FreeBSD's Make, FreeBSD's sh, etc., so there's the possibility of migrating Portage more easily to other systems (yes, I know some portage stuff uses bash.)

[ yokelpunk | kuro5hin diary ]
[ Parent ]

the "original" is getting old (none / 0) (#52)
by gps on Fri Apr 05, 2002 at 01:39:31 PM EST

Ports works, I love the ports system. However it is showing its age. gentoo's portage was written with lessons learned from bsd's ports system in mind.

[ Parent ]
Wonderful write-up. (4.50 / 2) (#10)
by nr0mx on Thu Apr 04, 2002 at 10:17:22 PM EST

I especially liked how you sneaked in the bit about "a rant about the DMCA". Makes the article that much more interesting. ;)



Yes (3.00 / 5) (#11)
by E r i c on Thu Apr 04, 2002 at 10:19:13 PM EST

It's nice to see a real technology article at a supposed technology site.

This isn't a flamebait directed at rusty or anyone, it's just an observance that most articles here tend to be about politics.

I blame my past transgressions on Eminem's music. Reform number five is currently in progress.
[ Parent ]
great! some coincidences... (4.50 / 2) (#15)
by KiTaSuMbA on Thu Apr 04, 2002 at 10:56:01 PM EST

Funny thing is I'm actually working with a couple of friends on a hopefully-to-be-distro based on an all-source system (we got the idea after building a couple of Linux From Scratch boxes and admired the speed).
However, if I get this right, some serious manual work is required to get the best out of gentoo (nano here, nano there). I have no prob with that personally (what could be "worse" than an LFS? :-) but our "vision" of the distro would be to ask some rather simple questions (like what you need on your kernel, wich packages to install etc.), probe the PCIs and go for the compile. What makes a gem out of gentoo is the portage idea, wich provides a lot more than just raw-dumping sources and going configure-make-make install (ie.: dependencies, that have always been a pain when working with sources).
I believe this (the all-from-source) type of linux systems to be our best way for the future: as systems' hardware capabilities increase rapidly, precompiled "compatible" (that means at least the basics are 386) binaries are holding back a linux box from offering all it can do. Plus, you avoid bloatware distros with 5 or more cds.
Trouble is, source-based distros are still intended only for advanced users and usually require broadband connections to download all these sources, and gentoo is a very good pass forward in adressing these issues. I'm definately going to make space on my disk to try it out!
There is no Dopaminergic Pepperoni Kabal!
Combining efforts? (3.00 / 1) (#38)
by stfrn on Fri Apr 05, 2002 at 10:04:00 AM EST

So would it be at all possible for you to make a menu based extension to gentoo? As that is the number one thing it seems to be missing, a way for less techy people to get into it.

"Man, I'm going to bed. I can't even insult people properly tonight." - Imperfect
What would you recomend to someone who doesn't like SPAM?
[ Parent ]
thus meta-distribution (5.00 / 1) (#51)
by Anonymous American on Fri Apr 05, 2002 at 01:38:58 PM EST

I think we will see easy to use distros based on Gentoo. Daniel Robbins likes to call it a meta-distribution.

[ Parent ]
Linux From Scratch (4.20 / 5) (#19)
by Witt on Thu Apr 04, 2002 at 11:42:19 PM EST

Although not a distribution per se, Linux From Scratch has a similar premise: you install everything from source, yourself, and as a result, you gain complete control over your system.

I've been using an LFS system myself for a couple of months. I learned tons while setting it up - how the init scripts work, where the configuration files are for various apps, how to configure sendmail, and the list goes on.

For adventurous people with a second box and a fast net connection, it's something worth looking into.

Trust your technolust
-- Jeremiah

My problem with LFS (none / 0) (#65)
by Cro Magnon on Mon Apr 08, 2002 at 03:54:12 PM EST

Since LFS is compiled from a host distro, you really need twice as much HD space as you do with one distro. And it's not something I could do in an evening, or even a weekend. After about a week trying to install it, I had an LFS system that could boot and compile programs, but not much else, and running out of room on my Slack partition. Eventually, I just deleted LFS to reclaim the extra space.
Information wants to be beer.
[ Parent ]
Trash Windows (none / 0) (#67)
by sgp on Fri Apr 19, 2002 at 07:22:40 PM EST

On my 6GB laptop, I had a 750MB Windows partition (hda1) - the rest was RedHat7.2 (hda2). Since I never used Windows anyway, I trashed it, and used RedHat to get LFS into a bootable state. Unfortunately my /home was part of /, so I just booted from a RedHat CDROM, deleted /bin, /usr, /etc, etc, and cpio'd hda1 to hda2. Grub was most obliging, and I now have a 750MB /spare partition which I use for scratch space (src for installs, etc)

There are 10 types of people in the world:
Those who understand binary, and those who don't.

[ Parent ]

Debian? (2.33 / 3) (#20)
by Khendon on Fri Apr 05, 2002 at 12:09:03 AM EST

I don't understand, what does this give you that debian doesn't?

Flexible, powerful? Debian has that.
Install a tiny base and add packages from there? Yep, debian again.
Resolve dependencies? Yeah, got that.
Build from packaged source? Yep.


BZNC (4.50 / 2) (#23)
by regeya on Fri Apr 05, 2002 at 12:18:15 AM EST

Build from packaged source? Yep.

Bad Zealot! No Cookie!

Portage, and by extension, Gentoo, offer a mechanism to build packages and recursively build dependencies. It's possible to do so in Debian, but it's a kludge.

Your next argument will be that it's unnecessary, it doesn't make sense, etc. You see, after dealing with the same argument so many times, I'm becoming something of a clairvoyant when dealing with the Debian self-congratulatory circle-jerk. And before you say it, I'm a fellow Debian user. I'm just tired of the attitude that Debian is perfect, because it's not. That sort of thinking leads to stagnation, which is starting to show itself.

So stop thinking in zealot-like terms, and start thinking in terms of what's out there that Debian does better than anyone else, and what areas Debian is outdone (many, if you'll care to learn what they are.)

[ yokelpunk | kuro5hin diary ]
[ Parent ]

Fellow Debian user... (3.00 / 1) (#25)
by ramses0 on Fri Apr 05, 2002 at 02:30:57 AM EST

Perhaps I should mention this in a more appropriate debian-forum, but I was just thinking of this the other day- Debian is in the fortunate/unfortunate position of having many packages, and many maintainers for those packages, but also needing developer brainpower to make those kinds of advances to the core tools (ie: apt, dpkg, installer, gui-front ends, etc).

Unfortunately, *.deb has not become the standard (and maybe it shouldn't), but in my eyes, it looks like it will be increasingly difficult to maintain the number of packages existing in debian and still make advances in technology or of the state of the art. Perhaps a lot of people are comfortable with the way things are and don't feel the need for change. But for now, for me, debian and apt-get is the best way I've seen for dealing with packages and package management.

--Robert
[ rate all comments , for great ju
[
Parent ]

Debian Developer here... (4.50 / 2) (#36)
by HoserHead on Fri Apr 05, 2002 at 09:06:01 AM EST

I don't know why you think it's difficult to keep the packages and also increase the state-of-the-art in Debian. The thing is, maintaining packages isn't that hard. It takes me maybe 1 hour out of a week dealing with bug reports and fixing things, and recompiling, and that's on a bad week.

The thing that takes up the real time is the development I do on my own software, namely mpg321. Others have their own babies: Joey Hess has debhelper and debconf, in addition to the other things he contributes to; Adam Heath has a good deal of the infrastructure; the list goes on and on.

There are very few maintainers who even if they wanted to couldn't spare the time to help out with other activies in Debian because of the needs of their packages. Branden Robinson is one (xfree86); Ben Collins, I believe, would be another (glibc). And I wouldn't put it past them to help out with the development of Debian itself, too.

The point is, Debian has 800+ developers. It's not hard to get enough peopel to develop the advances we need to make our distribution better.

[ Parent ]

Debian Developers (none / 0) (#54)
by TRS-80 on Fri Apr 05, 2002 at 02:41:25 PM EST

The two examples you give are actually invlovled with Debian at the highest level - Ben Collins is the outgoing Debian Project Leader, and Branden Robinson is one of this year's candidates in this year's Debian Project Leader elections.

[ Parent ]
...and? (none / 0) (#55)
by HoserHead on Fri Apr 05, 2002 at 03:37:57 PM EST

What's your point? So are Bdale and Raphael. Ben and Branden happen to maintain such time and labour-intensive packages that them trying to do a lot for the infrastructure of Debian would probably be a mistake, unless they had a lot of spare time.

[ Parent ]
reinventing the wheel (1.33 / 3) (#27)
by klash on Fri Apr 05, 2002 at 02:55:02 AM EST

Portage, and by extension, Gentoo, offer a mechanism to build packages and recursively build dependencies. It's possible to do so in Debian, but it's a kludge.

Just because the toolchain doesn't support it well doesn't mean it's a kludge, it just means the tool hasn't been written yet. The demand isn't there, Debian is binary-centric. But it could be supported very cleanly: every source package can build itself if the build-depends are installed, and every source package knows its build-depends. Put two and two together, and you have a clean and straightforward procedure for building packages recursively.

And before you say it, I'm a fellow Debian user. I'm just tired of the attitude that Debian is perfect, because it's not. That sort of thinking leads to stagnation, which is starting to show itself.

And the attitude that it is better to start from scratch than to improve a well-designed system that already exists is what leads to a world of 20 window managers, 10 widget toolkits, and 10,000 internet sites that run slash or scoop.

[ Parent ]

Dr. Pangloss replieth (4.00 / 1) (#30)
by cyberdruid on Fri Apr 05, 2002 at 04:47:01 AM EST

And the attitude that it is better to start from scratch than to improve a well-designed system that already exists is what leads to a world of 20 window managers, 10 widget toolkits, and 10,000 internet sites that run slash or scoop.

A good world. A world with choice and lack of monopoly. A world where one who does not like the decisions of one distro/wm/editor/whatever can simply change.

[ Parent ]

Happy medium (3.00 / 3) (#35)
by Khendon on Fri Apr 05, 2002 at 08:22:45 AM EST

I'd go for the centre path every time; extend what you've already got as far as feasible, but no further. There's no point in starting from scratch unless you can add something fundamentally different that couldn't easily be added to something that already exists.

So far, I've *still* not heard anything fundamentally different about gentoo that a simple tool change to debian wouldn't fix.

[ Parent ]
well (5.00 / 1) (#56)
by regeya on Fri Apr 05, 2002 at 03:59:54 PM EST

It might be nice to have a nice, simple, clearly-marked way for the end-user to rebuild packages from source, recursively both upward and downward. That way, when something like, say, libpng is updated, breaking unimportant packages like kde* :-> the end-user could have the option of either rebuilding or waiting for the maintainer to do what they're supposed to do (or, in the recent example I just cited, wait for the new package maintainers to get up to speed.)

[ yokelpunk | kuro5hin diary ]
[ Parent ]

You're not listening! BZNC! (none / 0) (#46)
by regeya on Fri Apr 05, 2002 at 12:53:59 PM EST

I'm lashing out against the attitude about the perfection of the Debian system, requiring no further innovation in the world of Free Software distrubition. It's a sucky attitude and I don't mind saying so.

Didn't mean to make you think that the wheel needed to be reinvented, but it certainly hasn't hurt Portage (which isn't based on Ports, BTW) a darn bit.

[ yokelpunk | kuro5hin diary ]
[ Parent ]

you've missed my point (none / 0) (#58)
by klash on Fri Apr 05, 2002 at 04:54:46 PM EST

I'm lashing out against the attitude about the perfection of the Debian system, requiring no further innovation in the world of Free Software distrubition. It's a sucky attitude and I don't mind saying so.

Debian is not perfect. not not not. I never claimed that it was. Why do you call me a zealot?

I'm lashing out against the attitude that it's better to ignore previous work and start from scratch than it is to improve existing systems.

Debian is not perfect. But it has a great start and almost 10 years of experience going for it. It needs the efforts of talented people to make it better. When these people take the not-invented-here attitude and write a similar system from scratch, Debian loses the chance to be improved by talented people, and these people create a project that will not achieve the same level of maturity for several years.

[ Parent ]

What makes you think Debian will change? (none / 0) (#68)
by dh003i on Sun Mar 09, 2003 at 10:06:11 PM EST

Debian currently offers binary-only packages, pre-compiled for an i386.  There is no apt-get source, then compile for i686 (e.g., 1.1GHz AMD Athlon).  Compiling everything optimized for your specific CPU is where you gain the performance advantage in Gentoo over Debian.  There is a significant optimization when talking about changing from compilation for i386 to compilation for i686, if your on a i686.  Debian doesn't offer you a way to these kind of processor-specific optimizations from the get-go.

I do believe, however, that Debian offers you just as much absolute control over what is installed and the configuration as does Gentoo.

So, what it boils down to is that a Gentoo install is going to be faster than a Debian install, due to the processor-specific optimizations.  That's what's in the favor of Gentoo.

However, Debian has as it's advantage that it's definately the most stable GNU/Linux distro, and is -- along with Slackware -- the most mature GNU/Linux distribution.

Really, though, Debian developers don't have to do much to gain the extra performance advantages that Gentoo has, without the stability issues that Gentoo has.

Really, all they need to create a Net-CD install ISO (with ReiserFS support) that sets you up with the 2.4 kernel but does it in a similar way as Gentoo.  Allow you to download the latest STABLE source and compile it yourself.  It should give you the option to ues GCC 4.x, rather than the older version of GCC that Debian uses.  GCC 4.x has significant compiling (as in optimization) advantages over 3.x, which will produce faster compiled code.  Better yet, Debian developers can allow you to do all of this optimized compilation while still using their menu-based install system, which is (though a nightmare) not as much of a nightmare as Gentoo install.

Social Security is a pyramid scam.
[ Parent ]

No, read what I said... (2.50 / 2) (#28)
by Khendon on Fri Apr 05, 2002 at 02:56:48 AM EST

I didn't say debian was perfect, I said that nothing mentioned in the article struck me as being new.

[ Parent ]
Of course not (4.00 / 2) (#43)
by prometheus on Fri Apr 05, 2002 at 11:39:13 AM EST

Being that Portage is based on Ports from the BSDs, and the article said so, we already know there's nothing new here. It doesn't reduce the coolness factor for people who think that's cool.
--
--
<omnifarad> We've got a guy killing people in DC without regard for his astro van's horrible fuel economy
[ Parent ]
I'd argue that you did. (none / 0) (#61)
by regeya on Fri Apr 05, 2002 at 10:10:04 PM EST

Try the parent comment practically gushing over Debian's supposed perfection.


[ yokelpunk | kuro5hin diary ]
[ Parent ]

Universal Machines (3.66 / 3) (#59)
by forii on Fri Apr 05, 2002 at 06:20:02 PM EST

I don't understand, what does this give you that debian doesn't?

Flexible, powerful? Debian has that.

Install a tiny base and add packages from there? Yep, debian again.

Resolve dependencies? Yeah, got that.

Build from packaged source? Yep.

A suitably configured Turing Machine can do all this too. What's your point?
Proud member of the ACLU, the NRA, and the EFF.
[ Parent ]

Optimizations? (5.00 / 1) (#66)
by Hal9001 on Sun Apr 14, 2002 at 03:29:06 PM EST

Everyone seems to have missed a big advantage of Gentoo and building from sources, which is that you can optimize the resulting binaries for your machine. This can result in significant performance benefits and smaller executables.

[ Parent ]
Gentoo is great (4.66 / 3) (#22)
by aaron on Fri Apr 05, 2002 at 12:14:55 AM EST

I've done a few Gentoo installs on test boxes during the pre-release period, and submitted a few bugs and a new ebuild. (Incidentally, the ebuild/emerge system makes it very easy to add package-management to software that's not already in Portage.) I've been very happy with it, and it'll be going on my next workstation.

I had it installed on my laptop (compaq presario 1200XL126) for a while, but encountered an odd lockup problem. I suspected it to be related to APM, as it would only happen if I left the machine alone for a while, but unfortunately I need my laptop to be working, so freebsd went back on it. If anybody has suggestions on that, they're certainly welcome. ;)

One comment on the writeup -- emerge can take an arbitrary number of packages as arguments. The "emerge xfsprogs;emerge bitchx;emerge vim;emerge links" command can be reduced to the more simple "emerge xfsprogs bitchx vim links", and portage will calculate dependencies and install everything in the correct order. Great work, gentoo developers!

Ahh thanks! (none / 0) (#53)
by Anonymous American on Fri Apr 05, 2002 at 01:41:32 PM EST

One comment on the writeup -- emerge can take an arbitrary number of packages as arguments. The "emerge xfsprogs;emerge bitchx;emerge vim;emerge links" command can be reduced to the more simple "emerge xfsprogs bitchx vim links", and portage will calculate dependencies and install everything in the correct order. Great work, gentoo developers!

Thanks for the tip!



[ Parent ]
gentoo should consider... (5.00 / 4) (#24)
by astyanax on Fri Apr 05, 2002 at 12:50:41 AM EST

using the --disable-wrapping-as-root flag to ./configure for its nano binary on the installation media. This flag automatically disables wrapping if your UID==0. Mind you, there's no way to turn wrapping ON for root if you use this flag when creating your binary, but why would you want to? ;-)

No, they should consider... (3.75 / 4) (#34)
by Khendon on Fri Apr 05, 2002 at 08:19:22 AM EST

...not using such a horrific editor in the first place. Anything with roots (however distant) at the university of washington deserves burning.

[ Parent ]
Um (4.00 / 4) (#41)
by astyanax on Fri Apr 05, 2002 at 10:51:21 AM EST

What specifically is so horrific about nano? Just because it is a clone of a terribly licensed program, or are there specific shortcomings you would like addressed?

[ Parent ]
uh.. (3.66 / 3) (#26)
by kimpton on Fri Apr 05, 2002 at 02:39:34 AM EST

This is bare metal Linux, powerful and dangerous. If you do something without thinking you may fall into a bucket of pain.

You're installing an OS, not wrestling an alligator.

An interesting read on a quiet friday morning though. Thank you.

what a silly claim (1.80 / 5) (#29)
by klash on Fri Apr 05, 2002 at 03:12:54 AM EST

As an added bonus I got something I wasn't even expecting. Speed. Blinding, blazing, incredible speed.

This is baseless sensationalism.

If your computer runs faster with Gentoo than with other Linux distributions, it can only be for two reasons:

  1. Your running programs are consuming fewer resources like RAM and CPU time.
  2. Your kernel configuration is better tuned for your system.
Neither of these is specific to your distribution. Any Linux distribution should allow a minimal install that gives you only the necessities (I know Debian does, and probably Red Had too). And any distribution will allow you to compile your own kernel.

Not true (4.00 / 1) (#31)
by xtremex on Fri Apr 05, 2002 at 05:15:36 AM EST

By default, every distro has it's binaries compiled with debugging info (fat binaries) , and the tri-install command does as well, unless you specifically omit it. I have Gentoo on MY laptop, and it is truly truly fast. Next, I'm going to do Sorcerer Linux.

[ Parent ]
This is totally and completely untrue (4.50 / 2) (#37)
by HoserHead on Fri Apr 05, 2002 at 09:09:45 AM EST

I don't know if other distributions do it differently, but Debian specifically does not compile their binaries with debugging information, and on install the default is to run strip on the binaries, too.

I don't know where you get the idea that we install debug binaries by default, but that'd not only be dumb but detrimental to our users. Evolution is big enough as it is; do you really want to bloat the package by a further 50% with debug symbols?

[ Parent ]

I used to be a debian user.... (none / 0) (#57)
by xtremex on Fri Apr 05, 2002 at 04:52:27 PM EST

and I didn't know this about debian. I use mandrake now, and when I do config, make, make install, it compiles with debugging.(I just work up, so I might be wrong)

[ Parent ]
Compiles with debugging != installs with debugging (none / 0) (#63)
by HoserHead on Sat Apr 06, 2002 at 01:52:04 AM EST

When you use the -g option for GCC, it includes all the debugging information you need into the binary. When you use install -s (the default, usually), it strips all the debugging information off. Thus, you get a clean binary.

That being said, the way most new Debian packages are made now (as is specified in the new Policy), they by default compile without -g and with install -s, and allow environment variables to control whether it's compiled with debug information and whether debug symbols are stripped at install time.

[ Parent ]

glibc (4.50 / 2) (#40)
by sgp on Fri Apr 05, 2002 at 10:21:11 AM EST

I use Linuxfromscratch (similar to gentoo) and found a huge speedup on my system as compared to RedHat7.2. I don't put this down to the kernel (I was running a handrolled kernel on RedHat anyway) but to glibc. Every application calls glibc, which if it's not built to your own box, makes a big difference to the speed of everything else. The cumulative effect is noticeable.

There are 10 types of people in the world:
Those who understand binary, and those who don't.

[ Parent ]

Compiler Optimizations (5.00 / 2) (#44)
by prometheus on Fri Apr 05, 2002 at 11:51:29 AM EST

Actually, you get a fairly large speedup when you tell gcc to compile things for your processor's architecture. i686, K6-II/III, and Athlons all have different optimal orderings and alignment for the machine code which take advantage of the differences in their ability to execute code fast. Compiling for i386 is one of the slowest things you can do, even without debugging symbols.

And, there are a load of other optimizations you can have GCC do which speed things up even more that you can specify when you build things from source. Specifying -O2 alone can speed things up a lot as well, probably more than compiling for a specific processor variant, for example.

I should dig out some timing tests I did and post them, I guess.
--
--
<omnifarad> We've got a guy killing people in DC without regard for his astro van's horrible fuel economy
[ Parent ]
A pile load of gotchas (4.25 / 4) (#32)
by PigleT on Fri Apr 05, 2002 at 05:57:40 AM EST

I've recently flipped from using Debian to Gentoo, simply because downloading masses of binary packages in the hope of staying uptodate AND resolving dependencies AND doing the same again for a version-1 to version-2 build# change really isn't the best use of cable modem, and where debian's recursive dependency stuff works, it's binary only - there is no "apt-get -r source" that does the same as gentoo.

Other things that aren't in the article above that you're bound to stumble across:

a) it *really* helps if you hack /usr/sbin/emerge so that it calls `rsync -z' at the appropriate moment, instead of rsync-ing the whole 30M across.

b) it helps if you remember to run lilo

c) you can specify multiple packages to emerge on the one command, none of this "; emerge somethingelse" crud.
However, the syntax to emerge is highly inconsistent; to me, "--unmerge" is a verb, so are "update" and "system" - and "rsync" is both a package *and* a verb. Of course you can work around it in the case of rsync by specifying a package-group/rsync instead, but I don't *want* to do that. Make it accept package-names by default on the commandline, and either have multiple command-names or various --install or --unmerge verbs, either way, don't mix and match..
A command to list installed versions from the db would be nice as well.

d) when the install notes tell you to set CONFIG_PROTECT="", they don't mean you to do the same thing as part of your regular daily `emerge rsync; emerge --world update --buildpkg --pretend' cycle.

e) emerge --unmerge --safe *isn't*. The whole upgrading process is a bit dicey IMO; you get bits of old packages left lying around, which in the case of mozilla and galeon was moderately wasteful on space.

But I still *like* it. Long may gentoo continue for those of use who like from-source. Even better still, can someone port it to PPC then I can go out and buy a replacement powerbook *pleeeease*?! ;)
~Tim -- We stood in the moonlight and the river flowed
Gentoo PPC (5.00 / 1) (#47)
by pvdabeel on Fri Apr 05, 2002 at 12:55:43 PM EST

Even better still, can someone port it toP PC then I can go out and buy a replacement powerbook *pleeeease*?! ;) Gentoo PPC homepage Now go out and buy a replacment powerbook :-)

[ Parent ]
Ooooooooook! (none / 0) (#48)
by PigleT on Fri Apr 05, 2002 at 01:24:15 PM EST

"Gentoo PPC homepage"

Ooooh. Oooh ooh. Mama mia. Want powerbook NOW! :8)

Ta :)

~Tim -- We stood in the moonlight and the river flowed
[ Parent ]
Great Article (4.33 / 3) (#45)
by prometheus on Fri Apr 05, 2002 at 11:55:00 AM EST

I know it's been said before here, but this is excellent. I'm happy to see something besides politics.

I installed Gentoo a few times, and really liked it, and as nice as Portage is, at the time I wasn't looking for a Package Manager so much as a way to just build software with a certain set of options.

And I have an irrational dislike for SysV init scripts, which Gentoo has, sort of...

It's irrational, so I'll try not to get into a flame war, since nothing I say about it will be rational...
--
--
<omnifarad> We've got a guy killing people in DC without regard for his astro van's horrible fuel economy
What is the 'net reliance? (5.00 / 1) (#62)
by static on Fri Apr 05, 2002 at 10:34:15 PM EST

Or, put another way, does Gentoo expect you to have a large, unmetered Internet link?

This is not a rant, but like most people outside North America, I have a metered Internet link (i.e. I pay per Mb downloaded). So the last thing I want is a package that wants to download many megabytes of stuff to install. In fact, it is often cheaper for me to acquire a proper distro CD than to download an ISO!

So. How does Gentoo cater for this scenario?

Wade.

Yes. (4.50 / 2) (#64)
by Anonymous American on Sat Apr 06, 2002 at 08:10:52 PM EST

Yeah, Gentoo pretty much assumes you have a unmetered internet connection. There are ways around it, but right now you would have to roll your own. Soon gentoo.org plans to sell cd's ... I wonder if they will contain mirrors of most of the packages.

[ Parent ]
Installing Gentoo Linux | 68 comments (62 topical, 6 editorial, 0 hidden)
Display: Sort:

kuro5hin.org

[XML]
All trademarks and copyrights on this page are owned by their respective companies. The Rest 2000 - Present Kuro5hin.org Inc.
See our legalese page for copyright policies. Please also read our Privacy Policy.
Kuro5hin.org is powered by Free Software, including Apache, Perl, and Linux, The Scoop Engine that runs this site is freely available, under the terms of the GPL.
Need some help? Email help@kuro5hin.org.
My heart's the long stairs.

Powered by Scoop create account | help/FAQ | mission | links | search | IRC | YOU choose the stories!