Friday, April 23, 2010

After Upgrading, or why I still use Gentoo

Another blogger commented on Gentoo being "bleeding edge", and told a story of how his system didn't perform all that well when he chose builds from unstable.

Yep, that happens.  I used to use Debian extensively, and switched to Gentoo a while back. I still have one Debian box around here somewhere, but I use Gentoo on the 4 or 5 others.

For me, the switch to Gentoo was predicated on not being able to find prebuilt .debs for all the packages I wanted to install simultaneously. I mean, sure, I could find this deb, or that deb, or the other deb, scattered about various archives, but they each depended on different versions and patches of other base packages and, as a result, couldn't be installed on the same system. Same problem but worse for fedora. Success with these distros seems predicated on wanting to build a system that does the same combination of things that someone else wants and has built some binaries to do.

By contrast, with Gentoo you use a combination of flags and the world list to specify what the box is for, and it builds all your packages from source, taking into account everything else you already have installed. Thus it neatly sidestepped the problem I was having with prebuilt packages.

I also wanted to build a home security gateway on a low power box (an analyst friend comment that it used less power than her toothbrush), with little ram, that runs a weird cpu, and gentoo is really good at that, allowing me to fine tune what packages I want installed, and even cpu architecture and compile flags and such to make it as efficient as possible on my tiny system.  There's little chance I would have found debian packages prebuilt for that system.

So for me, Gentoo has done a lot of what I need.

So far as installing packages from unstable ... well, that used to be painful for me as well with Debian. Gentoo is no worse.

But the underlying pain that Chip expresses is that Gentoo is indeed a bit bleeding edge, and yeah, requires a little fiddling and a bit of devil-may-care when upgrading.

An issue I've encountered with Gentoo is "there is no way to get there from here."  A common example is trying to upgrade the udev package and either hotplug or lvm packages - whichever one you try to upgrade first, won't work. Upgrade udev first and the new udev isn't compatible with old hotplug. The opposite order, same problem.

I've even run into a case in which a new install on a clean box fails because 2 packages each depend on the other. C'mon, that's plain wrong.

There are scads of cases of this, examples are all over the gentoo bug system.

There are a couple of workarounds that can help. One, which is appropriate if the packages will build fine but might not work or have just not been listed as working together, is to build those packages without dependencies to get the right versions in place, then rebuild. Another workaround is to tune USE flags (another way of tuning the dependencies) to get the packages in place, then return the USE flags the way you want and rebuild.  If you're feeling particularly frisky, you can uninstall the existing udev, hotplug or lvm2 and then reinstall them, so there are no incompatible older versions in the way.  And hope you don't have any problems along that patch that require a reboot.

Sometimes these work, sometimes they don't. I can understand why many folks wouldn't use Gentoo for a business-critical system. Or even a business-useful one.

Me .. well, my wife's TV runs on Gentoo. She's still my wife. :)

The saving grace for me has been Gentoo's ability to create a binary package from your running system.  Certain key packages, I create binaries before I emerge a new version, and if things don't work I can return to that version, including my config settings, easily, even though it may not be supported in the distro any more.  This isn't very practical for a wholesale kde upgrade, but for some packages like postfix or shorewall or even mythtv-* ... when I've really needed to back out an upgrade, it has worked fine.

No comments:

Post a Comment