Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
setup a local gentoo source mirror by ebuild?
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Installing Gentoo
View previous topic :: View next topic  
Author Message
fpemud
Apprentice
Apprentice


Joined: 15 Feb 2012
Posts: 295

PostPosted: Sun Nov 10, 2019 11:45 pm    Post subject: setup a local gentoo source mirror by ebuild? Reply with quote

I'd like t'o setup a gentoo source mirror for my small group.
After reading https://wiki.gentoo.org/wiki/Project:Infrastructure/Mirrors/Source I'm wondering can I do the whole process in a automated way, which is just emerging a package and enable a service?
Is there any project around? Or maybe I could write one so that it would be convinent if I need to do it again.
Back to top
View user's profile Send private message
John R. Graham
Administrator
Administrator


Joined: 08 Mar 2005
Posts: 10459
Location: Somewhere over Atlanta, Georgia

PostPosted: Mon Nov 11, 2019 3:31 am    Post subject: Reply with quote

See the Local Mirror article on the Gentoo Wiki.

- John
_________________
I can confirm that I have received between 0 and 499 National Security Letters.
Back to top
View user's profile Send private message
NeddySeagoon
Administrator
Administrator


Joined: 05 Jul 2003
Posts: 45383
Location: 56N 3W

PostPosted: Mon Nov 11, 2019 12:05 pm    Post subject: Reply with quote

fpemud,

I use http-replicator and point all my machines to that.

The first system to demand a download caues it to be cached. Then other requests are served from the cache.
It saves keeping a full distfiles mirror, which was over 240G last time I looked.

I run an rsync server for the portage tree too.
_________________
Regards,

NeddySeagoon

Computer users fall into two groups:-
those that do backups
those that have never had a hard drive fail.
Back to top
View user's profile Send private message
fpemud
Apprentice
Apprentice


Joined: 15 Feb 2012
Posts: 295

PostPosted: Tue Nov 12, 2019 2:22 am    Post subject: Reply with quote

Thanks very much. So it seems there's no ready-for-use project.

I have another question for a local mirror:
Will I download a corrupted file from mirror when the mirror is synchronizing this file?
Back to top
View user's profile Send private message
Jaglover
Watchman
Watchman


Joined: 29 May 2005
Posts: 7653
Location: Saint Amant, Acadiana

PostPosted: Tue Nov 12, 2019 2:27 am    Post subject: Reply with quote

In case you have one of your computers always on simply share portage and distfiles over NFS. Any PC on your LAN can sync, any distfile which is needed for any box will be shared and not downloaded again. I have had it this way for longest time. I have monthly cronjob which runs eclean, removing distfiles which have no corresponding ebuilds any more.
_________________
Please learn how to denote units correctly!
Back to top
View user's profile Send private message
NeddySeagoon
Administrator
Administrator


Joined: 05 Jul 2003
Posts: 45383
Location: 56N 3W

PostPosted: Tue Nov 12, 2019 9:46 am    Post subject: Reply with quote

fpemud,

Individual files will always be correct but sets that really need an atomic update don't get it.
However, the window where that can happen has got much smaller with repo signing.

Now the repo updates are downloaded into a temporary space and the signatures checked.
If that check fails, the update is discarded.
Once the signatures check the local temp copy is merged into your copy of the repo.

That merge is much faster than an rsync into your live repo, which could also leave your repo in a mess when you had ebuilds from one update and a Manifest from another.
That can still happen be its much rarer now.
_________________
Regards,

NeddySeagoon

Computer users fall into two groups:-
those that do backups
those that have never had a hard drive fail.
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Installing Gentoo All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum