LinuxQuestions.org
Visit Jeremy's Blog.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Red Hat
User Name
Password
Red Hat This forum is for the discussion of Red Hat Linux.

Notices


Reply
  Search this Thread
Old 10-15-2008, 04:42 PM   #1
neildomo
LQ Newbie
 
Registered: Oct 2008
Posts: 7

Rep: Reputation: 0
Add a custom-built rpm to a repository


We have a local repository, and I recently used rpmbuild -bb to build an rpm. I copied it over to the RPMS subdir where all the other rpms are, but it doesn't show up when I do a 'yum update pkgname' on a server. Do I have to somehow tell the repository that I put some new rpms there? Is there a tool to do this, or do I just vi a file and add the rpm names?

Thanks,
Neil
 
Old 10-15-2008, 04:52 PM   #2
jailbait
LQ Guru
 
Registered: Feb 2003
Location: Virginia, USA
Distribution: Debian 12
Posts: 8,337

Rep: Reputation: 548Reputation: 548Reputation: 548Reputation: 548Reputation: 548Reputation: 548
You can add a local directory to Red Hat's list of repositories. I am uncertain about Red Hat but I would guess that the repository list is kept in /etc/yum.repos.d.

In any case you can install a rpm package which is not in any repository by using the rpm command. Something like:

rpm -i /usr/src/redhat/RPMS/i686/my.new.rpm

--------------------
Steve Stites
 
Old 10-15-2008, 05:03 PM   #3
neildomo
LQ Newbie
 
Registered: Oct 2008
Posts: 7

Original Poster
Rep: Reputation: 0
We already have a local directory with rpms, and it's already in our yum configuration so that when we do a 'yum update|install $pkgname' it will look in this repository. The issue I'm having is that I copied an rpm into that directory, and yum doesn't seem to know that. When I try 'yum update $pkgname', it says that I already have the latest version(the rpm I build is a newer version).

I could conceivable run rpm -Uvh /path/to/$pkgname, but that kinda get's troublesome with dependencies and all, and we've established that we want to use yum for this.

Thanks,
Neil
 
Old 10-15-2008, 05:50 PM   #4
jailbait
LQ Guru
 
Registered: Feb 2003
Location: Virginia, USA
Distribution: Debian 12
Posts: 8,337

Rep: Reputation: 548Reputation: 548Reputation: 548Reputation: 548Reputation: 548Reputation: 548
I think that the way you straighten yum out on what versions it has on hand is:

yum clean headers

However, I have never tried this command so take my advice with a grain of salt. Check out the command in man yum and Google and see what you think.

--------------------
Steve Stites
 
Old 10-15-2008, 06:01 PM   #5
billymayday
LQ Guru
 
Registered: Mar 2006
Location: Sydney, Australia
Distribution: Fedora, CentOS, OpenSuse, Slack, Gentoo, Debian, Arch, PCBSD
Posts: 6,678

Rep: Reputation: 122Reputation: 122
Have you tried recreating the repo with createrepo? repomd.xml, etc will need to be updated
 
Old 10-15-2008, 06:08 PM   #6
ArfaSmif
Member
 
Registered: Oct 2008
Location: Brisbane Australia
Distribution: Fedora, Centos, Manjaro
Posts: 317

Rep: Reputation: 70
You will have to use the command "createrepo" to update the repo files for your local repositry. See the man page for createrepo.
 
Old 10-15-2008, 09:11 PM   #7
neildomo
LQ Newbie
 
Registered: Oct 2008
Posts: 7

Original Poster
Rep: Reputation: 0
Thanks! I'll look into it.
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Reusing a custom built kernel on a new installation dizzi Slackware 4 08-01-2007 03:57 PM
Upgrade to etch without upgrading Custom built Xorg kushalkoolwal Debian 2 05-10-2007 12:16 PM
How to create custom install CD with third party driver built in? Arodef Red Hat 3 04-05-2006 06:37 AM
Custom built PC using Linux questions Azalar Linux - Newbie 5 01-17-2006 09:36 PM
Custom Built PC - No Monitor Signal Eklipz Linux - Hardware 12 12-25-2004 09:48 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Red Hat

All times are GMT -5. The time now is 08:38 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration