Fedora Linux Support Community & Resources Center
  #1  
Old 3rd August 2009, 03:25 PM
tpharris Offline
Registered User
 
Join Date: Mar 2008
Location: Chicago, Illinois
Posts: 9
windows_vistafirefox
Lightbulb [SOLVED] Using 'createrepo' and building a local network mirror.

As the title says I'm trying to build myself a local RPM mirror. I have multiple laptops and a desktop that use Fedora 11. So I used 'rsync' to setup and sync my directories. I next went on to create my repo with the 'createrepo' function. I run my server backend as FreeBSD so I moved my data over there and setup my 'lighttpd' service.

Everything went fine until I used 'rsync' and synced up my data. Am I supposed to run 'createrepo' after each sync? If so, does anyone else use the same kinda setup, even if not FreeBSD, but a different os other than linux for their server that they run this from? Or any suggestion would be helpful. I've been dealing with this for 2 weeks now and finally gave up researching and testing and thought I'd ask for help. Not something I'm good at doing. Check my register date and my first post date.


Edit: FreeBSD doesn't have a port or unofficial port for this. I noticed it seems to be written as a python script so thought I could somehow get it to run on FreeBSD with linux emulation. Still working that route and trying to trouble shoot with the appropriate community and forums.

Last edited by tpharris; 4th August 2009 at 08:43 PM. Reason: Marking as solved.
Reply With Quote
  #2  
Old 3rd August 2009, 03:49 PM
bbfuller Offline
Registered User
 
Join Date: Jun 2005
Location: UK
Posts: 4,369
linuxopera
Hello tpharris

Yes, I mirror one of the updates repositories here.

I always run "createrepo" here after each mirroring. Though I assume that if you mirrored the repodata folder that wouldn't be necessary.

I then alter the address of the repository in the appropriate entry in yum.repos.d.

I've never actually tried to do it via http, I just mount my repository as a samba share.

My mirror though is on Fedora and as such I have no trouble running "createrepo".

If I can help any further just post back.

Last edited by bbfuller; 3rd August 2009 at 03:56 PM.
Reply With Quote
  #3  
Old 3rd August 2009, 04:00 PM
bbfuller Offline
Registered User
 
Join Date: Jun 2005
Location: UK
Posts: 4,369
linuxopera
Hello again tpharris

It's been a long time since I did this the first time and I never really have to set this up from scratch these days.

I do remember though, that if I had done any previous updating from the official mirrors, then I had to run:

Code:
yum clean all
on my machine that was to be updated before it would be happy with my new repository.
Reply With Quote
  #4  
Old 3rd August 2009, 05:03 PM
tpharris Offline
Registered User
 
Join Date: Mar 2008
Location: Chicago, Illinois
Posts: 9
windows_vistafirefox
Thanks for the advice bbfuller. I'm going to tinker around with this using some of your suggestions later. Though, I have no need for samba and therefore don't run it. So I'll have to try and integrate http into those steps somewhere. I'll pop back on with my results.
Reply With Quote
  #5  
Old 3rd August 2009, 05:07 PM
bbfuller Offline
Registered User
 
Join Date: Jun 2005
Location: UK
Posts: 4,369
linuxopera
Hello tpharris

If you look in the fedora.updates.repo file in yum.repos.d, you'll see the line baseurl is an http address.

Just comment that out and replace it with your own http address.
Reply With Quote
  #6  
Old 3rd August 2009, 06:07 PM
Dangermouse Offline
Administrator - (On Leave)
 
Join Date: Aug 2007
Location: London Postbox (the red one)
Age: 49
Posts: 3,864
linuxfedorafirefox
Hi this is what i did, which you may find useful is, for me when i only want to download updates etc.. once for all comps on lan, i set yum to keep cache, than rsync them to /var/www/html/fedora (local web server) and run createrepo, all in a script, and just add the local repo to the other comps.
Reply With Quote
  #7  
Old 4th August 2009, 08:41 PM
tpharris Offline
Registered User
 
Join Date: Mar 2008
Location: Chicago, Illinois
Posts: 9
windows_vistafirefox
Quote:
Originally Posted by bbfuller View Post
Hello tpharris

Yes, I mirror one of the updates repositories here.

I always run "createrepo" here after each mirroring. Though I assume that if you mirrored the repodata folder that wouldn't be necessary.

I then alter the address of the repository in the appropriate entry in yum.repos.d.

I've never actually tried to do it via http, I just mount my repository as a samba share.

My mirror though is on Fedora and as such I have no trouble running "createrepo".

If I can help any further just post back.

Going back thru this thread I had noticed you mentioned if I had mirrored the repodata folder it wouldn't be necessary. I see that after reading that I was 1-sub directory too far down the tree. I was using 'rsync' to grab just packages and that the mirror had already done the creation of the repodata files for me.

So I updated my 'rsync' script and now things work nicely without having to run the command myself. And it works just fine with my web server pointed to it. Thanks.
Reply With Quote
  #8  
Old 4th August 2009, 08:42 PM
tpharris Offline
Registered User
 
Join Date: Mar 2008
Location: Chicago, Illinois
Posts: 9
windows_vistafirefox
Quote:
Originally Posted by Dangermouse View Post
Hi this is what i did, which you may find useful is, for me when i only want to download updates etc.. once for all comps on lan, i set yum to keep cache, than rsync them to /var/www/html/fedora (local web server) and run createrepo, all in a script, and just add the local repo to the other comps.

I was looking to just centralize everything from my FreeBSD server. I didn't want to run any extra services on my desktop/laptops. I slim them down as far as they go after initial install. Anyways, thanks for the tips though. It made me look into a bunch of other topics and suggestions. I also ran through your guides on your website and now I have the next 2 weeks of tinkering all planned out. Thanks again for your help and suggestions.
Reply With Quote
Reply

Tags
building, createrepo, local, mirror, network

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

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 On
HTML code is Off

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
createrepo can't install from dvd and local repos not working (help please) littlej_money Using Fedora 2 6th November 2008 07:59 PM
How can I use a local mirror? Joffer Using Fedora 2 1st May 2005 10:29 PM
Createrepo - Generate local RPM repository Flu Using Fedora 0 11th November 2004 07:14 PM


Current GMT-time: 13:30 (Friday, 24-10-2014)

TopSubscribe to XML RSS for all Threads in all ForumsFedoraForumDotOrg Archive
logo

All trademarks, and forum posts in this site are property of their respective owner(s).
FedoraForum.org is privately owned and is not directly sponsored by the Fedora Project or Red Hat, Inc.

Privacy Policy | Term of Use | Posting Guidelines | Archive | Contact Us | Founding Members

Powered by vBulletin® Copyright ©2000 - 2012, vBulletin Solutions, Inc.

FedoraForum is Powered by RedHat
Zuenoula Photos on Instagram - Balta Travel Photos on Instagram - Kontich Travel Photos