Руководство по установке и настройке Fedora 9

Fedora 9 (SULPHUR) is here! As always it comes along with some new and bleeding edge features such as 2.6.25 kernel, Gnome 2.22.1, KDE 3.5.9, OpenOffice 2.4, Firefox 3 and PackageKit, a new cross-distribution (!) software management system that has replaced pirut and pup. I've written this guide to help new Fedora users to easilly configure their system. So, grub a Fedora installation disk and let's move on to our system's configuration part.

1. Upgrading from Fedora 7/8

A new application has been developed in order to allow Fedora users easilly upgrade to the new release without having to download and cd/dvd. Preupgrade resolves all dependencies, downloads the needed packages, configures grub and finally asks the user just to reboot to complete the upgrade. Install and run Preupgrade by typing:

su -c 'yum install preupgrade'
preupgrade
Select Fedora 9 and after a while you'll be asked to reboot in your upgraded Fedora 9 system!

2. Configuring sudo

**Note: In my previous Fedora guides I've been using sudo for the commands that needed root access. However since many users don't want to add their user to the sudoers I've decided to change all the commands to the su -c 'command here' way. If you want to type many commands as root it is better to type only the first time su - and give your root password. After that you become root until you type exit. Of course it's up to you to configure sudo or not.

* Modifing sudoers file
Normally if you want to run a command which requires root privileges you first have to type 'su -', type your root password and then type the command. However you can bypass this by using the 'sudo' command. But first you have to configure it like this:

su --login -c 'visudo'
Now go below the line:

root ALL=(ALL) ALL
press a, and type the following

username ALL=(ALL) ALL
where username is the username you use to login. Next press Escape.

Now, if you want to be promted for your root password each time you use the sudo command go to this line:

# %wheel ALL=(ALL) ALL
and with your cursor pointing on # press x

If you don't want to be promted for your root password each time you use the sudo command go to this line:

# %wheel ALL=(ALL) NOPASSWD: ALL
and with your cursor pointing on # press x

Next, press :wq to save and exit. (type the : as well)

* Adding your user to the wheel group
Just type:

su -c 'gpasswd -a username wheel'
* Adding sbin to your PATH
This step is optional but saves you a lot of time since many commands are located under /usr/sbin and /sbin and when you are trying to execute them as a single user from the terminal you must type their full path. To avoid this type:

su -c 'gedit ~/.bash_profile'
Then change the following line:

PATH=$PATH:$HOME/bin
to

PATH=$PATH:/usr/sbin:/sbin:$HOME/bin
* Testing sudo
To test if you have done it correctly as a simple user type:

$ sudo whoami
If everything is working properly the command should return the word 'root'.

3. Configuring yum

* Basic Commands
Below there are the most common commands you will use for yum, Fedora's Package Management System. You can find a more detailed description of those along with some more commands if you type:

yum --help
man yum
* Install an application

su -c 'yum install application_name'
* Remove an application

su -c 'yum remove application_name'
* Install an rpm from your hard disk using yum to resolve dependencies

su -c 'yum localinstall application_name'
* Search for an application

su -c 'yum search application_name'
* Find info about an application

su -c 'yum info application_name'
* Update the whole system

su -c 'yum update'
* Enable a repository

su -c 'yum --enablerepo=repo_name'
* Disable a repository

su -c 'yum --disablerepo=repo_name'
* Importing Fedora GPG keys
Fedora has 2 basic repositories named 'fedora' and 'updates'. To use them and not get errors about unsigned packages you must import their GPG keys. Open a terminal and type:

su -c 'rpm --import /etc/pki/rpm-gpg/*'
* Third party Repositories
Fedora software repositories don't include support for MP3, DVD and Video playback/recording because of patent licences. For this reason you have to install that software from third party repositories. But don't worry, this is pretty easy! ;)

Now we are going to install the Livna Repository, a third party repo which provides many multimedia codecs and additional applications. For the rest of this guide I will assume that you have installed and enabled the Livna Repository. So, open a terminal and type:

su -c 'rpm -hiv http://rpm.livna.org/livna-release-9.rpm'
su -c 'rpm --import http://rpm.livna.org/RPM-LIVNA-GPG-KEY'
* Graphical Interface for yum
If you don't like typing commands in your console you can use Fedora's Graphical interface for yum. You can find it under System -> Administration -> Add/Remove Software.

You can also install yumex for this reason.

