View previous topic :: View next topic |
Author |
Message |
flybynite l33t
Joined: 06 Dec 2002 Posts: 620
|
Posted: Sat Aug 19, 2006 8:18 pm Post subject: |
|
|
melinux wrote: | Is there a problem with the latest rsync?
When I start it I get this error:
* Starting rsyncd ...
rsync: --safe-links: unknown option (in daemon mode)
(Type "rsync --daemon --help" for assistance with daemon mode.)
rsync error: syntax or usage error (code 1) at options.c(857) [client=2. [ !! ]
|
--safe-links is no longer needed or supported in daemon mode. I've updated the howto to reflect this. Just remove --safe-links and it should work fine. |
|
Back to top |
|
|
katafitos n00b
Joined: 22 Nov 2006 Posts: 56 Location: Greece
|
Posted: Tue Jun 12, 2007 4:17 pm Post subject: |
|
|
I have a problem with the Local Rsync Mirror
When I test sync with emerge --sync I get this
Code: | >>> Starting rsync with rsync://192.xxx.xxx.xxx/gentoo-portage...
>>> Checking server timestamp ...
rsync: read error: Connection reset by peer (104)
rsync error: error in rsync protocol data stream (code 12) at io.c(609) [receiver=2.6.9]
|
I can't figure out what's the cause of this. Any idea? |
|
Back to top |
|
|
shrike Apprentice
Joined: 20 Feb 2004 Posts: 187 Location: Closer to home
|
Posted: Thu Jun 21, 2007 2:01 am Post subject: |
|
|
katafitos,
This is a long shot but check the RSYNC_TIMEOUT value in /etc/make.conf. Default is 30. I recall similiar error msgs when I had that set to a value of 5.
shrike |
|
Back to top |
|
|
katafitos n00b
Joined: 22 Nov 2006 Posts: 56 Location: Greece
|
Posted: Thu Jun 21, 2007 2:24 pm Post subject: |
|
|
shrike wrote: | katafitos,
This is a long shot but check the RSYNC_TIMEOUT value in /etc/make.conf. Default is 30. I recall similiar error msgs when I had that set to a value of 5.
shrike |
Thank you very much shrike!!
that did the trick!! |
|
Back to top |
|
|
Guybrush Tux's lil' helper
Joined: 06 Feb 2003 Posts: 99 Location: 48°27'N, 11°8'O
|
Posted: Wed Nov 14, 2007 6:50 pm Post subject: |
|
|
For all with a local rsync mirror who have problems syncing and get the error message "rsync: on remote machine: --no-specials: unknown option":
I had a problem syncing my local portage mirror with the portage tree. It seems that the meaning of the rsync-parameter --devices has changed as of rsync version 2.6.7. Just add "--special" to the list of rsync parameters and it should work again. I also have filed a bug report. Hope that helps. |
|
Back to top |
|
|
carpman Advocate
Joined: 20 Jun 2002 Posts: 2202 Location: London - UK
|
Posted: Thu Nov 15, 2007 5:15 pm Post subject: |
|
|
Hello, am getting following error on starting deamon
Code: |
/etc/init.d/rsyncd start
* Starting rsync daemon ...
rsync: --timeout=300: unknown option (in daemon mode)
(Type "rsync --daemon --help" for assistance with daemon mode.)
rsync error: syntax or usage error (code 1) at options.c(878) [client=2.6.9]
|
Code: |
cat /etc/init.d/rsyncd
#!/sbin/runscript
# Copyright 1999-2004 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
# $Header: /var/cvsroot/gentoo-x86/net-misc/rsync/files/rsyncd.init.d,v 1.5 2007/02/23 11:33:59 uberlord Exp $
depend() {
use net
}
# FYI: --sparce seems to cause problems.
RSYNCOPTS="--daemon --timeout=300"
start() {
ebegin "Starting rsync daemon"
start-stop-daemon --start --quiet --pidfile /var/run/rsyncd.pid --nicelevel 15 --exec /usr/bin/rsync -- ${RSYNCOPTS}
eend $?
}
stop() {
ebegin "Stopping rsync daemon"
start-stop-daemon --stop --quiet --pidfile /var/run/rsyncd.pid
eend $?
}
|
cheers _________________ Work Station - 64bit
Gigabyte GA X48-DQ6 Core2duo E8400
8GB GSkill DDR2-1066
SATA Areca 1210 Raid
BFG OC2 8800 GTS 640mb
--------------------------------
Notebook
Samsung Q45 7100 4gb |
|
Back to top |
|
|
zappatized n00b
Joined: 18 Aug 2012 Posts: 21
|
Posted: Wed Aug 29, 2012 2:26 pm Post subject: Quick n dirty rsync/distfiles mirror (for other newbies) |
|
|
I have been trying to set up a local (personal) mirror for some time. There are a lot of guides but for now I'm just looking for a simple solution that I can implement right away. It was fairly straightforward to follow the official guide for local portage tree syncing, but trying to mirror distfiles proved more elusive. To save others the trouble of sorting through numerous forum posts I'd like to share my setup culled from those posts. This setup requires no packages beyond what is included in the base system.
Code: | # /etc/rsyncd.conf
uid = nobody
gid = nobody
use chroot = yes
munge symlinks = yes
# Limit access to private LAN (substitute with 10.0.0.0/24 depending on router, check with '$ route')
hosts allow = 192.168.1.0/24
max connections = 15
# This line is required by the /etc/init.d/rsyncd script
pid file = /var/run/rsyncd.pid
motd file = /etc/motd.rsyncd
# This provides a separate log file
log file = /var/log/rsync.log
# This will log every file transferred - up to 85,000+ per user, per sync
#transfer logging = yes
log format = %t %a %m %f %b
syslog facility = local3
timeout = 300
# Simple example for enabling your own local rsync server
[gentoo-portage]
path = /usr/./portage
comment = Funtoo Portage tree
exclude = /distfiles /packages
# For distributing Portage sources (distfiles) to internal clients
[gentoo-distfiles]
path = /usr/./portage
comment = Gentoo Distfiles mirror
include = /distfiles
|
No changes were made to /etc/init.d/rsyncd. /etc/conf.d/rsyncd contains the following options:
Code: | RSYNC_OPTS="--quiet --recursive --links --perms --times --devices --delete --nicelevel 15"
|
Start the rsyncd daemon on the local server and add to default runlevel. Edit make.conf for client computers:
Code: | SYNC="rsync://<localserver ip or name>/gentoo-portage"
GENTOO_MIRRORS="rsync://<localserver ip or name>/gentoo-distfiles ..."
|
I haven't set up a binhost yet but if I do I would start by duplicating the rsync distfiles module for the packages dir and then configure PORTAGE_BINHOST on the client(s) and PORTAGE_BINHOST_HEADER_URI on the server. |
|
Back to top |
|
|
msst Apprentice
Joined: 07 Jun 2011 Posts: 259
|
Posted: Sat Jan 12, 2013 1:37 pm Post subject: |
|
|
Hmm, I am considering to set up a local mirror, but I do not want to run an additional daemon on my mini-box. Theres already sshd on it and all is set up.
How do I use rsync over ssh without setting up rsyncd? If I use the rsync program to access my mini-box, then it already copies things over using ssh. What to do to make emerge use this mechanism? |
|
Back to top |
|
|
pgu l33t
Joined: 30 Jul 2009 Posts: 721 Location: Oslo, Norway
|
Posted: Sun Dec 14, 2014 11:50 am Post subject: |
|
|
This is 10 years old. Is it still valid? Or are there easier ways obtain a local sync cache today? |
|
Back to top |
|
|
Ant P. Watchman
Joined: 18 Apr 2009 Posts: 6920
|
Posted: Sun Dec 14, 2014 10:39 pm Post subject: |
|
|
There are a bunch of other options, like:
- Share $PORTDIR over NFS, though this doesn't address the fact your initial rsync from upstream is still dangerously insecure.
- Use webrsync and a caching HTTP proxy (which would also work for distfiles downloads).
- Use one of the many git mirrors of the portage tree (or switch to Funtoo), and run a local git-daemon
"Easier" is always going to be subjective though. |
|
Back to top |
|
|
steveL Watchman
Joined: 13 Sep 2006 Posts: 5153 Location: The Peanut Gallery
|
Posted: Mon Dec 15, 2014 5:21 pm Post subject: |
|
|
distfiles is best done over sftp, ime; I don't recall the details but I used to have that setup for my old laptop, with the user allowed write access in order to save off new downloads.
Then rsync over ssh, separately, for portage tree. |
|
Back to top |
|
|
|