Configure your server for Yum (Yellowdog Updater Modified):

There’s no more need to look for CDs from your pile of CDs or from the clutter of your desk. Earlier in 2009, Oracle launched their public yum server which offers a free and convenient way to install packages from the Enterprise Linux and Oracle VM. Obviously, the Yum server if offered without support.

We will show you how to setup your Red Hat or Oracle Enterprise Linux to use Oracle’s public Yum repository. In this example, we only focus on 64-bit Red Hat 5 Update 3.

[root@rac01 ~]# cd /etc/yum.repos.d/
[root@rac01 yum.repos.d]# ls -ltr
total 0
[root@rac01 yum.repos.d]# wget http://public-yum.oracle.com/public-yum-el5.repo
--11:27:04--  http://public-yum.oracle.com/public-yum-el5.repo
Resolving public-yum.oracle.com... 141.146.44.34
Connecting to public-yum.oracle.com|141.146.44.34|:80... connected.
HTTP request sent, awaiting response... 200 OK
Length: 1402 (1.4K) [text/plain]
Saving to: `public-yum-el5.repo'

100%[=========================================================>] 1,402       --.-K/s   in 0s     

11:27:04 (83.6 MB/s) - `public-yum-el5.repo' saved [1402/1402]

Edit the file public-yum-el5.repo with your choice of editor such as vi. Change enabled=0 to enabled=1 for the following sections since we are on RH5 U3

Portions of your yum.repos.d file should look something like this:

[el5_u3_base]
name=Enterprise Linux $releasever U3 - $basearch - base
baseurl=http://public-yum.oracle.com/repo/EnterpriseLinux/EL5/3/base/$basearch/
gpgkey=http://public-yum.oracle.com/RPM-GPG-KEY-oracle-el5
gpgcheck=1
enabled=1

[el5_addons]
name=Enterprise Linux $releasever - $basearch - addons
baseurl=http://public-yum.oracle.com/repo/EnterpriseLinux/EL5/addons/$basearch/
gpgkey=http://public-yum.oracle.com/RPM-GPG-KEY-oracle-el5
gpgcheck=1
enabled=1

[el5_oracle_addons]
name=Enterprise Linux $releasever - $basearch - oracle_addons
baseurl=http://public-yum.oracle.com/repo/EnterpriseLinux/EL5/oracle_addons/$basearch/
gpgkey=http://public-yum.oracle.com/RPM-GPG-KEY-oracle-el5
gpgcheck=1
enabled=1

Install missing RPM needed to install Oracle

Here’s an example of downloading the compat-db RPM and installing the package

[root@rac01 yum.repos.d]# yum install compat-db
Loaded plugins: security
Setting up Install Process
Parsing package install arguments
Package compat-db-4.2.52-5.1.x86_64 already installed and latest version
Resolving Dependencies
--> Running transaction check
---> Package compat-db.i386 0:4.2.52-5.1 set to be updated
--> Finished Dependency Resolution

Dependencies Resolved

==================================================================================================
 Package                Arch              Version                  Repository                Size
==================================================================================================
Installing:
 compat-db              i386              4.2.52-5.1               el5_u3_base              1.7 M

Transaction Summary
==================================================================================================
Install      1 Package(s)
Update       0 Package(s)
Remove       0 Package(s)         

Total download size: 1.7 M
Is this ok [y/N]: y
Downloading Packages:
compat-db-4.2.52-5.1.i386.rpm                                              | 1.7 MB     00:01
Running rpm_check_debug
Running Transaction Test
Finished Transaction Test
Transaction Test Succeeded
Running Transaction
  Installing     : compat-db                                         [1/1] 

Installed: compat-db.i386 0:4.2.52-5.1
Complete!

Posted by Charles Kim, Oracle ACE

Technorati Tags: