0% found this document useful (0 votes)
43 views

Configure Yum Repository Steps

This document outlines the steps to configure an Oracle Enterprise Linux (OEL) system to use the Oracle Public YUM Repository. It includes instructions for checking YUM configuration, creating a new repository file, and adding repository configurations. Finally, it provides a command to test the repository setup to ensure it is functioning correctly.

Uploaded by

Abhi
Copyright
© © All Rights Reserved
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
43 views

Configure Yum Repository Steps

This document outlines the steps to configure an Oracle Enterprise Linux (OEL) system to use the Oracle Public YUM Repository. It includes instructions for checking YUM configuration, creating a new repository file, and adding repository configurations. Finally, it provides a command to test the repository setup to ensure it is functioning correctly.

Uploaded by

Abhi
Copyright
© © All Rights Reserved
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
You are on page 1/ 3

Configure Yum Repository Steps

To configure your OEL system to use the Oracle Public YUM Repository,
accomplish the following actions as root.

1. Checking YUM Configuration

1. Change to the /etc directory.

# cd /etc

2. Ensure the contents of the yum.conf file look like the following. Make
any changes necessary before proceeding to step 3.

[main]
cachedir=/var/cache/yum
keepcache=0
debuglevel=2
logfile=/var/log/yum.log
distroverpkg=redhat-release
tolerant=1
exactarch=1
obsoletes=1
gpgcheck=1
plugins=1

# Note: yum-RHN-plugin doesn't honor this.


metadata_expire=1h

# Default.
# installonly_limit = 3

# PUT YOUR REPOS HERE OR IN separate files named file.repo


# in /etc/yum.repos.d
# Never update kernel and kernel-uek
installonlypkgs=kernel kernel-smp kernel-bigmem kernel-enterprise
kernel-debug kernel-unsupported kernel-uek
exclude=up2date

NOTE: If your system needs to use a proxy to access the internet, add the
following line to the yum.conf file:

proxy=http://[url.to.proxy]:[port]

For example:

proxy=http://www.myproxy.com:80

You can also use an IP address in place of the URL.


3. Change to the /etc/yum.repos.d directory.

# cd /etc/yum.repos.d

4. List the contents of the yum.repos.d directory. Repository configuration


files have a file extension of .repo. If the only files in the directory are
Exadata-computenode.repo.sample and/or ULN-Base.repo, go on to the “2.
Creating a Repo File” section. If there are more files than just Exadata-
computenode.repo.sample and/or ULN-Base.repo, go on to the “3. Adding
a Repository Configuration” section.

2. Creating a Repo File

1. In /etc/yum.repos.d, edit a new file called oracle-public-yum-ol6.repo.

2. In the new file, add the following lines:

# vi /etc/yum.repos.d/oracle-public-yum-ol6.repo
[public_ol6_latest]
name=Oracle Linux $releasever Latest ($basearch)
baseurl=http://public-yum.oracle.com/repo/OracleLinux/OL6/latest/
$basearch/
gpgkey=http://public-yum.oracle.com/RPM-GPG-KEY-oracle-ol6
gpgcheck=1
enabled=1

3. Save the file.

4. Go to the “4. Test the Repository” section.

3. Adding a Repository Configuration

1. Review each of the repo files in the /etc/yum.repos.d. Look for section
that looks similar to this:

[public_ol6_latest]
name=Oracle Linux $releasever Latest ($basearch)
baseurl=http://public-yum.oracle.com/repo/OracleLinux/OL6/latest/
$basearch/
gpgkey=http://public-yum.oracle.com/RPM-GPG-KEY-oracle-ol6
gpgcheck=1
enabled=1
If you do not see this in any of the repo files, accomplish the steps in the “2.
Creating a Repo File” section. If you do see this in one of the repo files, go
to next step below.

2. Ensure the enabled line is set to 1 (active):

enabled=1

If not set to 1, make the change and save the file. If set to 1, you are
already configured to access the Oracle Public YUM Repository.

3. Go to the “4. Test the Repository” section.

4. Test the Repository

Issue the following command:

# yum repolist

You should see the list of repositories

You might also like