 |
 |
 |
 |
| Using Fedora General support for current versions. Ask questions about Fedora and it's software that do not belong in any other forum. |

3rd August 2009, 03:25 PM
|
|
Registered User
|
|
Join Date: Mar 2008
Location: Chicago, Illinois
Posts: 9

|
|
[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.
|

3rd August 2009, 03:49 PM
|
|
Registered User
|
|
Join Date: Jun 2005
Location: UK
Posts: 4,344

|
|
|
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.
|

3rd August 2009, 04:00 PM
|
|
Registered User
|
|
Join Date: Jun 2005
Location: UK
Posts: 4,344

|
|
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:
on my machine that was to be updated before it would be happy with my new repository.
|

3rd August 2009, 05:03 PM
|
|
Registered User
|
|
Join Date: Mar 2008
Location: Chicago, Illinois
Posts: 9

|
|
|
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.
|

3rd August 2009, 05:07 PM
|
|
Registered User
|
|
Join Date: Jun 2005
Location: UK
Posts: 4,344

|
|
|
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.
|

3rd August 2009, 06:07 PM
|
 |
Administrator
|
|
Join Date: Aug 2007
Location: London Postbox (the red one)
Age: 47
Posts: 3,847

|
|
|
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.
|

4th August 2009, 08:41 PM
|
|
Registered User
|
|
Join Date: Mar 2008
Location: Chicago, Illinois
Posts: 9

|
|
Quote:
Originally Posted by bbfuller
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.
|

4th August 2009, 08:42 PM
|
|
Registered User
|
|
Join Date: Mar 2008
Location: Chicago, Illinois
Posts: 9

|
|
Quote:
Originally Posted by Dangermouse
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.
|
| Thread Tools |
Search this Thread |
|
|
|
| Display Modes |
Linear Mode
|
Posting Rules
|
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts
HTML code is Off
|
|
|
Current GMT-time: 17:09 (Saturday, 18-05-2013)
|
|
 |
 |
 |
 |
|
|