[ << ] [ < ] [ Home ] [ > ] [ >> ]


11. Finalizing your Gentoo Installation

Content:

11.a. User Administration

Adding a User for Daily Use

Working as root on a Unix/Linux system is dangerous and should be avoided as much as possible. Therefore it is strongly recommended to add a user for day-to-day use.

The groups the user is member of define what activities the user can perform. The following table lists a number of important groups you might wish to use:

Group Description
audio be able to access the audio devices
cdrom be able to directly access cdrom devices
floppy be able to directly access floppy devices
games be able to play games
usb be able to access USB devices
video be able to access video capturing hardware and doing hardware acceleration
wheel be able to use su

For instance, to create a user called john who is member of the wheel, users and audio groups, log in as root first (only root can create users) and run useradd:

Code listing 1: Adding a user for day-to-day use

Login: root
Password: (Your root password)

# useradd -m -G users,wheel,audio -s /bin/bash john
# passwd john
Password: (Enter the password for john)
Re-enter password: (Re-enter the password to verify)

If a user ever needs to perform some task as root, they can use su - to temporarily receive root privileges. Another way is to use the sudo package which is, if correctly configured, very secure.

11.b. Optional: Install GRP Packages

Important: This part is for GRP users only. Other users should skip this part and continue with Where to go from here?.

Now that your system is booted, log on as the user you created (for instance, john) and use su - to gain root privileges:

Code listing 2: Gaining root privileges

$ su -
Password: (Enter your root password)

Now we need to change the Portage configuration to look for the prebuilt binaries from the second CD (Gentoo Packages CD). First mount this CD:

Code listing 3: Mount the Packages CD

(Put the Gentoo Packages CD in the CD tray)
# mount /mnt/cdrom

Now configure Portage to use /mnt/cdrom for its prebuilt packages:

Code listing 4: Configuring Portage to use /mnt/cdrom

# ls /mnt/cdrom

(If there is a /mnt/cdrom/packages directory:)
# export PKGDIR="/mnt/cdrom/packages"

(Otherwise:)
# export PKGDIR="/mnt/cdrom"

Now install the packages you want. The Packages CD contains several prebuilt binaries, for instance KDE:

Code listing 5: Installing KDE

# emerge --usepkg kde

Be sure to install the binaries now. When you do an emerge --sync to update Portage (as you will learn later), the prebuilt binaries might not match against the ebuilds in your updated Portage. You can try to circumvent this by using emerge --usepkgonly instead of emerge --usepkg.

Congratulations, your system is now fully equipped! Continue with Where to go from here? to learn more about Gentoo.


[ << ] [ < ] [ Home ] [ > ] [ >> ]