su -c 'yum install yumex'
* Configure yum through Proxy
If you are behind an http proxy server and you want yum to connect to the internet through that proxy open a terminal and type:

su -c 'gedit /etc/yum.conf'
Add this line in the yum configuration

proxy=http://ip:port/
where ip is your proxy's ip address and port is the port the proxy listens to. Don't forget the / after the port number. Save and exit.

4. Configuring Services

You can easilly select which services should run when you boot your system you can use Fedora's services configuration utility which can be found under System -> Administration -> Services.

For a detailed description on all services and daemons read my Fedora Services Guide .

5. Installing video drivers

**Note: To install many of the following packages you must have the Livna Repository enabled as described here .

* Installing nVidia driver
Nvidia 173.14.05 now supports X.Org server 1.5 which means you can now have 3D support in Fedora 9. Just type:

su -c 'yum install kmod-nvidia xorg-x11-drv-nvidia xorg-x11-drv-nvidia-lib'

* Installing ATi driver
Currently there aren't usable drivers for Fedora 9 because of the new version of X.Org it uses. A solution can be found in fedoraforums.org

6. Installing Microsoft fonts

Fedora uses Liberation and DejaVu fonts which are installed by default and look pretty smooth and nice, plus they are open source.

If you insist on using the microsoft fonts you can download and install the msttcorefonts rpm like this.

wget http://www.my-guides.net/en/images/stories/fedora9/msttcore-fonts-2.0-2....
su -c 'rpm -ivh msttcore-fonts-2.0-2.noarch.rpm'
I built it myself using the msttcore-fonts-2.0-2.spec from Fedora-devel mailing list which unlke msttcore-fonts-2.0-1.spec doesn't require installing the xfs server. Therefore is ideal for Fedora 8 and 9. It includes Arial, Andale, Comic Sans, Courier New, Georgia, Impact, Tahoma, Times, Trebuchet MS, Verdana and Webdings fonts.

The procedure just in case you want to built it yourself is the following.

su -c 'yum install rpmdevtools rpm-build cabextract'
rpmdev-setuptree
cd ~/rpmbuild/SPECS/
wget http://www.my-guides.net/en/images/stories/fedora9/msttcore-fonts-2.0-2....
rpmbuild -bb msttcore-fonts-2.0-2.spec
cd ~/rpmbuild/RPMS/noarch/
su -c 'rpm -ivh msttcore-fonts-2.0-2.noarch.rpm'

Now you can change your fonts through System -> Prefereces Look and Feel -> Appearance -> Fonts

7. Configuring Nautilus

* Open each folder in the same window
Go to System -> Preferences -> Personal -> File Management and in the Behavior tab select the Always open in browser windows option.

Now you will use the File Browser to navigate through your folders.

* Open Terminal here
It's very useful to have an 'Open Terminal here' command to easilly open a folder in terminal while you are browsing it in Nautilus. To do so type:

su -c 'yum install nautilus-open-terminal'
log out and then log in, right click in a Nautilus window and you'll see the command.

* Enable Num Lock on GNOME startup
su -c 'yum install numlockx
su -c 'cp /etc/gdm/Init/Default /etc/gdm/Init/Default_backup'
su -c 'gedit /etc/gdm/Init/Default'
And add the following lines at the end of the file.

if [ -x /usr/bin/numlockx ]; then
/usr/bin/numlockx on
fi
Save and exit. Now restart X server and check if num lock light is on.

8. Configuring Firefox

* Acrobat Plugin
To be able to view pdf documents through Firefox you must have adobe acrobat reader installed as described here.

* Flash Plugin
Go to Adobe's site and select the 'Yum for Linux' option. Open the file with the default Package Installer. It will install it for you.

Next open the System -> Administartion -> Add/Remove Software and search for flash-plugin. Select to install the plugin and import the GPG key or just type:

su -c 'yum install flash-plugin'

Finally restart Firefox and type about:plugins in the address bar. You should Shockwave Flash among the plugins.

Users of Fedora x86_64 must install the nspluginwrapper.i386 package to enable the 32-bit Adobe Flash plugin in x86_64 Firefox and the pulseaudio-libs.i386 package to enable sound from the plugin..

Create the 32bit mozilla plugin directory using this command:

su -c 'mkdir -p /usr/lib/mozilla/plugins'
Install the nspluginwrapper.i386, nspluginwrapper.x86_64, and pulseaudio-libs.i386 packages:

