Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

[gentoo-user] rsync local mirror question

5 views
Skip to first unread message

Walter Dnes

unread,
Oct 25, 2022, 4:40:03 PM10/25/22
to
I followed https://wiki.gentoo.org/wiki/Local_Mirror instructions for
doing a local rsync mirror. I ran commented the rsync mirrors line in
the client's make.conf and ran "emerge --sync". The client still
synced from a server on the internet. Do I need to manually force
rsync to go local, e.g...

[thimk][root][~] rsync 192.168.1.252::
gentoo-portage Gentoo ebuild repository

--
I've seen things, you people wouldn't believe; Gopher, Netscape with
frames, the first Browser Wars. Searching for pages with AltaVista,
pop-up windows self-replicating, trying to uninstall RealPlayer. All
those moments, will be lost in time like tears in rain... time to die.

Adam Carter

unread,
Oct 25, 2022, 6:10:03 PM10/25/22
to
On Wed, Oct 26, 2022 at 7:35 AM Walter Dnes <walt...@waltdnes.org> wrote:
  I followed https://wiki.gentoo.org/wiki/Local_Mirror instructions for
doing a local rsync mirror.  I ran commented the rsync mirrors line in
the client's make.conf and ran "emerge --sync".  The client still
synced from a server on the internet.  Do I need to manually force
rsync to go local, e.g...


Maybe you missed this
"Now, make the other computers use the local rsync mirror instead of a public one, by changing the sync-uri entry in the appropriate file in /etc/portage/repos.conf/."
 

Michael

unread,
Oct 25, 2022, 6:11:17 PM10/25/22
to
On Tuesday, 25 October 2022 21:36:40 BST Walter Dnes wrote:
> I followed https://wiki.gentoo.org/wiki/Local_Mirror instructions for
> doing a local rsync mirror. I ran commented the rsync mirrors line in
> the client's make.conf and ran "emerge --sync". The client still
> synced from a server on the internet. Do I need to manually force
> rsync to go local, e.g...
>
> [thimk][root][~] rsync 192.168.1.252::
> gentoo-portage Gentoo ebuild repository

No, you shouldn't have to do any such thing. Just make sure you have set up
in your '/etc/portage/repos.conf/gentoo.conf' the correct rsync mirror and
commented out the server on the Internet; e.g.:

[snip ...]

sync-type = rsync
#sync-uri = rsync://rsync.gentoo.org/gentoo-portage
sync-uri = rsync://192.168.1.252/gentoo-portage

signature.asc

Walter Dnes

unread,
Oct 25, 2022, 10:10:04 PM10/25/22
to
On Tue, Oct 25, 2022 at 11:07:14PM +0100, Michael wrote
>
> sync-type = rsync
> #sync-uri = rsync://rsync.gentoo.org/gentoo-portage
> sync-uri = rsync://192.168.1.252/gentoo-portage

Thanks Michael (and Adam). I did indeed forget to update sync-uri.
I subscribe to Netflix, which requires Google-Chrome. It nags for
security updates every few days, so I'll soon find out how well the
corrected mirror setup works.

Question: Can I leave "GENTOO_MIRRORS" uncommented in make.conf? The
minimal change for my laptop would be...

...when at home on my LAN...

#sync-uri = rsync://rsync.gentoo.org/gentoo-portage
sync-uri = rsync://192.168.1.252/gentoo-portage

...when taking the laptop out of my apartment...

sync-uri = rsync://rsync.gentoo.org/gentoo-portage
#sync-uri = rsync://192.168.1.252/gentoo-portage

Michael

unread,
Oct 26, 2022, 5:00:03 AM10/26/22
to
On Wednesday, 26 October 2022 03:06:19 BST Walter Dnes wrote:
> On Tue, Oct 25, 2022 at 11:07:14PM +0100, Michael wrote
>
> > sync-type = rsync
> > #sync-uri = rsync://rsync.gentoo.org/gentoo-portage
> > sync-uri = rsync://192.168.1.252/gentoo-portage
>
> Thanks Michael (and Adam). I did indeed forget to update sync-uri.
> I subscribe to Netflix, which requires Google-Chrome. It nags for
> security updates every few days, so I'll soon find out how well the
> corrected mirror setup works.
>
> Question: Can I leave "GENTOO_MIRRORS" uncommented in make.conf? The
> minimal change for my laptop would be...

Yes, you may leave your GENTOO_MIRRORS URIs as you have it, unless you don't
want to be downloading the same source files more than once for machines in
your LAN.

If downloading chrome source files many times a week separately for multiple
machines is no fun, you can set up a local http proxy caching server with its
webroot pointing to its distfiles directory. Then in your clients'
GENTOO_MIRRORS directive add as the first mirror your LAN Gentoo address/port.
The only drawback is you will have to sync and then emerge --fetchonly, or --
fetch-all-uri, on the local mirror before you start emerging the various
client PCs. A cron job can ensure this is all done by the time you're ready
to run sync & emerge on the rest of your clients.

