Gentoo - portage usage, tips and tricks
By: John McFarlane
<john.mcfarlane@rockfloat.com>
This document was originally created on 11/18/2005
Last updated:
11/18/2005 @ 10:00
Abstract:
This document outlines how to use portage to install things,
and keep your setup current on patches.
Table of Contents:
1. Update your list of packages
Before you ever install something on Gentoo you want to update
your list of packages. This is analgous to
apt-get -update. Remember that this doesn't install
any softare, rather it just updates information about packages:
Perform the update:
I'm finished with this step
Perform the update:
root# emerge sync
I recommend running this via cron daily, that way it's always up to date.
2. Update your system - you don't want to get r00ted
Now that you have an up to date Portage tree, you want to update
the actual softare on your system.
I'm finished with this step
root# emerge -uDa world
Here's what that means:
- emerge (install)
- u (update)
- D (deep, so dependancies are also used)
- a (ask permission before installing!)
3. Check to see if any config files need to be updated
Portage will automatically handle any trivial changes, but sometimes
there are changes that you need to manage.
I'm finished with this step
root# etc-update
Here's what you do next:
-
Look at the list of configuration files it gives you. Look
for any config files you care about, or recognize. For example
if you run apache or php and there are config files related
to either, then manage these first.
- Type the number next to the config file
- example: 4 This will select this particular config and present you with a list of the differences (in less)
- Hit q to exit less
- Now you should see a menu asking what you want to do. Pick...
- Once you've dealt with all config's that you care about you can feel free to let the system take care of the rest. Type -3 and it will go thru and replace each config with the updated version. For each one it will prompt to delete the old version, go ahead and hit y for each one.
This document was originally created on 11/18/2005
Disclaimer:
This page is not endorsed by gentoo.org or any other cool
cats. Any information provided in this document is to be used
at your own risk.