su -c 'yum -y install nspluginwrapper.{i386,x86_64} pulseaudio-libs.i386'
Install flash-plugin as shown above.

Run mozilla-plugin-config to register the flash plugin:

su -c 'mozilla-plugin-config -i -g -v'
Finally restart Firefox and type about:plugins in the address bar. You should Shockwave Flash among the plugins.

* Mplayer Plugin
Although Fedora 9 has totem-mozplugin preinstalled it doesn't seem to work. I prefer the mplayer plugin for Firefox but at this time there is no Livna package. To install it type:

su -c 'yum remove totem-mozplugin'
su -c 'yum install mplayerplug-in'
You should also install additional codecs as described here to support wmv video playback.

* java Plugin
Fedora 9 comes with java openjdk plugin preinstalled. However you may face some problems when trying to run certain java applets. For more information check here .

If you don't have it installed type:

su -c 'yum install java-1.6.0-openjdk{,-plugin}'
In case you have upgraded from Fedora 8 you should first remove java-icedtead like this:

su -c "yum erase java-1.7.0-icedtea{,-plugin}"
You can always install SUN's JRE as described here.

* mms streaming play
In the address bar type:

about:config
Right click somewhere and select NEW and then STRING. Type this in the box:

network.protocol-handler.app.mms
Click ok and in the box type the program you want to open the streaming media with, such as /usr/bin/mplayer.

Next right click again and select NEW and then BOOLEAN. Type this in the box:

network.protocol-handler.external.mms
Click ok and then type:

true
* Set backspace button
By default in Fedora's Firefox when you press the backspace button it does nothing. If you want backspace to take you to the previous page type in the address bar:

about:config
and in Filter box type:

browser.backspace_action
Right click on it, select Modify and change its value from 2 to 0. Restart Firefox and the backspace will be set.

9. Configuring e-mail client

Fedora 9 has evolution as the default e-mail client. Of course you can install Thunderbird if you prefer it. Just type:

su -c 'yum install Thunderbird'
Now you can find Thunderbird under Applications -> Internet -> Thunderbird Mail Client. To make it the default Fedora mail client go to System -> Preferences -> Personal -> Preferred Applications and under Mail Reader select Thunderbird Mail.

10. MP3 and Audio players

**Note: To install many of the following packages you must have the Livna Repository enabled as described here .

The first time you will try to play an mp3 file Totem Movie PLayer will come up and it will through you a message about Proprietary formats. Here you can download the free fluendo mp3 decoder which will allow you to play mp3s just fine as shown in the screenshots below.

However fluendo doesn't allow you to encode mp3s. In that case you can install mp3 codes from Livna as shown below.

At any time you can uninstall the fluendo codec simply by typing:

rm ~/.gstreamer-0.10/plugins/libgstflump3dec.so
* Rhythmbox
I believe that Rhythmbox is a better mp3 player than the default Totem for Gnome users. You can find it under Applications -> Sound & Video -> Rhythmbox Music Player. If you don't have it, to install it type:

su -c 'yum install gstreamer rhythmbox'
To make all mp3 files open by default with Rhytmbox right click on an mp3 file and select 'Open with Other Application...'. Click on Rhytmbox Music Player and you're done.

To add mp3 and other audio support type:

su -c 'yum install gstreamer-plugins-good gstreamer-plugins-bad gstreamer-plugins-ugly'
* amaroK
amaroK is a pretty good audio/mp3 player for KDE. Of course you can install it under Gnome or any other Desktop Environment too. To install it and add mp3 support type:

su -c 'yum install amarok amarok-extras-nonfree'
* Audacious
Audacious is another audio player similar to old winamp 2.x. To install it type:

su -c 'yum install audacious audacious-plugins-nonfree-*'
If you want to use your winamp 2.x skin with audacious simply copy winamp's *.wsz skin to /usr/share/audacious/Skins/

If your tags are in a different encoding than utf8 you can force audacious to use it:

Preferences -> Playlist -> Metadata -> Fallback character encoding -> iso8859-7

If you want to add in queue mp3s when double clicked edit this file:

su -c 'nano /usr/share/applications/fedora-audacious.desktop'
And change Exec=audacious to Exec=audacious -e

* XMMS
This audio player is no longer used, you could try audacious instead, but if you still want it type:

su -c 'yum install xmms xmms-libs xmms-mp3'
11. DVD & Video