You can use any number of available webservers with small footprint; e.g.
nginx, lighttpd, boa, etc. The http-replicator is no longer available.


> ...when at home on my LAN...
>
> #sync-uri = rsync://rsync.gentoo.org/gentoo-portage
> sync-uri = rsync://192.168.1.252/gentoo-portage
>
> ...when taking the laptop out of my apartment...
>
> sync-uri = rsync://rsync.gentoo.org/gentoo-portage
> #sync-uri = rsync://192.168.1.252/gentoo-portage

I don't know if you can set more than one sync server, so if the first is not
available it will try the next and so on. When the sync URI was defined in
make.conf this was the case. I suppose you can try it. If it works it'll
save you having to manually edit the file each time you move your laptop away
from your LAN.
signature.asc

Walter Dnes

unread,
Oct 26, 2022, 11:50:04 AM10/26/22
to
On Tue, Oct 25, 2022 at 11:07:14PM +0100, Michael wrote
>
> No, you shouldn't have to do any such thing. Just make sure you
> have set up in your '/etc/portage/repos.conf/gentoo.conf' the correct
> rsync mirror and commented out the server on the Internet; e.g.:

OK, I tried it on my other used Lenovo laptop (thimk2) and it works.
But "inquiring minds want to know"...

* In your instructions '/etc/portage/repos.conf/gentoo.conf' is the file
to change sync-uri in (and it works).

* In https://wiki.gentoo.org/wiki/Local_Mirror the file to change is
given as /etc/portage/repos.conf/gentoo-mirror.conf There is no such
file on my system. Should I file a documentation bug?

Michael

unread,
Oct 26, 2022, 12:51:13 PM10/26/22
to
On Wednesday, 26 October 2022 16:48:29 BST Walter Dnes wrote:
> On Tue, Oct 25, 2022 at 11:07:14PM +0100, Michael wrote
>
> > No, you shouldn't have to do any such thing. Just make sure you
> > have set up in your '/etc/portage/repos.conf/gentoo.conf' the correct
>
> > rsync mirror and commented out the server on the Internet; e.g.:
> OK, I tried it on my other used Lenovo laptop (thimk2) and it works.
> But "inquiring minds want to know"...
>
> * In your instructions '/etc/portage/repos.conf/gentoo.conf' is the file
> to change sync-uri in (and it works).
>
> * In https://wiki.gentoo.org/wiki/Local_Mirror the file to change is
> given as /etc/portage/repos.conf/gentoo-mirror.conf There is no such
> file on my system. Should I file a documentation bug?

Yes, I think it should be updated. This wiki page states what's currently the
convention:

https://wiki.gentoo.org/wiki/Handbook:AMD64/Portage/
Files#Gentoo_ebuild_repository

However, *.conf files can be nested and portage will parse them all the same.
signature.asc

Walter Dnes

unread,
Oct 26, 2022, 8:30:04 PM10/26/22
to
On Wed, Oct 26, 2022 at 05:42:24PM +0100, Michael wrote
> On Wednesday, 26 October 2022 16:48:29 BST Walter Dnes wrote:

> > * In https://wiki.gentoo.org/wiki/Local_Mirror the file to change is
> > given as /etc/portage/repos.conf/gentoo-mirror.conf There is no such
> > file on my system. Should I file a documentation bug?
>
> Yes, I think it should be updated.

Problem; "https://bugs.gentoo.org/enter_bug.cgi" specifically says
"Documentation: Documentation other than Wiki and translations."
The documentation problem is on the wiki page. Now what?

Michael

unread,
Oct 27, 2022, 4:01:24 AM10/27/22
to
On Thursday, 27 October 2022 01:24:24 BST Walter Dnes wrote:
> On Wed, Oct 26, 2022 at 05:42:24PM +0100, Michael wrote
>
> > On Wednesday, 26 October 2022 16:48:29 BST Walter Dnes wrote:
> > > * In https://wiki.gentoo.org/wiki/Local_Mirror the file to change is
> > > given as /etc/portage/repos.conf/gentoo-mirror.conf There is no such
> > > file on my system. Should I file a documentation bug?
> >
> > Yes, I think it should be updated.
>
> Problem; "https://bugs.gentoo.org/enter_bug.cgi" specifically says
> "Documentation: Documentation other than Wiki and translations."
> The documentation problem is on the wiki page. Now what?

I suppose you create an account and edit it? Or see if you can reach out to
the last contributor and perhaps he will correct it:

https://wiki.gentoo.org/wiki/User:Ris

signature.asc
0 new messages