How to create local repo for push agent feature using repotrack

Print Friendly, PDF & Email

Use the following commands to get all the packages and their dependencies:

yum install epel-release.noarch -y

In Centos 6.X epel.repo files has an https url which is currently not working. Workaround the problem with this command:

sed -i 's|mirrorlist=https://mirrors|mirrorlist=http://mirrors|g' /etc/yum.repos.d/epel.repo

If repotrack is not installed run:

yum install yum-utils -y

Note:  this is true if you are running the latest release for your OS version

repotrack -r 'epel' -r 'rpmforge' -r 'C5.11-base' -p C5.11 nagios-common nagios-plugins nagios-plugins-all nagios-plugins-nrpe nrpe nagios-nrpe openssl glibc

repotrack -p C5.11 nagios-common nagios-plugins nagios-plugins-all nagios-plugins-nrpe nrpe nagios-nrpe openssl glibc

repotrack -r 'epel' -r 'C6.3-base' -p C6.3 nagios-plugins-nrpe nrpe nagios-plugins-load nagios-plugins-swap nagios-plugins-procs nagios-plugins-disk nagios-plugins-users openssl09* openssl-1* make ocsinventory-agent

repotrack -p C6.3 nagios-plugins-nrpe nrpe nagios-plugins-load nagios-plugins-swap nagios-plugins-procs nagios-plugins-disk nagios-plugins-users openssl09* openssl-1* make ocsinventory-agent

An additional package must be downloaded manually and added to the local repo because repotrack seems to be unable to resolve it correctly:

yumdownloader --destdir=C6.3 openssl

(openssl-1.0.1e-42.el6.x86_64.rpm and openssl-1.0.1e-42.el6.i686.rpm)

Replacing CX.Y with your current OS version, such as C5.4, C6.3, etc.

Note: if you are creating a local repo for a previous version from a host running the latest version run just the following command:

repotrack -r 'epel' -r 'rpmforge' -r 'C5.4-base' -p C5.4 nagios-common nagios-plugins nagios-plugins-all nagios-plugins-nrpe nrpe nagios-nrpe openssl glibc

repotrack -r 'epel' -r 'C6.3-base' -p C6.3 nagios-plugins-nrpe nrpe nagios-plugins-load nagios-plugins-swap nagios-plugins-procs nagios-plugins-disk nagios-plugins-users openssl09* openssl-1* make ocsinventory-agent

An additional package must be downloaded manually and added to the local repo because repotrack seems to be unable to resolve it correctly:

yumdownloader --destdir=C6.3 openssl

(openssl-1.0.1e-42.el6.x86_64.rpm and openssl-1.0.1e-42.el6.i686.rpm)

Again replacing CX.Y with your current OS version, such as C5.4, C6.3, etc.

The resulting structure is uploaded in atlantixlab FTP (download.atlantixlab.ftp) customers/skeleton folder.

Note: repotrack command has a bug and will get also i386, i586 and i686 unneeded RPMs even if running on a 64 bit cpu architecture. To prevent yum localinstall (run by the auto-installer) to resolve additional unneeded dependencies after creating a local repo it is extremely suggested to cleanup the local repo with a command like the following

rm -vf C6.7/*i[356]86*

 

atlantixadmin has written 113 articles

Leave a Reply

Your email address will not be published. Required fields are marked *

You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <s> <strike> <strong>