**Note: To install many of the following packages you must have the Livna Repository enabled as described here .

* DVD playback
In order to play DVDs you must install the appropriate codecs.

su -c 'yum install libdvdcss libdvdread libdvdnav lsdvd libdvbpsi'
* Video files playback
If you have previously set up mp3 playback additional packages would have been installed as dependencies. These packages include video codecs such as xvidcore, ffmpeg and other.

To check some of them type:

su -c 'yum install ffmpeg ffmpeg-compat libmatrosca xvidcore'
Finally to be able to play some closed window formats such as wmv files type the following:

cd ~/Download
wget http://www1.mplayerhq.hu/MPlayer/releases/codecs/all-20071007.tar.bz2
tar -jxf all-20071007.tar.bz2
su -c 'mkdir -p /usr/local/lib/codecs'
su -c 'cp all-20071007/* /usr/local/lib/codecs'
rm -rf all-20071007
Now choose one of the following Video players and install it.

* Totem
Fedora 9 has installed Totem Movie Player. If you want to play DVD files also with totem type:

su -c 'yum install totem-xine totem-xine-plparser xine-lib-extras xine-lib-extras-nonfree'
* Mplayer/SMPlayer
I prefer mplayer and smplayer (mplayer's GUI) for video playback. It supports almost any video type, external subtitles as well as DVD playback as long as you have the needed codecs installed as shown previously.

su -c 'yum install mplayer smplayer'
Open smplayer from Applications -> Sound & Video -> SMPlayer

* VLC
VLC (Video Lan Client) supports almost any video type without the need of installing external codecs.

su -c 'yum install vlc'
* kaffeine
kaffeine is another KDE media player that uses the xine engine.

su -c 'yum install kaffeine'
su -c 'yum install xine-lib-extras xine-lib-extras-nonfree'
* RealPlayer
An opensource alternative to RealPlayer is HelixPlayer. You can try it by typing:

su -c 'yum install HelixPlayer'
If you don't like it you can download RealPlayer rpm from here . Next open a terminal and go to the Folder you downloaded it. Install it by typing:

su -c 'yum remove HelixPlayer'
su -c 'yum install compat-libstdc++-33'
su -c 'rpm -hiv RealPlayer10GOLD.rpm'
* Avidemux
Avidemux is a very good multimedia editor. Install it like this:

su -c 'yum install avidemux'
It will be listed in Applications -> Sound & Video -> Avidemux Video Editor.

12. IRC Clients

* Konversation
A Qt based IRC client for KDE users

su -c 'yum install konversation'
* xchat
A gtk+ based IRC client for GNOME users

su -c 'yum intall xchat'
You will find it under Applications -> Internet -> IRC

13. MSN Messenger Clients

* Pidgin
The default IM client that comes with Fedora 9 is Pidgin. It's in Applications -> Internet -> Internet Messenger. If it's not there install it by typing:

su -c 'yum install pidgin'
* Kopete
Kopete is KDE's IM client. Install it by typing:

su -c 'yum install kdenetwork'
* aMSN
Another pretty good IM is amsn. It supports many plugins.

su -c 'yum install amsn'
You will find it under Applications -> Internet -> aMSN

14. Author, Burn and BackUp CD/DVDs

* Sound-Juicer
Sound Juicer is a CD ripping tool. It is installed by default and you can find it under Applications -> Sound & Video -> Audio CD Extractor. If it's not there install it with:

su -c 'yum install sound-juicer'
* GnomeBaker
A CD/DVD burning utility for GNOME.

su -c 'yum install gnomebaker'
It's under Applications -> Sound & Video -> CD/DVD Writer GnomeBaker.

* k3b
Probably the best Linux CD/DVD burning program. It comes along with a lot KDE dependencies if you are using GNOME.

su -c 'yum install k3b'
* k9copy
K9copy is the linux version of DVDshrink.

su -c 'yum install k9copy'
su -c 'yum install libdvdcss libdvdread libdvdnav lsdvd libdvbpsi'
* DeVeDe
DeVeDe is a very good dvd authoring tool. It allows you to convert any type of video format to DVD so that you can watch it in any player you like.

su -c 'yum install devede'
I have written a guide on How to create a custom DVD using DeVeDe http://www.my-guides.net/en/content/view/75/26/.

15. Download managers

If you don't want to use Firefox's default download manager you can try the following download managers. In case you want to easilly download rapidshare files with your Premium Account you can check my guide How to easilly download RapidShare files in Linux .

* d4x
A downloader for X windows that supports resuming.

su -c 'yum install d4x'
* kget
This is KDE's default download manager. if you are using GNOME you will have to download a lot of dependencies and KDE libraries, so you'd better not use it.

su -c 'yum install kdenetwork'
16. PDF Readers

* evince
The default pdf viewer for Fedora is Evince. If it's not installed type:

su -c 'yum install evince'
* xpdf
su -c 'yum install xpdf'
* acrobatreader
If you prefer adobe acrobat reader you can download it from here. The latest version at this time is 8.1.2. Download the Linux x86 rpm.

When the download completes right click on the Downloads window and click 'Open'. The PackageKit will install the rpm after you supply your root password.

Restart Firefox and type about:plugins in the Address Bar. You should see Adobe Reader 8.0 among the plugins.

17. Torrent Clients

* Transmission
Fedora 9 comes with Transmission as a default torrent client. You can find it under Applications -> Internet -> Transmission or in case you don't have it installed type:

su -c 'transmission'
* KTorrent
ktorrent is an alternative torrent client for KDE users.

su -c 'yum install ktorrent'
* Bittorrent
You could also try bittorrent

su -c 'yum install bittorrent bittorrent-gui'
18. Other Useful Applications

* unrar
su -c 'yum install unrar'
* FTP Client
Pretty good ftp client with ssh support.

su -c 'yum install gftp'
* chm Reader
For GNOME users gtk based chm viewer

su -c 'yum install gnochm'
For KDE users Qt based chm viewer

su -c 'yum install kchmviewer'
* eMule Client
su -c 'yum install amule'
* linuxdcpp
su -c 'yum install linuxdcpp'
* Partition Editor
For GNOME users gtk based partition manipulation program

su -c 'yum install gparted'
For KDE users Qt based partition manipulation program

su -c 'yum install qtparted'
* Google Earth
Go to this page http://earth.google.com/download-earth.html and download GoogleEarthLinux.bin. Next open a terminal and go to the folder you have saved it, ~/Download should be ok. Install it by typing:

su -c 'sh GoogleEarthLinux.bin'

Now you can find it under Applications -> Internet -> Google Earth. Notice that in order it to run ok you must have installed drivers for your video card.

* gtkpod
A sonf management program for Apple's well know iPod.

su -c 'yum install gtkpod'
It'll be installed under Applications -> Sound & Video -> GtkPod

* Skype
You can just visit skype's site and click on the Fedora 7 package. Select to open it with 'Package Installer (Default) and you are done.

Alternatively you can install the Skype repository. Open a terminal and type:

su -c 'gedit /etc/yum.repos.d/skype.repo'
In that file copy the following lines:

[skype]
name=Skype Repository
baseurl=http://download.skype.com/linux/repos/fedora/updates/i586/
enabled=1
gpgkey=http://www.skype.com/products/skype/linux/rpm-public-key.asc
gpgcheck=0
Now you can easily install/update skype by typing:

su -c 'yum install skype'
su -c 'yum update skype'
19. Accessing Windows Partitions

Fedora 9 will autodetect the Windows Partitions (FAT32, NTFS) that you may have in your computer's hard disk and it will place an icon of them on the desktop. Moreover ntfs-3g is installed by default which means that you have read/write access in NTFS partitions also.

If you want to enable/disable write support for external and/or internal devices with only two clicks you can install ntfs-config.

su -c 'yum install ntfs-config'
You can find it in System -> Administration -> NTFS Configuration Tool

ntfs-config-1

20. Accessing Windows Shares

If you want to access the shared of a Windows box of you LAN through Linux and also to be able to view your videos and listen to your mp3 through your local network install smb4k like this:

su -c 'yum install smb4k'
Now run smb4k. Go to Settings -> Configure Smb4K -> Samba and put your workgroup's name. Press Ok and exit. Now click on the Refresh button and let smb4k to scan your network. If you have iptables firewall running you must set Samba as a trusted service. To do so open a terminal and type:

system-config-firewall
Here in 'Trusted Services' find 'Samba', tick it and press 'Apply'.

Run smb4k and when the shares appear at the left window double click on the one you want. Currently smb4k has a bug with the sudo command. So if you get a message like:

mount error 1 = Operation not permitted
Refer to the mount.cifs(8) manual page (e.g.man mount.cifs)
open a terminal and type:

su -c 'chmod u+s /sbin/mount.cifs'
su -c 'chmod u+s /sbin/umount.cifs'
Each time you update smb4k or a samba component you have to run this command again.

21. Compiz-Fusion

Compiz Fusion is the 'cool cube' most of you have seen in a screenshot or video all over the Internet. Fedora 9 comes with a version of it that doesn't have all the features. You can take a look at it under System -> Preferences -> Look and Feel -> Desktop Effects. But if you want to use all the effects, plugins etc. follow the instructions below.

* Official Packages
The compiz-fusion packages found in Fedora repositories are a few versions back but they'll do their work. To install them type:

su -c 'yum remove compiz'
rm -rf ~/.gconf/apps/compiz
su -c 'yum install yum install compiz-fusion compiz-fusion-gnome compiz-fusion-extras compiz-fusion-extras-gnome compiz-manager gnome-compiz-manager ccsm fusion-icon fusion-icon-gtk emerald emerald-themes'
* Unofficial Packages
su -c 'rpm -Uvh http://www.dfm.uninsubria.it/compiz/compiz-fusion-release-1-1.noarch.rpm'
su -c 'yum remove compiz'
rm -rf ~/.gconf/apps/compiz
su -c 'yum install compiz-all fusion-icon-all compiz-fusion-plugins-unsupported compiz-fusion-plugins-extra compiz-bcop ccsm emerald-themes compizconfig-backend-gconf compizconfig-backend-kconfig'
* Auto start
GNOME:

Go to System -> Preferences -> Personal -> Sessions and click Add. Then type what you see in the screenshot.

KDE:

Open a terminal and type:

ln -s /usr/bin/fusion-icon ~/.kde/Autostart/fusion-icon
Logout and then back in. Now you should see a blue icon in your tray. Right click on it and go to Select Window Manager -> Compiz. You can leave the default Window Decorator or select emerald through Select Window Decorator -> Emerald. If you click on Settings Manager, ccsm will run and you can configure compiz fusion as you like. Enjoy!

22. KDE

* KDE Installation
If you haven't installed KDE during the Fedora installation proccess you can easily install it through yum like this:

su -c 'yum groupinstall 'KDE (K Desktop Environment)''
When the installation completes log out and from the sessions manager choose KDE.

** Note: This command will install KDE 3.5.x. KDE4 is still under heavy development and therefore may crash often and generally may not work as expected. However if you want to try it check the KDE4 part of this guide, a few lines below.

* KDE Country Flags
If you have a multilanguage system and you want your country's flag to appear in the tray when you change from one language to the other download kblflags from www.kde-look.org and copy the flag you want as stated below (here I have installed the greek and usa flag).

tar -xzf kbflags-1.0.tar.gz
su -c 'cp kbflags-1.0/21x14/gr.png /usr/share/locale/l10n/gr/flag.png'
su -c 'cp kbflags-1.0/21x14/us.png /usr/share/locale/l10n/us/flag.png'

* KDE style in gtk applications
Some gtk applications don't look good in KDE. To force those applications use the qt style install qtk-qt-engine.

su -c 'yum install gtk-qt-engine'
Then go to Control Center -> Appearance & Themes -> GTK Styles and Fonts and apply the changes you want.

* KDM and Auto Login
If you are the only user in your computer and you don't want each time you turn on your computer to have to type your username and your password you can use KDE's auto login function.
First you must install kdm:

su -c 'gedit /etc/sysconfig/desktop'
and paste in those lines.

DESKTOP="KDE"
DISPLAYMANAGER="KDE"
Save and exit.

Then go to Control Center -> System Administration -> Login manager. Press the "Administrator Mode" button at the bottom and give your root password. Then go to "Convinience" and check "Enable Auto-Login". Select the user you want to auto login with. If you don't want to give your password each time check "Enable Password-Less Login" and check your user. Hit "Apply" and you are done. Next time you reboot you will automatically login with your user account.

* KDE4
As I mentioned before KDE4 isn't expected to work flawlessly until it reaches version 4.1. If you have KDE 3.5.x installed it will corrupt if you install KDE4. If you still want to try it open a terminal and type:

su -c 'yum install kdebase4 kdelibs4 kde-settings-kdm'
This should install all the essential. Log out and log back in choosing KDE from the sessions manager.

23. JAVA

Fedora 9 comes with java from the OpenJDK project. It is very easy to install it through yum (if it hasn't already been installed) and it works just fine. Try it! If you still want to install the Sun Java go a few lines below.

* OpenJDK
su -c 'yum install java-*-openjdk'
* SUN's JAVA
First you must install some libraries needed by Sun' Java. Open a console and type:

su -c 'yum install compat-libstdc++-33 compat-libstdc++-296'
When the libraries are installed create the neccessary links by typing:

su -c '/sbin/ldconfig'
Now click here to go to sun's java site. Click on the download button next to 'Java Runtime Environment (JRE) 6 Update 6'.

**Note: If you also want to compile java programs using Sun's Java Development Kit Installation you must download the 'JDK 6 Update 6' file. Accept the agreement and download the Linux self-extracting file (not the RPM file). The procedure is the same as below. You only have to replace jre1 with jdk1 in the following commands.

Select your Platform (Linux for i386 Fedora or Linux x64 for Fedora x86_64). Accept the agreement and press Continue.

**Note: The rest of the guide is based on the i586 package. If you have Fedora x86_64 installed you should download the Linux x64 file and replace the file names as neccessary.

You must download the Linux self-extracting file (jre-6u6-linux-i586.bin) not the RPM file as shown in the screenshot below.

Next open a terminal and go to the folder you have downloaded jre. Here it will be directory Download, Firefox's default downlad directory.

cd ~/Download/
And type the following to install (when writting this guide 6u6 was the latest version, replace it with the file you have downloaded if it has changed):

su -c 'mv jre-6u6-linux-i586.bin /opt'
cd /opt/
su -c 'chmod a+x jre-6u6-linux-i586.bin'
su -c './jre-6u6-linux-i586.bin'
Use spacebar to read the agreement. At the end type yes to proceed with the installation.

Finally to make Firefox use the installed plugin type:

su -c 'yum remove java-*-openjdk-plugin'
su -c 'ln -s /opt/jre1.6.0_06/plugin/i386/ns7/libjavaplugin_oji.so /usr/lib/mozilla/plugins/libjavaplugin_oji.so'
Restart firefox and type about:plugins in the address bar. If the plugins have successfully installed you should see Java(TM) Plug-in among the plugins.

Now, if you also want to run java programs using Sun's java type in a console:

su -
(Give your root password)
nano /etc/profile.d/java.sh
In that file copy the following:

export JAVA_HOME=/opt/jre1.6.0_06
export PATH=$JAVA_HOME/bin:$PATH
Next type:

source /etc/profile.d/java.sh
/usr/sbin/alternatives --config java
Here you should see something like this:

There are 2 programs which provide 'java'.
Selection Command
-----------------------------------------------
*+ 1 /usr/lib/jvm/jre-1.6.0-openjdk/bin/java
2 /usr/lib/jvm/jre-1.5.0-gcj/bin/java

Enter to keep the current selection[+], or type selection number:

Check how many programs provide java and press Ctrl+C. Here I have 2 so in the next command I will use 3 at the end of the command. Increase by one the number of programs that you have.

/usr/sbin/alternatives --install /usr/bin/java java /opt/jre1.6.0_06/bin/java 3
/usr/sbin/alternatives --config java
Now you should get something like this:

There are 3 programs which provide 'java'.
Selection Command
-----------------------------------------------
*+ 1 /usr/lib/jvm/jre-1.6.0-openjdk/bin/java
2 /usr/lib/jvm/jre-1.5.0-gcj/bin/java
3 /opt/jre1.6.0_06/bin/java

Enter to keep the current selection[+], or type selection number:

Select the option you have entered e.g. 3. To test that you have correctly installed java type:

java -version
You should get something like that:

java version "1.6.0_06"
Java(TM) SE Runtime Environment (build 1.6.0_06-b02)
Java HotSpot(TM) Client VM (build 1.6.0_06-b02, mixed mode, sharing)
If at some time you update your Java installation simply remove the old one by typing:

su -c 'alternatives --remove java /opt/jre1.6.0_06/bin/java'
At any time you can easilly change between OpenJDK, GCJ and Sun's JAVA either by running the command

su -c '/usr/sbin/alternatives --config java'

Linux I класса
Linux II класса
Linux III класса
Счетчики
  • Самый популярный сайт о Linux и Windows 10
О Либератуме

Liberatum — это новости мира дистрибутивов Linux, обзоры, сборки, блоги, а также лучший сайт об Ubuntu*.