This is the mail archive of the
cygwin
mailing list for the Cygwin project.
Re: rsync still broken
- From: Linda Walsh <cygwin at tlinx dot org>
- To: cygwin at cygwin dot com
- Date: Thu, 19 Mar 2015 17:14:18 -0700
- Subject: Re: rsync still broken
- Authentication-results: sourceware.org; auth=none
- References: <CAKf2h5TzBP7KYO+NhZ7oVRpb-O_q86RvFxa1NacVWgRVu8BfRA at mail dot gmail dot com> <5501F852 dot 3060301 at tlinx dot org> <CAKf2h5RcKYingYXezbvXpHPVeYNCu=uXwb7p_CVK1dJAhgV1aA at mail dot gmail dot com>
Frank Fesevur wrote:
... I use --numeric-ids and I have these two lines in the rsyncd.conf
uid = 0
gid = 0
---
How is your local rsync talking to the server?
I.e. using the 'rsyncd' daemon running on the server?
For me, I don't have the rsyncd daemon running full time on the
server, but use the "remote shell" option with my RSYNC_RSH environment
var set to 'ssh'. Just reading on the man page that this is the
default on most systems these days.
If you use the "rsyncd" daemon, you should read the rsyncd.conf manpage:
Especially this section:
uid This parameter specifies the user name or user ID ...
The default
when run by a super-user is to switch to the systemâs "nobody"
user. The default for a non-super-user is to not try to change
the user. See also the "gid" parameter.
---
It doesn't look like uid and gid set to 0 will "just work".
If you use the 'ssh' protocol for transfers, you would need to be
able to login from your local system to the server as 'root' with
no password:
i.e.:
ssh root@server
If that doesn't work -- rsync probably won't work correctly either.
But the thing that surpises me is that in 3.0.9 is just worked.
---
I'm still at 3.0.9 and don't want to break things, but you are right:
---
law.Bliss> whoami
Bliss\law
law.Bliss> mkdir cygwin
law.Bliss> mkdir /h/cygwin ## /h=homedir on server
law.Bliss> llg -a /h/cygwin
total 0
drwxrwxr-x+ 1 Bliss\law lawgroup 0 Mar 19 17:07 ./
drwxr-xr-x+ 1 Bliss\law lawgroup 0 Mar 17 20:36 ../
law.Bliss> echo "test" >cygwin/test.txt
law.Bliss> rsync -a cygwin/. ishtar:cygwin/.
law.Bliss> llg -a /h/cygwin
total 4
drwxrwxr-x+ 1 Bliss\law lawgroup 0 Mar 19 16:42 ./
drwxr-xr-x+ 1 Bliss\law lawgroup 0 Mar 17 20:36 ../
-rw-rw-r-- 1 Bliss\law lawgroup 5 Mar 19 16:42 test.txt
law.Bliss> rsync -v
rsync version 3.0.9 protocol version 30
----
Yup -- seems to work in 3.0.9.
BTW -- rsync is pretty slow for some transfers -- created
a 1G local file and timed transfers with rsync, cp and dd.
with 'dd' I used "direct" which should be synchronous/unbuffered,
but I don't think rsync or cp have options to turn that off.
Still 'dd' was fastest, followed by 'cp' and rsync, well:
law.Bliss> dd if=/dev/zero of=1G bs=1M count=1024 oflag=direct
1024+0 records in
1024+0 records out
1073741824 bytes (1.1 GB) copied, 1.96472 s, 547 MB/s #local file
law.Bliss> time rsync 1G ishtar:cygwin/
18.76sec 3.43usr 2.40sys (31.07% cpu) #using rsync proto
law.Bliss> rm /h/cygwin/1G
law.Bliss> time cp 1G /h/cygwin
8.53sec 0.00usr 0.77sys (9.13% cpu) #cp using SMB/CIFS
law.Bliss> rm /h/cygwin/1G
law.Bliss> time dd if=1G of=/h/cygwin/1G bs=1M count=1024 oflag=direct
1024+0 records in
1024+0 records out
1073741824 bytes (1.1 GB) copied, 6.91213 s, 155 MB/s # dd using SMB/CIFS
6.95sec 0.01usr 0.67sys (9.85% cpu)
law.Bliss> rm /h/cygwin/1G # rsync using SMB/CIFS
law.Bliss> time rsync 1G /h/cygwin/
29.18sec 3.52usr 3.08sys (22.65% cpu)
You might try reinstalling 3.0.9 and see if that still works --
would help narrow it down to whether or not it is in cygwin or in
rsync.
--
Problem reports: http://cygwin.com/problems.html
FAQ: http://cygwin.com/faq/
Documentation: http://cygwin.com/docs.html
Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple