Oracle Linux public YUM repository configuration


Oracle Linux (or OEL for short) is a distribution of Red Hat Linux (RHEL) which includes additional packages, configurations and settings that are optimal for running Oracle products. In our test environments, this is frequently the operating system of choice, as it’s freely available, and very reliable for trying out various products related to the Oracle database.

One task that often becomes tedious is the update and installation of various packages, as there are often dependencies that come into play (at least, when using Linux’s various rpm commands). An alternative is to use the yum option, along with Oracle’s public repository which will handle all dependencies (including required patches and their minimum versions).

To get started, we must first have an installation of RHEL/OEL setup, in my case I’m using RHEL 5.5. We need to ensure that the server is connected to the internet, and can do so easily by trying to reach any valid host (for simplicity’s sake, I’m using Google’s page):

[root@rhelgrid yum.repos.d]# ping google.com

PING google.com (209.85.175.147) 56(84) bytes of data.

64 bytes from google.com (209.85.175.147): icmp_seq=1 ttl=56 time=5.11 ms

64 bytes from google.com (209.85.175.147): icmp_seq=2 ttl=56 time=5.45 ms

64 bytes from google.com (209.85.175.147): icmp_seq=3 ttl=56 time=4.87 ms

 

— google.com ping statistics —

3 packets transmitted, 3 received, 0% packet loss, time 2001ms

rtt min/avg/max/mdev = 4.877/5.148/5.458/0.252 ms

 

Now that we know we’re connected, we need to go to the YUM configuration directory (located at /etc/yum.repos.d) and copy the public repository configuration file from Oracle’s public server (by using a wget command), as shown below:

 

[root@rhelgrid yum.repos.d]# wget http://public-yum.oracle.com/public-yum-el5.repo

–2011-11-02 03:19:23–  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: 2533 (2.5K) [text/plain]

Saving to: `public-yum-el5.repo.1′

 

100%[======================================>] 2,533       –.-K/s   in 0s

 

2011-11-02 03:19:23 (268 MB/s) – `public-yum-el5.repo.1′ saved [2533/2533]

 

 

Next we need to edit the configuration file (public-yum-el5.repo) that we downloaded earlier, and ensure that the correct version of the repository is enabled (based on whether we are using OEL or RHEL, and the current update number we’re on):

 

[el5_u5_base]

name=Enterprise Linux $releasever U5 – $basearch – base

baseurl=http://public-yum.oracle.com/repo/EnterpriseLinux/EL5/5/base/$basearch/

gpgkey=http://public-yum.oracle.com/RPM-GPG-KEY-oracle-el5

gpgcheck=1

enabled=1

 

As seen above, I’m enabling the repository for RHEL 5, update 5 (or RHEL 5.5). Now all that remains is to ensure that we are able to list all the packages included in the repository, and install what we require (I’m going to install samba-winbind to test out some DNS server configurations):

 

[root@rhelgrid yum.repos.d]# yum list | grep win

This system is not registered with RHN.

RHN support will be disabled.

ant-swing.x86_64                          1.6.5-2jpp.2               el5_u5_base

libchewing.i386                           0.3.0-8.el5                el5_u5_base

libchewing.x86_64                         0.3.0-8.el5                el5_u5_base

libchewing-devel.i386                     0.3.0-8.el5                el5_u5_base

libchewing-devel.x86_64                   0.3.0-8.el5                el5_u5_base

samba3x-winbind.i386                      3.5.4-0.70.el5             ol5_u6_base

samba3x-winbind.x86_64                    3.5.4-0.70.el5             ol5_u6_base

samba3x-winbind-devel.i386                3.5.4-0.70.el5             ol5_u6_base

samba3x-winbind-devel.x86_64              3.5.4-0.70.el5             ol5_u6_base

scim-chewing.x86_64                       0.3.1-11.el5               el5_u5_base

[root@rhelgrid yum.repos.d]# yum install samba3x

Loaded plugins: rhnplugin, security

This system is not registered with RHN.

RHN support will be disabled.

Setting up Install Process

Resolving Dependencies

–> Running transaction check

—> Package samba3x.x86_64 0:3.5.4-0.70.el5 set to be updated

–> Processing Dependency: samba3x-common = 3.5.4-0.70.el5 for package: samba3x

–> Processing Dependency: libtalloc.so.2()(64bit) for package: samba3x

–> Processing Dependency: libtdb.so.1()(64bit) for package: samba3x

–> Processing Dependency: libwbclient.so.0()(64bit) for package: samba3x

–> Running transaction check

—> Package libtalloc.x86_64 0:2.0.1-11.el5 set to be updated

—> Package libtdb.x86_64 0:1.2.1-5.el5 set to be updated

—> Package samba3x-common.x86_64 0:3.5.4-0.70.el5 set to be updated

—> Package samba3x-winbind.x86_64 0:3.5.4-0.70.el5 set to be updated

–> Finished Dependency Resolution

 

Dependencies Resolved

 

==================================================================================================================================================================================

 Package                                       Arch                                 Version                                       Repository                                 Size

==================================================================================================================================================================================

Installing:

 samba3x                                       x86_64                               3.5.4-0.70.el5                                ol5_u6_base                               5.9 M

Installing for dependencies:

 libtalloc                                     x86_64                               2.0.1-11.el5                                  ol5_u6_base                                20 k

 libtdb                                        x86_64                               1.2.1-5.el5                                   ol5_u6_base                                28 k

 samba3x-common                                x86_64                               3.5.4-0.70.el5                                ol5_u6_base                                17 M

 samba3x-winbind                               x86_64                               3.5.4-0.70.el5                                ol5_u6_base                               4.3 M

 

Transaction Summary

==================================================================================================================================================================================

Install       5 Package(s)

Upgrade       0 Package(s)

 

Total download size: 27 M

 

Is this ok [y/N]: y

Downloading Packages:

(1/5): libtalloc-2.0.1-11.el5.x86_64.rpm                                                                                                                   |  20 kB     00:00

(2/5): libtdb-1.2.1-5.el5.x86_64.rpm                                                                                                                       |  28 kB     00:00

(3/5): samba3x-winbind-3.5.4-0.70.el5.x86_64.rpm                                                                                                           | 4.3 MB     00:17

(4/5): samba3x-3.5.4-0.70.el5.x86_64.rpm                                                                                                                   | 5.9 MB     00:24

(5/5): samba3x-common-3.5.4-0.70.el5.x86_64.rpm                                                                                                            |  17 MB     01:08

———————————————————————————————————————————————————————————-

Total                                                                                                                                             244 kB/s |  27 MB     01:54

Running rpm_check_debug

Running Transaction Test

Finished Transaction Test

Transaction Test Succeeded

Running Transaction

  Installing     : libtalloc                                                                                                                                                  1/5

  Installing     : libtdb                                                                                                                                                     2/5

  Installing     : samba3x-common                                                                                                                                             3/5

  Installing     : samba3x-winbind                                                                                                                                            4/5

  Installing     : samba3x                                                                                                                                                    5/5

 

Installed:

  samba3x.x86_64 0:3.5.4-0.70.el5

 

Dependency Installed:

  libtalloc.x86_64 0:2.0.1-11.el5          libtdb.x86_64 0:1.2.1-5.el5          samba3x-common.x86_64 0:3.5.4-0.70.el5          samba3x-winbind.x86_64 0:3.5.4-0.70.el5

Complete!

 

So there we have it, the public YUM repository was able to list everything that I needed, as well as identify 2 packages that were pre-requisites for winbind, download and install all of them once I confirmed the operation

About oracletempspace

I'm an Oracle enthusiast, whose work revolves around consulting, designing, implementing and generally helping businesses get the most out of Oracle Database and related products.
This entry was posted in Oracle Linux 5, RHEL 5, RPM management, RPM management, YUM repository, YUM repository and tagged , , , , . Bookmark the permalink.

Leave a comment