Making local yum rpm repositorie

From Teknologisk videncenter
Revision as of 08:47, 12 March 2009 by Heth (talk | contribs) (New page: Install ''createrepo'' <pre> yum install createrepo </pre> Make directory structure * A directory called ''base'' which holds local copy of RPM's * A directory called ''updates'' which ...)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to: navigation, search

Install createrepo

yum install  createrepo


Make directory structure

  • A directory called base which holds local copy of RPM's
  • A directory called updates which holds the updates.

On this server which is a PXE install server the RPM's are already resident on the ftp server /var/ftp/install/centos52/CentOS/RPMS which I just link to the repositorie

mkdir -p/var/www/html/Centos/52/yum/updates
ln -s /var/ftp/install/centos52/CentOS/RPMS /var/www/html/Centos/52/yum/base

Now create the base repository headers: (Takes a couple of minuttes)
createrepo creates some files in a new repodata directory.

[root@ks ~]# createrepo /var/www/html/Centos/52/yum
[root@ks ~]# ls /var/www/html/Centos/52/yum/repodata
filelists.xml.gz  other.xml.gz  primary.xml.gz  repomd.xml