Re: Status of rsync + cygwin

2003-08-05 Thread Max Bowsher
Edward Grace wrote:
 Dear All,

 I have been following the rsync discussion list for some time,
 particularly with reference to the rsync problems on Cygwin.  From my
 understanding there are two (seperate) issues.

 1) Rsync can wait indefinitely due to some form of child/signal handling
 problem (I imagine this can be a pain to get right for all the different
 platforms)

 2) Long file names that are still within the POSIX limit can't always be
 read.

 My understanding is that (1) is a rsync problem, for which a number of
 patches have been proposed and (2) appears to be a cygwin problem.

I have never heard about (2) before, and I read most of the traffic on both
cygwin and rsync lists.

 Could you advise me as to:
 * when (1) is likely to find its way into a rsync / cygwin release

You should probably just watch this list.

 * where the patches are (there was some confusion) and where to find info
 on building under cygwin.

Search the mailing list archives for patch info.

Get the Cygwin rsync source package for canonical info about building on
Cygwin. Basically, the usual ./configure  make  make install.

 * Where to ask about the cygwin issues (I am asking here as I imagine
 people here know a lot of the relevent people there)

Try to make a reasonable guess whether it is more cygwin or rsync related,
and let that guide you. There are enough people on both lists to suggest you
switch to the other if it would make more sense.

Max.

-- 
To unsubscribe or change options: http://lists.samba.org/mailman/listinfo/rsync
Before posting, read: http://www.catb.org/~esr/faqs/smart-questions.html


Re: cygwin rsync hang under Windows Terminal Services session

2003-07-16 Thread Max Bowsher
Alan Adams (DSLWN) wrote:
 Hi, though the list would be interested to know an issue we have just come
 across.

 We have found that rsync version 2.5.6 over ssh within a cygwin
environment
 run manually from either a command prompt or a cygwin prompt hangs every
 time if we run it in a Windows Terminal Server session. It doesn't seem to
 matter what the remote server is as we have experienced this when the
remote
 server is Win2K running cygwin and a native Linux. But it doesn't hang
when
 we run it from the Windows console or in a VNC session or via an ssh
 terminal session. I assume this means the terminal environment set up by a
 WTS session is somehow different and either cygwin or ssh or rsync is not
 handling it. The environment we have tested this in is as follows;

 Client
 - Win2K SP2 and SP3
 - cygserver (cygwin) 1.5, API version 1.3.22(0.78/3/1)-(1.0.0.2)
2003-03-18
 09:20, Compiled on Mar 18 2003 (output from cygserver -v)

Care! Using cygserver like this is inappropriate. Cygserver is a
still-under-early-development very specific tool to provide additional
functionality to Cygwin. It is actually no longer installed by default under
current dev builds of 1.5.

The *correct* way to obtain cygwin1.dll version information is uname -rv.

Max.

-- 
To unsubscribe or change options: http://lists.samba.org/mailman/listinfo/rsync
Before posting, read: http://www.catb.org/~esr/faqs/smart-questions.html


Re: patch draft for extended attributes on linux

2003-06-26 Thread Max Bowsher
Martin Pool wrote:
 On 25 Jun 2003, Wayne Davison [EMAIL PROTECTED] wrote:
 On Wed, Jun 25, 2003 at 10:34:38AM +1000, Martin Pool wrote:
 There is no mtime for xattrs, so they are transferred every time as
 part of the file list.

 One possibly better solution would be to create some kind of CRC of the
 xattr data (MD4/MD5/whatever) and send just that in the file list for
 each file.  This would allow you to figure out when to update the xattr
 data, but the protocol would need to be modified to send the xattr data
 during the file-update phase (and possibly to allow the reciever to
 request just an xattr update without doing a file update).

 That's a pretty good idea.  For the moment I just wanted a minimal
 patch, as traffic size is not an overwhelming consideration for the
 particular user I was helping.

 However, for many realistic cases the xas are quite small.  It is
 entirely possible for a file's attr and value them to be smaller than
 a 20-byte SHA1.  (Well, perhaps not with my inefficient packing, but
 in principle they might be.)

In the case of xattrs-as-acls, it is quite likely that the same acl will be
applied to many different files. It might therefore be worth considering a
table-based approach: File foo has acl has attribute number 3, where the
attribute numbers refer to a table constructed at file-list generation time.


Max.

-- 
To unsubscribe or change options: http://lists.samba.org/mailman/listinfo/rsync
Before posting, read: http://www.catb.org/~esr/faqs/smart-questions.html


Re: Using include/exclude options

2003-06-26 Thread Max Bowsher
Jason Williams wrote:
 Hello everyone.

 I have a question about using the include/exclude function for rsync.
 What I am trying to do is backup specific directories and their
 corresponding data, while at the same time, excluding other directories.

 Specifically, I have a backup server with the follow setup:

 /backupstorage/D/...all the directories are here...there are roughly 18
 directories.

 So what I was trying to do was create a file that I can point to specify
 what directories I want backed up.

 Here is what I was attempting:

 rsync -avn --include-file=/home/rsyncfile /backupstorage/D/ /home/rsyncbak

 It is a dry run of course. However, it still wants to backup everything in
 the /backupstorage/D/.

 Here is a quick snip of what is in my rsyncfile:

 /backupstorage/D/1999 TaxReturns/
 /backupstorage/D/Appraisals/
 /backupstorage/D/CLOSED00/
 /backupstorage/D/CLOSED01/
 /backupstorage/CLOSED02/
 /backupstorage/D/CLOSED97/
 /backupstorage/D/CLOSED98/
 /backupstorage/D/CLOSED99/

 Im guessing that im not specifying correctly in the file.

 Anyone have any input on what im doing wrong?

The default is include. Since you haven't excluded anything, everything is
either included-explicitly or included-by-default.


Max.

-- 
To unsubscribe or change options: http://lists.samba.org/mailman/listinfo/rsync
Before posting, read: http://www.catb.org/~esr/faqs/smart-questions.html


Re: [rfc idle thought] exclude pattern left anchor

2003-06-05 Thread Max Bowsher
jw schultz wrote:
 A thought has been nagging me for a bit now so i'll run it
 up the flagpole and see if anyone salutes.

 There seems to be quite a bit of confusion regarding the use
 of the leading slash as a top of tree anchor for exclude
 patterns.  The manpage seems clear enough to me but somehow
 it doesn't seem to get through.

 What if we allowed a leading circumflex (^) to serve the
 same function.  We could then change the documentation to
 reflect the newer usage.

 People are used to a leading ^ meaning anchor-left.
 It does have the disadvantage of making it difficult to
 match filenames with a leading ^ but those are quite rare.

 I wouldn't even think of such a change were it not for the
 frequency with which people confuse the meaning of a leading
 slash.

OK, here is one user's opinion:

Using the / as an anchor seems more elegant to me, given that it means the
root of the synced area.

Also, I can't help wondering if people would then get confused and try to
use regexps as exclude patterns.


Max.

-- 
To unsubscribe or change options: http://lists.samba.org/mailman/listinfo/rsync
Before posting, read: http://www.catb.org/~esr/faqs/smart-questions.html


Re: WARNING: rsync mirror is erased when remote HD-dies

2003-04-05 Thread Max Bowsher
[EMAIL PROTECTED] wrote:
 Hello,

 this is the excerpt from the rsync_backup.sh

 # OK the filesystems should be mounted
 # lets start the rsync process
 rsync -arlpogtDvx --delete --force /mnt/nfs_mirror_src
/mnt/nfs_mirror_dest

-a = -rlptgoD, so you can shorten that to -avx

If nothing is mounted on /mnt/nfs_mirror_src, then of course it will look
like an empty directory, and rsync will empty /mnt/nfs_mirror_dest to match.

You are aware that using NFS prevents rsync's remote-update algorithm from
giving you any benefits, aren't you?

Keeping one single backup is risking dataloss even without this particular
case. Maybe you could use the linked incremental backup approach?

Alternatively, I vaguely remember some patches that enforced a maximum limit
on the number of files to delete in one rsync run. Kind of a kludge, though.

Max.

-- 
To unsubscribe or change options: http://lists.samba.org/mailman/listinfo/rsync
Before posting, read: http://www.tuxedo.org/~esr/faqs/smart-questions.html


Re: structure only

2003-03-25 Thread Max Bowsher
[EMAIL PROTECTED] wrote:
 Hi people,

 I used to copy filesystem structures ( only Directories ) with rsync
 version 2.3.1.
 For this I used

 rsync -e ssh -trulogxp - -include */ - -exclude *
 remotemaschine:/source /localtraget

 Now, on a new maschine with rsync version 2.5.5 that doesn´t work any
 more. Now rsync copies directories and files, too.

 Is is possible to do a workaround with the newer version(s) ?
 Or is it a bug ?

Run with -vv to see how the include/exclude it being applied. That usually
shows why it's not doing what you want.

Max.

-- 
To unsubscribe or change options: http://lists.samba.org/mailman/listinfo/rsync
Before posting, read: http://www.tuxedo.org/~esr/faqs/smart-questions.html


Re: Transfer files bigger than 1383275520 bytes - Rsync compiledincygwin

2003-03-25 Thread Max Bowsher
Christian wrote:
 Hello,

 I can't transfer big files. In the output below, you can see that rsync
 only transfer 1383275520 of a 5448046592 bytes file:

Cygwin doesn't support large files. (Yet)

 $ rsync --version
 rsync  version 2.5.6  protocol version 26
 Copyright (C) 1996-2002 by Andrew Tridgell and others
 http://rsync.samba.org/
 Capabilities: 32-bit files, socketpairs, hard links, symlinks, batchfiles,


See? 5448046592 is larger than can be represented with 32 bits.


Max.


-- 
To unsubscribe or change options: http://lists.samba.org/mailman/listinfo/rsync
Before posting, read: http://www.tuxedo.org/~esr/faqs/smart-questions.html


Re: Need Help.

2003-03-23 Thread Max Bowsher
derix suartyo wrote:
 Dear Expert,

 I'm very newbie with rsync and i just installed RSYNC
 in both of my servers. Let say the server is ServerA
 (10.1.1.1) and ServerB (10.1.1.2). Rsync daemon runs
 in server A. The rsycnd.conf is like this (i save this
 file in /etc/rsyncd.conf):

 uid = rsync
 gid = rsync
 use chroot  = no
 max connections = 4
 syslog facility = local5
 auth users  = root
 secrets file= /etc/rsyncd.secrets
 pid file= /var/run/rsyncd.pid
 [derix]
 path= /home/derix
 comment = testing rsync

 and my secret file is like this:
 root:abc123

 I checked the process by typing ps -ef | grep rsync
 and the result is like this:
 root  5487 1  0 13:05 ?00:00:00 rsync
 --daemon

This part refers to the rsync daemon method of connection.

 When i try to download the data from ServerA to
 ServerB,the password prompt occured. I use this
 command:
 rsync -a -e ssh [EMAIL PROTECTED]:/home/derix
 /home/derix/dat/

This bit refers to connection via ssh. They are totally different. You need
to decide which one you want to use.

Max.

-- 
To unsubscribe or change options: http://lists.samba.org/mailman/listinfo/rsync
Before posting, read: http://www.tuxedo.org/~esr/faqs/smart-questions.html


Re: [RFC] protocol version

2003-03-22 Thread Max Bowsher
jw schultz wrote:
 I'm in the midst of coding a patch set for consideration
 that will bump the protocol version and have a couple of
 observations.

 The current minimum backwards-compatible protocol is 15
 but we have code that checks for protocol versions as old as
 12.  If someone else doesn't beat me to it i'm considering
 cleaning out the pre-15 compatibility code.  A backwards
 compatibility patch could be created for those that want to
 keep it.

 The current protocol version is 26.  Once i increment it
 that will be 27 (duh!) Currently the maximum compatible remote
 protocol is 30.  This should be bumped up to 35 or 40.

 It has been a long time since protocol 15.  I'm not
 suggesting changing the minimum yet, but i am thinking it
 might be a good idea to add a OLD_PROTOCOL_VERSION and if
 the remote_version = OLD_PROTOCOL_VERSION kick out a
 warning.  I was thinking version 19 for now since 20 was
 introduced about four years ago.  A few revs (a year or so)
 from now we could then advance the MIN to the OLD and bump
 up the OLD and clean out some more cruft.

Four years of non-deprecated backwards compatibility sounds extremely
generous.
As a comparison point, unison offers no backward compatibility at all!


Max.

-- 
To unsubscribe or change options: http://lists.samba.org/mailman/listinfo/rsync
Before posting, read: http://www.tuxedo.org/~esr/faqs/smart-questions.html


Re: CYGWIN Rsync exclude/include problem

2003-03-21 Thread Max Bowsher
Mike Lavender wrote:
 I'm having troubles with getting rsync 2.5.5 (CYGWIN version) to
 include/exclude files they way I expect it to. I have mulled over the
 list postings and man pages regarding this and I am either missing
 something or ... well I don' know.

 I have a drive with 12 folders in the root however, I only want to rsync
 5 of them (the ones marked with an *) and in those 4 I want to exclude
 certain folders and file patterns. The Root looks like this:

 /Backup
 /Copied DVD
 /Databases*
 /Documents and Settings*
 /Inetpub*
 /Plus11*
 /Program Files
 /rsync*
 /Temp
 /Windows
 /Trial Software
 /wmpub

 Using the following command line and includes.txt file I still get the
 Backup, Copied DVD etc folders. If I add a global * or /* then nothing
 gets rsynced. I have commented the include file to explain my logic.
 Any advice would be great!

 Thanks in advance.
 Mike Lavender
 ===

 Command Line:
 rsync -avvvzl --stats --delete --delete-excluded
 --exclude-from=c:\rsync\includes.txt /cygdrive/c/ [EMAIL PROTECTED]::LaptopBackup
 ^

Are you running this from the Cygwin shell (bash)? If so, the shell will eat
the backslashes. Try writing it as /cygdrive/c/rsync/includes.txt. If that
doesn't work, then run with -vv to get info on how the exclude patterns are
working.


Max.


 includes.txt:
 + /Databases/#Include /Databases  subfolders

 + /Documents and Settings/ #Include /Documents and Settings 
 subfolders
 - /Documents and Settings/NetworkService/ #Exclude /NetworkService
 subfolders
 - /Documents and Settings/LocalService/ #Exclude /LocalService
 subfolders
 - /Documents and Settings/All Users/ #Exclude /All Users subfolders
 - /Documents and Settings/Default Users/ #Exclude /Default Users
 subfolders

 + /Inetpub/#Include /Inetpub  subfolders
 + /Inetpub/wwwroot/#Include /Inetpub/wwwroot  subfolders
 - /Inetpub/*#Exclude /files and other folders?? in Inetpub

 + /Plus11/
 + /Plus11/MYOBData/
 + /Plus11/Forms/
 + /Plus11/Old*/#Include folders that start with Old
 - /Plus11/*

 + /rsync/

 - *.tmp#Exclude all *.tmp files
 - Temp/#Exclude all Temp folders
 - UserData/#Exclude all UserData folders
 - *.dmp
 - Temporary Internet Files/
 - cache/
 - RECYCLER/
 - Help/
 - /* #exclude not specifically included files * folders in the root.

-- 
To unsubscribe or change options: http://lists.samba.org/mailman/listinfo/rsync
Before posting, read: http://www.tuxedo.org/~esr/faqs/smart-questions.html


Re: CYGWIN Rsync exclude/include problem

2003-03-21 Thread Max Bowsher
Dalton Harvie wrote:
 Newbie response:

 How about:

 rsync -avvvzl --stats --delete --delete-excluded
 --exclude-from=c:\rsync\includes.txt /cygdrive/c/* [EMAIL PROTECTED]::LaptopBackup

 as I've had problems with the --delete flag without using the * before

NOT advisable. Adding * is unneccessarily complicating matters.

It is much easier to envisage the simple one source one destination case
(and therefore easier to write exclude lists) than to try using multiple
source syncs on the components of the toplevel directory.

Max.


 (see down the list a bit, can't delete older file/directory links on
 another local partition after `snapshot' type backup script)

 and for the file something like

 - *.tmp# put these first as runs through list from top
 - Temp/#Exclude all Temp folders
 - UserData/#Exclude all UserData folders
 - *.dmp
 - Temporary Internet Files/
 - cache/
 - RECYCLER/
 - Help/

 + /Databases/#Include /Databases  subfolders
 + /Databases/**  # includes all the files and tree under this

 + /Documents and Settings/ #Include /Documents and Settings 
 subfolders - /Documents and Settings/NetworkService/ #Exclude
 /NetworkService subfolders
 - /Documents and Settings/LocalService/ #Exclude /LocalService
 subfolders
 - /Documents and Settings/All Users/ #Exclude /All Users subfolders
 - /Documents and Settings/Default Users/
 + /Documents and Settings/**

 # other directories included in the same way

 - * #exclude everything else

 Maybe this might work?  Dalton Harvie.

 On Friday 21 March 2003 10:22, Mike Lavender wrote:
 I'm having troubles with getting rsync 2.5.5 (CYGWIN version) to
 include/exclude files they way I expect it to. I have mulled over the
 list postings and man pages regarding this and I am either missing
 something or ... well I don' know.

 I have a drive with 12 folders in the root however, I only want to rsync
 5 of them (the ones marked with an *) and in those 4 I want to exclude
 certain folders and file patterns. The Root looks like this:

 /Backup
 /Copied DVD
 /Databases*
 /Documents and Settings*
 /Inetpub*
 /Plus11*
 /Program Files
 /rsync*
 /Temp
 /Windows
 /Trial Software
 /wmpub

 Using the following command line and includes.txt file I still get the
 Backup, Copied DVD etc folders. If I add a global * or /* then nothing
 gets rsynced. I have commented the include file to explain my logic.
 Any advice would be great!

 Thanks in advance.
 Mike Lavender
 ===

 Command Line:
 rsync -avvvzl --stats --delete --delete-excluded
 --exclude-from=c:\rsync\includes.txt /cygdrive/c/ [EMAIL PROTECTED]::LaptopBackup

 includes.txt:
 + /Databases/#Include /Databases  subfolders

 + /Documents and Settings/ #Include /Documents and Settings 
 subfolders - /Documents and Settings/NetworkService/ #Exclude
 /NetworkService subfolders - /Documents and Settings/LocalService/
 #Exclude /LocalService subfolders - /Documents and Settings/All Users/
 #Exclude /All Users subfolders - /Documents and Settings/Default Users/
 #Exclude /Default Users subfolders

 + /Inetpub/#Include /Inetpub  subfolders
 + /Inetpub/wwwroot/#Include /Inetpub/wwwroot  subfolders
 - /Inetpub/*#Exclude /files and other folders?? in Inetpub

 + /Plus11/
 + /Plus11/MYOBData/
 + /Plus11/Forms/
 + /Plus11/Old*/#Include folders that start with Old
 - /Plus11/*

 + /rsync/

 - *.tmp#Exclude all *.tmp files
 - Temp/#Exclude all Temp folders
 - UserData/#Exclude all UserData folders
 - *.dmp
 - Temporary Internet Files/
 - cache/
 - RECYCLER/
 - Help/
 - /* #exclude not specifically included files * folders in the root.

-- 
To unsubscribe or change options: http://lists.samba.org/mailman/listinfo/rsync
Before posting, read: http://www.tuxedo.org/~esr/faqs/smart-questions.html


Re: problems with rsync in cygwin

2003-03-18 Thread Max Bowsher
Jim Gallagher wrote:
 $ rsync -a /cygdrive/c/installs/palm rsync://192.168.2.3/palm
 rsync: Unknown Host
 rsh.exe: can't establish connection  == ???
...
 I thought the docs said that rsync protocol would be used if I used
 the rsync:// URL. It still wants to use rsh. I'm using rsync version
 2.5.5 under Cygwin.

In the release notes for 2.5.6:
* The rsync:// syntax for daemon connections is now accepted in the
  destination field.

Max.

-- 
To unsubscribe or change options: http://lists.samba.org/mailman/listinfo/rsync
Before posting, read: http://www.tuxedo.org/~esr/faqs/smart-questions.html


Re: Recursive filetype include

2003-03-14 Thread Max Bowsher
Mark Palatucci wrote:
 Hello,

 I have a directory tree that contains many files of type .htm. I don't
 want these when I rsync - so I used the option --exclude '*.htm'

 There is however, one subdirectory (and all of its subdirectories)
 that I would like to include these .htm files.

 I tried using many variations of --include 'subdir/*.htm' but this
 does not seem to work. It includes the .htm's in the main subdirectory
 - but not any of its subdirectories.

 Is there anyway I can get rsync to recursively include this filetype
 for all the subdirectories of a subdirectory - yet exclude these types
 for all the other branches of the main directory tree?

 Any info would be most appreciated,

Please post your exact command line and a careful description of your
directory structure. You are certainly thinking along the right lines, but
without details, its hard to know why it isn't working for you.


Max.

-- 
To unsubscribe or change options: http://lists.samba.org/mailman/listinfo/rsync
Before posting, read: http://www.tuxedo.org/~esr/faqs/smart-questions.html


Re: Recursive filetype include

2003-03-14 Thread Max Bowsher
Mark Palatucci wrote:
 Hi Max,
 
 The exact line is:
 
 /usr/local/bin/rsync --rsh=ssh -azvv --delete --force --include
 'cpp/*.htm' --exclude '*.htm' --exclude CVS* --exclude 'Makefile'
 --exclude '*.sh' --exclude '*.psd' $localdir/ [EMAIL PROTECTED]:www/
 
 
 This gets .htm's in cpp/, but not in dirs like cpp/foo/ or cpp/bar/

man rsync, and search for **  should help you there.

Max.

-- 
To unsubscribe or change options: http://lists.samba.org/mailman/listinfo/rsync
Before posting, read: http://www.tuxedo.org/~esr/faqs/smart-questions.html


Re: rsync alternatives for large mirrors?

2003-03-12 Thread Max Bowsher
Mike Loseke wrote:
  Anyone here ever use or see any tools (free or commercial) that are
 similar to rsync but maybe provide a little more in the way of
 reporting features? I'm looking into some possible alternatives to a
 system I have scratched together using rsync. I'm bumping into some
 issues involved more on the backend of my system (stats on directory
 structures and contents) which is limiting the amount of data I can
 sync in an 8 hour window to about 120GB. I'd like to be able to sync
 300GB+ in the same timeframe and still get my backend tasks completed.
 
  Currently those backend tasks that are eating up a fair bit of time
 consist of doing a du like action on the trees at either end which
 is used to generate a report which can be referenced by users so they
 know when data is in sync. Ideally I'd like an update as you go
 sort of method but I haven't figured out a way to do this with rsync.
 I do use rsync's output stats in addition to my own.

Augment rsync's output stats to include everything you need?

Max.

-- 
To unsubscribe or change options: http://lists.samba.org/mailman/listinfo/rsync
Before posting, read: http://www.tuxedo.org/~esr/faqs/smart-questions.html


Re: Questions about exclude-file

2003-03-10 Thread Max Bowsher
Max Kipness wrote:
 Thanks for the response.

 Concerning the first question of excluding pagefile.sys, yes it would
 indeed be in use. So you are saying that you cannot exclude a file
 that is in use?

Just to demonstrate how weird this situation is:

[EMAIL PROTECTED] [~] $ ls /c
ls: /cygdrive/c/pagefile.sys: No such file or directory
AUTOEXEC.BATIO.SYS RECYCLER   boot.ini
CONFIG.SYS  MSDOS.SYS  System Volume Information
egathered.xml
DevProgsNTDETECT.COM   Video  ntldr
Documents and Settings  Program Files  WINDOWS

Note that pagefile.sys doesn't show up in the dirlist!


Max Bowsher.

-- 
To unsubscribe or change options: http://lists.samba.org/mailman/listinfo/rsync
Before posting, read: http://www.tuxedo.org/~esr/faqs/smart-questions.html


Re: rsync and timestamps of local files

2003-03-08 Thread Max Bowsher
Haisam K. Ido wrote:
 Max Bowsher wrote:
 Haisam K. Ido wrote:
 
 bob parker wrote:
 
 I think so. It compares the size and timestamp of your local file
 with the remote one of the same name of course. If it all matches
 nothing is done unless you force it.
 
 If it does that then it is not doing what I'm asking about.
 
 I need to know if it checks the local files relative to a local log
 file that it keeps of previous rsyncings. If it finds differences
 between the local file and the log file content will it then and
 only them perform a diff with the remote file with the same name?
 
 
 There is no such log file.
 
 Is'nt that inefficient for the network traffic?

Maybe. Depends on the usage scenario.

Max.

-- 
To unsubscribe or change options: http://lists.samba.org/mailman/listinfo/rsync
Before posting, read: http://www.tuxedo.org/~esr/faqs/smart-questions.html


Re: Getting nowhere syncing a download

2003-03-06 Thread Max Bowsher
bob parker wrote:
 I must be doing something wrong with this, but I am trying to correct
 a downloaded iso which does not match the source md5sum.
 
 This is what I do:
 
 rsync
 rsync://ftp.gwdg.de/pub/linux/knoppix/KNOPPIX_V3.1-2003-01-20-EN.iso
 KNOPPIX_V3.1-2003-01-20-EN.iso 
 
 The command returns in a few seconds without any error message and
 nothing has changed with the md5sum on my copy.

Try using -vv for details on what's happening.


Max.

-- 
To unsubscribe or change options: http://lists.samba.org/mailman/listinfo/rsync
Before posting, read: http://www.tuxedo.org/~esr/faqs/smart-questions.html


Re: Getting nowhere syncing a download

2003-03-06 Thread Max Bowsher
bob parker wrote:
 
 Ok, here it is.
 [EMAIL PROTECTED]:~/archive/knoppix$ rsync -vv
 rsync://ftp.gwdg.de/pub/linux/knoppix/KNOPPIX_V3.1-2003-01-20-EN.iso
 KNOPPIX_V3.1-2003-01-20-EN.iso
 opening tcp connection to ftp.gwdg.de port 873
 KNOPPIX_V3.1-2003-01-20-EN.iso is uptodate
 wrote 102 bytes  read 85 bytes  41.56 bytes/sec
 total size is 732921856  speedup is 3919368.21
 
 And the md5sum check
 
 [EMAIL PROTECTED]:~/archive/knoppix$ md5sum -c
 KNOPPIX_V3.1-2003-01-20-EN.iso.md5 md5sum: MD5 check failed for
 'KNOPPIX_V3.1-2003-01-20-EN.iso' 
 
 I downloaded the md5sum again just to be sure but it still fails.

Curious. I wonder why rsync thinks the file is up to date.

Maybe the -I or -c options would make it look more carefully.


Max.



-- 
To unsubscribe or change options: http://lists.samba.org/mailman/listinfo/rsync
Before posting, read: http://www.tuxedo.org/~esr/faqs/smart-questions.html


Re: Getting nowhere syncing a download

2003-03-06 Thread Max Bowsher
bob parker wrote:
 On Fri, 7 Mar 2003 03:47, Max Bowsher wrote:
 bob parker wrote:
 Ok, here it is.
 [EMAIL PROTECTED]:~/archive/knoppix$ rsync -vv
 rsync://ftp.gwdg.de/pub/linux/knoppix/KNOPPIX_V3.1-2003-01-20-EN.iso
 KNOPPIX_V3.1-2003-01-20-EN.iso
 opening tcp connection to ftp.gwdg.de port 873
 KNOPPIX_V3.1-2003-01-20-EN.iso is uptodate
 wrote 102 bytes  read 85 bytes  41.56 bytes/sec
 total size is 732921856  speedup is 3919368.21

 And the md5sum check

 [EMAIL PROTECTED]:~/archive/knoppix$ md5sum -c
 KNOPPIX_V3.1-2003-01-20-EN.iso.md5 md5sum: MD5 check failed for
 'KNOPPIX_V3.1-2003-01-20-EN.iso'

 I downloaded the md5sum again just to be sure but it still fails.

 Curious. I wonder why rsync thinks the file is up to date.

 Maybe the -I or -c options would make it look more carefully.

 The -l option (still verbose)

The -(uppercase I) option, not the -(lowercase l) option.

 [EMAIL PROTECTED]:~/archive/knoppix$ rsync -l -vv
 rsync://ftp.gwdg.de/pub/linux/knoppix/KNOPPIX_V3.1-2003-01-20-EN.iso
 KNOPPIX_V3.1-2003-01-20-EN.iso
 opening tcp connection to ftp.gwdg.de port 873
 KNOPPIX_V3.1-2003-01-20-EN.iso is uptodate
 wrote 103 bytes  read 85 bytes  28.92 bytes/sec
 total size is 732921856  speedup is 3898520.51

 The -c option
 [EMAIL PROTECTED]:~/archive/knoppix$ rsync -c -vv
 rsync://ftp.gwdg.de/pub/linux/knoppix/KNOPPIX_V3.1-2003-01-20-EN.iso
 KNOPPIX_V3.1-2003-01-20-EN.iso
 opening tcp connection to ftp.gwdg.de port 873
 rsync: connection unexpectedly closed (24 bytes read so far)
 rsync error: error in rsync protocol data stream (code 12) at
 io.c(150)

 Weird!

Very. If you try the same command again? (i.e. was it just a network
problem?)

Max.

-- 
To unsubscribe or change options: http://lists.samba.org/mailman/listinfo/rsync
Before posting, read: http://www.tuxedo.org/~esr/faqs/smart-questions.html


Re: Getting nowhere syncing a download

2003-03-06 Thread Max Bowsher
bob parker wrote:
 On Fri, 7 Mar 2003 04:10, Max Bowsher wrote:
 bob parker wrote:
 On Fri, 7 Mar 2003 03:47, Max Bowsher wrote:
 Curious. I wonder why rsync thinks the file is up to date.
 
 Maybe the -I or -c options would make it look more carefully.
 
 The -l option (still verbose)
 
 The -(uppercase I) option, not the -(lowercase l) option.
 
 The 'L' option:

No, still wrong, I, not L.

Max.

-- 
To unsubscribe or change options: http://lists.samba.org/mailman/listinfo/rsync
Before posting, read: http://www.tuxedo.org/~esr/faqs/smart-questions.html


Re: Capturing output

2003-03-04 Thread Max Bowsher
Tom Freeman wrote:
 Hi folks,
 I am running rsync via a perl script run in a cronjob.
 
 Here's the command i'm running
 
 my $message = `/usr/bin/rsync --rsh=/usr/local/openssh/bin/ssh -avu
 $directory $destination`;
 
 At the moment when I run the script it writes all output to the
 screen. I want to be able to write this data
 to a log file, so that if things don't work, I can find out what's
 wrong. 
 
 I've tried
 writeLog($message);
 but this misses out some of the stuff that rsync writes to the
 screen, i.e. the useful stuff actually, like if the file is not found
 on the machine. 
 
 Any ideas how I can achieve this? Or is this a perl type question
 rather than something I can do with rsync...?

Yes, this is a perl question, not an rsync question. 
Do perldoc perlop and search for `STRING` (including the backticks).

Max.

-- 
To unsubscribe or change options: http://lists.samba.org/mailman/listinfo/rsync
Before posting, read: http://www.tuxedo.org/~esr/faqs/smart-questions.html


Re: Copying EAs and ACLs

2003-03-02 Thread Max Bowsher
jw schultz wrote:
 Although NTFS supports ACLs the cygwin environment does not
 _yet_ reflect that.*** NTFS ACLs do not quite translate to
 and from POSIX. The semantic differences mean that
 information is lost translating each direction.

Cygwin *does* support NTFS ACLs _now_ (I think the implementation is either
POSIX or POSIX-like). The semantics issues you mention above are very real,
but if Cygwin is functioning properly, rsync doesn't need to care.

 I have a vague recollection that NTFS
 also has some form of EAs.

It does, but not used much. I tried searching the MS Platform SDK, but
couldn't find any docs on them.

 If two like systems (windows-windows for
 example) are communicating they could use their native ACL
 format instead of POSIX.

That would entail a native Windows port of rsync (or sidestepping Cygwin for
ACL handling).

Max.


-- 
To unsubscribe or change options: http://lists.samba.org/mailman/listinfo/rsync
Before posting, read: http://www.tuxedo.org/~esr/faqs/smart-questions.html


Re: Newbie Question

2003-02-27 Thread Max Bowsher
Tom Freeman wrote:
 Hi,
 I finally got rsync to work, it seems it didn't like being located in
 /usr/local/bin/rsync, so I created a symbolic link from there to
 /usr/bin/rsync and all worked fine!
 
 My next problem is that it is prompting me to enter a password each
 time I run it. I really want rsync to run automatically via a
 cronjob. Is there a way to send the password to rsync so I don't have
 to enter it manually every time?

Try reading the man page.

Or, more succinctly: RTFM.


Max.

-- 
To unsubscribe or change options: http://lists.samba.org/mailman/listinfo/rsync
Before posting, read: http://www.tuxedo.org/~esr/faqs/smart-questions.html


Re: a couple of broken links

2003-02-25 Thread Max Bowsher
Jonah Graham wrote:
 While browsing around your pages I found a couple of broken links:
 
 On:
 http://lists.samba.org/mailman/listinfo/rsync
 
 link to Read This Before Posting --
 http://www.tuxedo.org/~esr/faqs/smart-questions.html now bring you to
 a random open source software website.

s/tuxedo/catb/

Max.

-- 
To unsubscribe or change options: http://lists.samba.org/mailman/listinfo/rsync
Before posting, read: http://www.tuxedo.org/~esr/faqs/smart-questions.html


Re: Include files though directory excluded

2003-02-17 Thread Max Bowsher
Gregor Waluga wrote:
 Hi,

 I got a little question on the rsync-option include/exclude:
 I excluded all hidden files in my home-directory but I want two files
 to be included. I used following command:

 gregor@notebook:~ rsync -avzuPn -e ssh --exclude=.* --exclude=*
 --include=.kderc --include=.gaimrc /home/gregor/
 192.168.0.1:/home/gregor/ building file list ...
 1 file to consider
 wrote 69 bytes  read 20 bytes  178.00 bytes/sec
 total size is 0  speedup is 0.00
 gregor@notebook:~

 Why this transfer was not successful? The syntax is correct (I think).


 My general problem is, that I want to use an include-file, where also
 exludes are listed. Here's my file (base directory is /home/gregor/):
 - *
 - .*
 + .kde/share/apps/kabc/*
 + .kde/share/apps/kbear/*
 + .kde/share/apps/kopete/*
 + .kde/share/apps/korganizer/*
 + .kde/share/apps/quanta/*
 + .gaim/*
 + .gaimrc
 + .OpenOffice/user/config/*
 + .OpenOffice/user/wordbook/*

 What's wrong here??

You exclude everything on the first line. Rsync never looks beyond the
initial exclude, because it matches _everything_.

Max.

-- 
To unsubscribe or change options: http://lists.samba.org/mailman/listinfo/rsync
Before posting, read: http://www.tuxedo.org/~esr/faqs/smart-questions.html



Re: Include files though directory excluded

2003-02-17 Thread Max Bowsher
Gregor Waluga wrote:
 Am Dienstag, 18. Februar 2003 01:04 schrieb Max Bowsher:

 Hi,

 My general problem is, that I want to use an include-file, where
 also exludes are listed. Here's my file (base directory is
 /home/gregor/):
 - *
 - .*
 + .kde/share/apps/kabc/*
 + .kde/share/apps/kbear/*
 + .kde/share/apps/kopete/*
 + .kde/share/apps/korganizer/*
 + .kde/share/apps/quanta/*
 + .gaim/*
 + .gaimrc
 + .OpenOffice/user/config/*
 + .OpenOffice/user/wordbook/*

 What's wrong here??

 You exclude everything on the first line. Rsync never looks beyond
 the initial exclude, because it matches _everything_.

 OK, my file looks now as follows:

 + .kde/share/apps/kabc/
 + .kde/share/apps/kbear/
 + .kde/share/apps/kopete/
 + .kde/share/apps/korganizer/
 + .kde/share/apps/quanta/
 + .gaim/
 + .gaimrc
 + .OpenOffice/user/config/
 + .OpenOffice/user/wordbook/
 - *
 - .*

 My console output is:
 building file list ...
 3 files to consider
 .gaimrc
 wrote 356 bytes  read 24 bytes  760.00 bytes/sec
 total size is 1949  speedup is 5.13

 Why was only this one file transferred? I want the other directories
 to be synchronized, too. I do know that e.g. the OpenOffice wordbook
 isn't synchronized yet!
 The tree on both machines is equal (base directory is /home/gregor/).

Well, now you are including the directories, but you aren't including the
files within them!

Max.

-- 
To unsubscribe or change options: http://lists.samba.org/mailman/listinfo/rsync
Before posting, read: http://www.tuxedo.org/~esr/faqs/smart-questions.html



Re: Include files though directory excluded

2003-02-17 Thread Max Bowsher
Gregor Waluga wrote:
 + .kde/share/apps/kabc/
 + .kde/share/apps/kbear/
 + .kde/share/apps/kopete/
 + .kde/share/apps/korganizer/
 + .kde/share/apps/quanta/
 + .gaim/
 + .gaimrc
 + .OpenOffice/user/config/
 + .OpenOffice/user/wordbook/
 - *
 - .*

+ .kde/share/apps/kabc/
+ .kde/share/apps/kabc/**
+ .kde/share/apps/kbear/
+ .kde/share/apps/kbear/**
+ .kde/share/apps/kopete/
+ .kde/share/apps/kopete/**
+ .kde/share/apps/korganizer/
+ .kde/share/apps/korganizer/**
+ .kde/share/apps/quanta/
+ .kde/share/apps/quanta/**
+ .gaim/
+ .gaim/**
+ .gaimrc
+ .OpenOffice/user/config/
+ .OpenOffice/user/config/**
+ .OpenOffice/user/wordbook/
+ .OpenOffice/user/wordbook/**
- *

NB: * will match dotfiles. No need for .* as well.

Max.

-- 
To unsubscribe or change options: http://lists.samba.org/mailman/listinfo/rsync
Before posting, read: http://www.tuxedo.org/~esr/faqs/smart-questions.html



Re: The FAQ / etiquette page didn't work?

2003-02-15 Thread Max Bowsher
S P Arif Sahari Wibowo wrote:
 Hi!
 
 I just subscribed to this list. Hello!
 
 When I tried many times to read the FAQ / etiquette page at
 http://www.tuxedo.org/~esr/faqs/smart-questions.html
 (or actually any address in www.tuxedo.org)
 I always get forwarded to other sites. What happen to tuxedo.org?
 
 Anyway, if this is not temporary, probably better to change the FAQ /
 etiquette page link to other place.

s/tuxedo/catb/


Max.

-- 
To unsubscribe or change options: http://lists.samba.org/mailman/listinfo/rsync
Before posting, read: http://www.tuxedo.org/~esr/faqs/smart-questions.html



Re: --delete for old file only?

2003-02-15 Thread Max Bowsher
S P Arif Sahari Wibowo wrote:
 Hi!
 
 Do you know any trick (scripts, combining rsync with other tools,
 etc.) to let rsync only delete the files with modification time
 before (older than) a certain date-time (can use the time of a file
 as a reference time)? 
 
 It probably more difficult when we rsync out (for rsync in, the we can
 actually find out right away which files in that criteria using small
 Find::File perl script).
 
 The idea is for a pair of sites that rsync each other (and use the
 --delete option). The old file only delete mechanism will reduce the
 possibily of a new file just added accidentally removed by the next
 rsync with --delete.
 
 Maybe something to add to rsync itself? :-)

Sounds like unison would be more suitable than rsync here.


Max.

-- 
To unsubscribe or change options: http://lists.samba.org/mailman/listinfo/rsync
Before posting, read: http://www.tuxedo.org/~esr/faqs/smart-questions.html



Re: Newbie syntax question on --include-from option

2003-02-13 Thread Max Bowsher
Loris Serena wrote:
 rsync -azv -e ssh --stats --include-from=rsynclist.txt host-one:

You've only got a source here, no destination.

 and rsynclist.txt looks like

 + /export/home/user1/dir1/dir2/dir3/
 + /export/home/user1/dir2/dir3/dir4/
 + /export/home/user1/dir3/dir4/dir5/
 + /export/home/user1/dir4/dir5/dir6/
 + /export/home/user1/dir5/dir6/dir7/

Remember that the default is to include. If you have no excludes, then
everything will be included anyway.

 Basically what  I am looking to achieve is NOT to specify a directory
 after the semicolon after host-one,

This...

 because I want to sync files from the
 source box
 EXACTLY to the same directory on the target box.

... won't do this. No directory = home directory, not root directory.


Max.

-- 
To unsubscribe or change options: http://lists.samba.org/mailman/listinfo/rsync
Before posting, read: http://www.tuxedo.org/~esr/faqs/smart-questions.html



Re: /me dead for a short while [Was: rsync in cygwin as service]

2003-02-12 Thread Max Bowsher
Dmitry Melekhov wrote:
 Well, now I know that _latest_ rsync does not work in daemon mode at
 all,

Works for me.

 i.e. when I start it with --daemon it simply exits without any
 error messages.
 But could you tell me is there rsync version which I can use in cygwin
 right now?

Yep. The current version on the Cygwin mirrors. Works just fine.


Max.


-- 
To unsubscribe or change options: http://lists.samba.org/mailman/listinfo/rsync
Before posting, read: http://www.tuxedo.org/~esr/faqs/smart-questions.html



Re: Connecting two rsync clients

2003-02-10 Thread Max Bowsher
George Hazlewood wrote:
 /usr/local/bin/rsync -vcrlnptgoxRz --delete -e ssh \
 --include-from=/usr/local/rsync/include.conf \
 --exclude-from=/usr/local/rsync/exclude.conf --stats --progress \

You can combine includes and excludes into one file:

+ /include/this
- /exclude/that

and reference the file with either --include-from or --exclude-from (which
just determines the default for lines which don't begin '- ' or '+ ').



Max.

-- 
To unsubscribe or change options: http://lists.samba.org/mailman/listinfo/rsync
Before posting, read: http://www.tuxedo.org/~esr/faqs/smart-questions.html



Re: Problem with rsync from one machine

2003-02-06 Thread Max Bowsher
Tom Walsh wrote:
 rsync --verbose --progress --stats --compress --rsh=/usr/bin/slogin
 -l root -o Compression=yes --recursive --times --links --perms
 --owner --group machineA.com:/etc /backup/machineA.com/etc
 
 The following occurs:
 
 All directories on Machine A /etc are replicated on Machine C
 /backup.../etc, however when the process starts to transfer files from
 Machine A, I get:
 
 receiving file list ...
 650 files to consider
 etc/
 etc/.pwd.lock
   3080 0%   8.82MB/s 538:49:00
 
 Looks pretty normal, except the fact that /etc/.pwd.lock is a 0 size
 file... So I am not sure where it is getting all that data from.

Can you tell us anything about what exactly /etc/.pwd.lock is?
Does ls -l /etc/.pwd.lock show anything different to a file which syncs ok?


Max.

-- 
To unsubscribe or change options: http://lists.samba.org/mailman/listinfo/rsync
Before posting, read: http://www.tuxedo.org/~esr/faqs/smart-questions.html



Re: Problem with rsync from one machine

2003-02-06 Thread Max Bowsher
Tom Walsh wrote:
 [root@magic /etc]# ls -la .pwd.lock
 -rw---1 root root0 Nov 29  2001 .pwd.lock
 
 Nothing special about that file... and like I said it occurs in any
 directory.
 
 If I do machineA.com:/etc/* (excluding files that start with .) it
 will hang on DIR_COLORS.
 
 It basically when ever it starts to transfer the files... Very odd
 behavior... I have a tough time trying to describe it even, so I
 can't even look online for a similar problem.

Ouch. Clutching at straws, but maybe - would reveal something?

Max.

-- 
To unsubscribe or change options: http://lists.samba.org/mailman/listinfo/rsync
Before posting, read: http://www.tuxedo.org/~esr/faqs/smart-questions.html



Re: rsync - what can it do?

2003-02-05 Thread Max Bowsher
bob parker wrote:
 Actually in this instance there is no hierarchy, it is just one flat
 700 meg iso. So my question is can rsync sort out out which parts of
 it have errors and just download the corrupted parts of it?

Yes.

Transferring a file, whilst making use of bits of it that are already
present on both sides is rsync's primary purpose.



Max.

-- 
To unsubscribe or change options: http://lists.samba.org/mailman/listinfo/rsync
Before posting, read: http://www.tuxedo.org/~esr/faqs/smart-questions.html



Re: Trouble with include/exclude patterns

2003-02-05 Thread Max Bowsher
Anand Buddhdev wrote:
 I'm using rsync 2.5.4 on my RedHat 7.3 client laptop and rsync 2.5.5
 on my RedHat 8.0 server. On the client, I have a directory rpm with
 5 subdirectories, out of which I only want to copy the one called
 SRPMS 
 across. I also have another directory .mozilla out of which I want
 to 
 copy across 2 files. I have constructed the following rsync
 invocation: 
 
 rsync -e ssh -av --delete \
 --exclude='/rpm/BUILD' --exclude='/rpm/SOURCES'
 --exclude='/rpm/SPECS' --exclude='/rpm/RPMS' \ 
 --include='.mozilla/arb/kfgj0v2y.slt/bookmarks.html' \
 --include='.mozilla/arb/kfgj0v2y.slt/prefs.js' \
 --exclude='.mozilla' \
 .mozilla \
 rpm \
 $SERVER:laptop-backup
 
 Now, this works correct for the rpm directory, by only copying
 rpm/SRPMS, and leaving out rpm/BUILD, rpm/SOURCES, /rpm/SPECS and
 rpm/RPMS.
 
 However, it does not copy my bookmarks.html and prefs.js files. If I
 add one more -v to the rsync command, I see this:
 
 excluding directory .mozilla because of pattern .mozilla
 
 So it seems the entire .mozilla directory is skipped, despite my 2
 --include statements.
 
 I have read the man page over and over, and I can't see what's wrong.

--include .mozilla
--include .mozilla/arb/
--exclude .mozilla/arb/*
--include .mozilla/arb/kfgj0v2y.slt/
--include .mozilla/arb/kfgj0v2y.slt/bookmarks.html
--include .mozilla/arb/kfgj0v2y.slt/prefs.js
--exclude .mozilla/arb/kfgj0v2y.slt/*

Yes, its messy.

I don't think there is a better way.

 Any idea what I'm doing wrong? And any ideas on reducing those 4
 --excludes to one --exclude and one --include for the rpm directory?

would:

--include /rpm/SRPMS
--exclude /rpm/*

do what you want?


Max.

-- 
To unsubscribe or change options: http://lists.samba.org/mailman/listinfo/rsync
Before posting, read: http://www.tuxedo.org/~esr/faqs/smart-questions.html



Re: Trouble with include/exclude patterns

2003-02-05 Thread Max Bowsher
Wayne Davison wrote:
 On Thu, Feb 06, 2003 at 01:17:34AM -, Max Bowsher wrote:
 --include .mozilla
 --include .mozilla/arb/
 --exclude .mozilla/arb/*
 --include .mozilla/arb/kfgj0v2y.slt/
 --include .mozilla/arb/kfgj0v2y.slt/bookmarks.html
 --include .mozilla/arb/kfgj0v2y.slt/prefs.js
 --exclude .mozilla/arb/kfgj0v2y.slt/*
 
 Close, but not quite.  The order of a couple lines is reversed and

Duh. Thanks for picking up on that.

 that might copy more than one file from the .mozilla/arb dir.

It would copy nothing from arb, surely?

 I'd also suggest putting the lines into an include file so that the
 command-line only needs an --include-from=file_name directive.  The
 lines would get +/- prefixes to tell it what to include/exclude:

I don't think .mozilla was in rpm:

+ /rpm/SRPMS/
- /rpm/*
+ /.mozilla/
+ /.mozilla/arb/
- /.mozilla/*
+ /.mozilla/arb/kfgj0v2y.slt/
- /.mozilla/arb/*
+ /.mozilla/arb/kfgj0v2y.slt/bookmarks.html
+ /.mozilla/arb/kfgj0v2y.slt/prefs.js
- /.mozilla/arb/kfgj0v2y.slt/*


Max.

-- 
To unsubscribe or change options: http://lists.samba.org/mailman/listinfo/rsync
Before posting, read: http://www.tuxedo.org/~esr/faqs/smart-questions.html



Re: rsync for ftp mirror

2003-01-31 Thread Max Bowsher
Alessandro Riz wrote:
 Hi,
 I've a little problem:
 I don't know if I can use rsync for doing an automatic mirror which
 use ftp protocol?
 I hope that shoul be possible but what?

Rsync uses the rsync protocol. If you have to mirror via ftp, then there are
programs out there, but rsync does not do that.

Max.

-- 
To unsubscribe or change options: http://lists.samba.org/mailman/listinfo/rsync
Before posting, read: http://www.tuxedo.org/~esr/faqs/smart-questions.html



Re: Cygwin issues: modify-window and hangs

2003-01-31 Thread Max Bowsher
jw schultz wrote:
 I'd rather we default modify-window to 1 for windows.

But windows != FAT. Even a Linux system *could* be using FAT. What's wrong
with the current state of affairs?
It's not like the mailing list (rsync or cygwin) is flooded with messages
complaining about this.

Max.

-- 
To unsubscribe or change options: http://lists.samba.org/mailman/listinfo/rsync
Before posting, read: http://www.tuxedo.org/~esr/faqs/smart-questions.html



Re: Cygwin issues: modify-window and hangs

2003-01-31 Thread Max Bowsher
jw schultz wrote:
 On Fri, Jan 31, 2003 at 02:44:58PM -, Max Bowsher wrote:
 jw schultz wrote:
 I'd rather we default modify-window to 1 for windows.
 
 But windows != FAT. Even a Linux system *could* be using FAT. What's
 wrong with the current state of affairs?
 It's not like the mailing list (rsync or cygwin) is flooded with
 messages complaining about this.
 
 Sorry, i wasn't quite clear.  Also i misremembered cygwin
 having a default modify-window = 2 in 2.5.5 (thanks _WIN32).
 To be clear, here are my preferences in decending order (#1
 being most prefered).
 
 1. modify-window = 0 on all platforms

I agree.

Max.

-- 
To unsubscribe or change options: http://lists.samba.org/mailman/listinfo/rsync
Before posting, read: http://www.tuxedo.org/~esr/faqs/smart-questions.html



Rsync on Cygwin testsuite results

2003-01-28 Thread Max Bowsher
I hacked config.h to undefine HAVE_SOCKETPAIR. Cygwin's socketpair was
failing randomly, causing errors on roughly a third of testsuite runs.
Having made that alteration (so rsync was using pipe, not socketpair), I ran
the testsuite 100 times. SSH tests were not enabled.

Out of 100 runs, 4 hung on the daemon test. The remaining 96 passed or
skipped all tests.


So - one lurking hang, one problem (with socketpair) with an easy
workaround.

Not too bad really, if I can make any further headway in tracing that hang.

Max.

-- 
To unsubscribe or change options: http://lists.samba.org/mailman/listinfo/rsync
Before posting, read: http://www.tuxedo.org/~esr/faqs/smart-questions.html



Re: Incremental transfers: how to tell?

2003-01-28 Thread Max Bowsher
James Kilton wrote:
 To follow up on this... I found the --stats option and
 here's what I'm getting:

 Number of files: 36
 Number of files transferred: 36
 Total file size: 10200816 bytes
 Total transferred file size: 10200816 bytes
 Literal data: 10200816 bytes
 Matched data: 0 bytes
 File list size: 576
 Total bytes written: 10203996
 Total bytes read: 596

 So, I don't know why no parts of the files are
 matching.  The files are the same save for 1 or 2
 values changing every 5 minutes.  I don't know if
 anyone here is familiar with RRD files, but they're
 database files commonly used for SNMP data collection.
  All the fields are created initially so the file size
 never changes -- the fields are populated as time goes
 on.

 Is RSync unable to do incremental transfers of
 non-text files?

No, it is perfectlty capable of this.

Is is possible that your files are changing in widely scattered places, such
that every block that rsync examines has changed?


Max.

-- 
To unsubscribe or change options: http://lists.samba.org/mailman/listinfo/rsync
Before posting, read: http://www.tuxedo.org/~esr/faqs/smart-questions.html



Re: Cygwin issues: modify-window and hangs

2003-01-27 Thread Max Bowsher
Dave Dykstra wrote:
 On Sat, Jan 25, 2003 at 06:32:08PM +0100, Greger Cronquist wrote:
  --- Max Bowsher [EMAIL PROTECTED] skrev:  Dave Dykstra
 wrote:

 I'm using the current Cygwin release
 (rsync-2.5.5-2). That is rsync-2.5.5,
 with an added msleep(30) which is intended to deal
 with a possible problem
 with signals in Cygwin.

 Making that msleep(100) works even better for me.

 Ah, I found the messages that were discussing this and I see this was
 supposed to prevent hangs at the ends of runs.  I went ahead and put
 an msleep(100) in before the final kill...USR2 in main.c do_recv().

Note that this is something of a kludge, which hasn't fixed the problem in
all cases. I'd say there is an argument for leaving this in the Cygwin
patches, out of the upstream source, until a better solution can be found,
or Cygwin changed to avoid this. However, don't hold 2.5.6 up to discuss
this, and we should probably wait for Lapo Luchini's opinion on this.

Max.

-- 
To unsubscribe or change options: http://lists.samba.org/mailman/listinfo/rsync
Before posting, read: http://www.tuxedo.org/~esr/faqs/smart-questions.html



Re: Securing Rsync

2003-01-27 Thread Max Bowsher
Mike Winfrey wrote:
 I have a rsync server set up on a win2k server and a win xp pro
 computer is my client. It's working very well doing the anonymous
 transfers. However, I've tried setting up a password file and not
 having any success.
 
 rsync.secrets on my rsync server
 user:password
 
 I run the following command string on my client computer:
 C:\rsync\rsync.exe -av --delete --password-file=/rsync/rsync.secrets
 /cygdrive/C/Documents and Settings/All Users 
 user@server::serverbu/ 
 
 the password file on my XP machine looks just like the one on the
 server.

There is your problem, then. From the manpage:

--password-file
   (The file) should contain just the password as a single line.

 I tried set rsync_password=password as well but that doesn't work
 either.

rsync_password != RSYNC_PASSWORD


Max.

-- 
To unsubscribe or change options: http://lists.samba.org/mailman/listinfo/rsync
Before posting, read: http://www.tuxedo.org/~esr/faqs/smart-questions.html



Re: Securing Rsync

2003-01-27 Thread Max Bowsher
[EMAIL PROTECTED] wrote:
 It's my understanding that passwords don't work in a cygwinned rsync.

I see no reason why that should be the case.

Max.

-- 
To unsubscribe or change options: http://lists.samba.org/mailman/listinfo/rsync
Before posting, read: http://www.tuxedo.org/~esr/faqs/smart-questions.html



Links in Resources relating to use on Windows are extremely out-of-date - could be misleading.

2003-01-27 Thread Max Bowsher
I suggest either removing the two Using rsync on Windows 9x/NT documents,
or placing a prominent warning on them that they are no longer current.


Max.


-- 
To unsubscribe or change options: http://lists.samba.org/mailman/listinfo/rsync
Before posting, read: http://www.tuxedo.org/~esr/faqs/smart-questions.html



Re: Cygwin issues: modify-window and hangs

2003-01-27 Thread Max Bowsher
Dave Dykstra wrote:
 This modify-window default of 1 has been causing some trouble on the
 rsync test suite on the Cygwin test machine on build.samba.org.  The
 problem is that some files get created and immediately copied within
 one second, and then the rsync code that implements '-p' checks to
 see if the copied file's time is within one second before deciding
 whether or not to change it. The test machine is presumably using an
 NTFS filesystem so it has one second granuarlity.

Yes, noticed this running make check last night. However, I also got
random (i.e. re-run the testsuite and get different results) failures of
some other tests. Is this showing up in your test machine?

 Last night I considered 4 possible solutions:
 1. Change the test suite to always wait 2 seconds before copying,
 at
 the beginning of the checkit function.
 2. Change the test suite to always pass --modify-window=0 to
 rsync by including it in the $RSYNC variable in testsuite/rsync.fns.
 3. Change the set_perms() function in rsync.c to check for exact
 time rather than calling cmp_modtime.
 4. Back out the default of --modify-window=1 on cygwin and go
 back to
 a default of 0.

 I implemented solution 1, but I'm not very comfortable with it because
 it slows the tests on all platforms. I'm now leaning toward solution
 3. Discussion?

How about 4? It seems wrong to penalize NTFS for a FAT problem, especially
as NTFS is now the preferred Windows filesystem.

Unless someone feels like making a FAT-detection patch, the previous status
quo looks to me like the best option.


Max.

-- 
To unsubscribe or change options: http://lists.samba.org/mailman/listinfo/rsync
Before posting, read: http://www.tuxedo.org/~esr/faqs/smart-questions.html



Re: [PATCH] open O_TEXT and O_BINARY for cygwin/windows

2003-01-27 Thread Max Bowsher
Dave Dykstra wrote:
 On Mon, Jan 27, 2003 at 10:46:16AM +0100, Lapo Luchini wrote:
 I can test that before releasing cygwin's 2.5.6-1 package,
 unfortunately I have almost *no* free time until after friday
 (university test on thursday ^_^)
 Anyway Max is also right, local issues can be resolved locally with
 much speed, even if in the long run it's of course better to put
 them in rsync cvs too.

 I'm reluctant to rely on cygwin-stream-specific patches because I know
 that other people compile it from source too.  Probably the msleep
 should be put in for Cygwin only with an ifdef though, or the waiting
 of the child removed altogether on Cygwin only.

Does it not make sense that anyone wishing to compile their own rsync for
Cygwin should start by looking at the Cygwin package? (Which, btw, includes
the clean rsync source, and patchfiles, so it is easy to see what is being
done to rsync specially for Cygwin).

The waiting for the child is presumably there for a reason. If is removed
for Cygwin, it should probably be removed for all platforms. If there is an
argument against that, then it applies equally to Cygwin as to any other
platforms.

 BTW: I wonder if the sleepms(30) is still needed, it's quite a bit of
 time that my build.samba.org hourly cron doesn't produce a hanged
 rsync... (must check that too)

 I know that some people still experience it, and I don't think
 anything has changed in that area since the time that the
 person who experienced the hang discovered the hack.

Cygwin has gone through many minor versions since then. I suggest releasing
an rsync without the hack, but with a command line option to turn it on.
That way, we get to see for certain whether the problem still exists, and
there is an easy workaround available if it does.


Max.

-- 
To unsubscribe or change options: http://lists.samba.org/mailman/listinfo/rsync
Before posting, read: http://www.tuxedo.org/~esr/faqs/smart-questions.html



Re: [PATCH] open O_TEXT and O_BINARY for cygwin/windows

2003-01-26 Thread Max Bowsher
Dave Dykstra wrote:
 Alright.  Max, could you quickly verify if the latest CVS version
 works OK for you on Cygwin?

What, in particular? I'm not a very good testcase, because I use binary
mounts and unix line endings everywhere.

It compiles and does syncs with remote rsync daemons, which is my normal
usage.

Max.




 It's better to always handle all three styles of line terminations
 anyway, because there are other situations than systems that have
 O_TEXT defined where it might be wanted, for example a Linux system
 that has a Windows filesystem mounted.

 - Dave

 On Sun, Jan 26, 2003 at 12:07:07PM -0800, Wayne Davison wrote:
 On Sun, Jan 26, 2003 at 08:16:50AM -0800, jw schultz wrote:
 authenticate.c: fd = open(fname,O_RDONLY | O_TEXT);
 get_secret() already discards \r

 authenticate.c: if ( (fd=open(filename,O_RDONLY | O_TEXT)) == -1) {
 getpassf() treats \r the same as \n

 Yeah, these already handle both Mac and PC line endings, so I removed
 the O_TEXT bit from these.

 clientserver.c: FILE *f = fopen(motd,r O_TEXT_STR);
 simply passes contents of motd file unchanged to client
 does it matter if there are \r chars in the file?

 I'm trying to imagine what will happen for Mac systems as well.
 Since the default for files is to open them in text mode on a Mac
 (and they don't have the Cygwin weirdness of trying to override a
 binary-mode mount, right?), then I think you're right here -- the
 extra \r that might come from a PC system should hopefully cause no
 problems (but we should test this).  In the meantime, I think it
 would be safe to revert this change.

 exclude.c:  f = fopen(fname,r O_TEXT_STR);
 exclude.c:  f = fdopen(0, r O_TEXT_STR);
 the file is processed with
 while (fgets(line,MAXPATHLEN,f)) {
 int l = strlen(line);
 if (l  line[l-1] == '\n') l--;
 line[l] = 0;
 if we add
 if (l  line[l-1] == '\r') l--;
 after the \n processing that will handle the \r\n case
 or we can replace the \n line with
 while (l  (line[l-1] == '\n'|| line[l-1] == '\r')) l--;
 and this function will be covered.

 As long as Mac systems are reading the file in text mode without the
 O_TEXT_STR, we should be fine (and I believe that to be the case).

 params.c:  OpenedFile = fopen( FileName, r O_TEXT_STR );
 since \r is a whitespace character it should be
 ignored.

 Sounds right (though I haven't verified your analysis).

 Since it sounds like the t has a potential for problems, I'm taking
 these recent changes out and will just put in the one suggested
 change to ignore a '\r' at the end of the line.  This should be
 safer for the current release.

 ...wayne..

-- 
To unsubscribe or change options: http://lists.samba.org/mailman/listinfo/rsync
Before posting, read: http://www.tuxedo.org/~esr/faqs/smart-questions.html



Re: [PATCH] open O_TEXT and O_BINARY for cygwin/windows

2003-01-26 Thread Max Bowsher
Dave Dykstra wrote:
 On Sun, Jan 26, 2003 at 08:54:19PM -, Max Bowsher wrote:
 Dave Dykstra wrote:
 Alright.  Max, could you quickly verify if the latest CVS version
 works OK for you on Cygwin?

 What, in particular? I'm not a very good testcase, because I use
 binary mounts and unix line endings everywhere.

 It compiles and does syncs with remote rsync daemons, which is my
 normal usage.

 Max.


 See if exclude files with DOS line endings work ok for you, and also
 the other config files if you can.


Sorry, I don't have time to fiddle around to that extent right now.

If you need to get 2.5.6 out the door, then do. If the Cygwin 2.5.6-1
doesn't work quite right, there can always be a 2.5.6-2.


Max.

-- 
To unsubscribe or change options: http://lists.samba.org/mailman/listinfo/rsync
Before posting, read: http://www.tuxedo.org/~esr/faqs/smart-questions.html



Re: Cygwin issues: modify-window and hangs

2003-01-25 Thread Max Bowsher
Dave Dykstra wrote:
 On Sat, Jan 25, 2003 at 12:10:39AM -, Max Bowsher wrote:
 Dave Dykstra wrote:
 While doing the tests we too experienced hangs at the end of copies.
 We were going over openssh from a Solaris 9 box to Windows 2000
 Cygwin.
 We tried the test from
 http://lists.samba.org/pipermail/rsync/2002-August/008130.html
 but it still experienced hangs.  It wasn't clear if the patch
 reduced
 the frequency or not.

 Data point: I regularly rsync from sources.redhat.com (Linux, I
 presume. Not Cygwin, anyway) to my local machine (Cygwin). I have
 never experienced a hang.

 Since you posted the above message, does that mean you used to
 experience hangs and that the rsyncs you do now are with the patch in?

No, all I did was translate a description of what to change into an actual
.patch file.

I have experienced connection reset by peer issues on Cygwin, but only on
file listing, never on actual transfers.

I'm using the current Cygwin release (rsync-2.5.5-2). That is rsync-2.5.5,
with an added msleep(30) which is intended to deal with a possible problem
with signals in Cygwin.

 Has *anybody* been able to figure out a fix for this that really
 works?
 It sure would be nice to get something into 2.5.6 but we're about
 out
 of time for that because I need to put it out this weekend before I
 start a new (temporary) job on Monday.  I imagine that the issue I
 was experiencing could be a separate one and this patch really would
 help other hangs people are having; can anybody give me an argument
 for putting in the calls to shutdown() anyway?  I would make it
 only happen on Cygwin, because it is unknown if they will cause harm
 on other platforms.

 Those platforms would have to be fairly broken. The behaviour of
 shutdown is pretty clearly defined.

 It is a relatively rarely used function, however, so it probably
 doesn't get much testing.  Cygwin/windows is what's really broken and
 I'd rather not risk all the other ports to suit it.

Understandable.

Anyway, since rsync on Cygwin is currently behaving perfectly for me, I
don't really have much to say in this discussion.

Max.

-- 
To unsubscribe or change options: http://lists.samba.org/mailman/listinfo/rsync
Before posting, read: http://www.tuxedo.org/~esr/faqs/smart-questions.html



Re: [PATCH] open O_TEXT and O_BINARY for cygwin/windows

2003-01-24 Thread Max Bowsher
Ville Herva wrote:
 On Thu, Jan 23, 2003 at 01:55:40PM -0600, you [Dave Dykstra] wrote:
 Why did you skip the fopen in log.c, which appends to the log file?

 I thought about that for a while. My reasoning was that the log file
 is probably read with unix/cygwin tools anyway - if not, the
 administrator is free to mount the filesystem binary or ascii. So I
 didn't want to enforce CR/LF on anyone.

Yes, please don't write in explicit text mode. Keeping the flexibility here
is good.


Max.

-- 
To unsubscribe or change options: http://lists.samba.org/mailman/listinfo/rsync
Before posting, read: http://www.tuxedo.org/~esr/faqs/smart-questions.html



Re: rsync 2.5.5

2003-01-24 Thread Max Bowsher
Patrick Amirian wrote:
 Hi,
 Can anyone tell me please where I can get the latest version of rsync
 for AIX ?

Download source and compile it?


Max.

-- 
To unsubscribe or change options: http://lists.samba.org/mailman/listinfo/rsync
Before posting, read: http://www.tuxedo.org/~esr/faqs/smart-questions.html



Re: Cygwin issues: modify-window and hangs

2003-01-24 Thread Max Bowsher
Dave Dykstra wrote:
 While doing the tests we too experienced hangs at the end of copies.
 We were going over openssh from a Solaris 9 box to Windows 2000
 Cygwin.
 We tried the test from
 http://lists.samba.org/pipermail/rsync/2002-August/008130.html
 but it still experienced hangs.  It wasn't clear if the patch reduced
 the frequency or not.

Data point: I regularly rsync from sources.redhat.com (Linux, I presume. Not
Cygwin, anyway) to my local machine (Cygwin). I have never experienced a
hang.

 Has *anybody* been able to figure out a fix for this that really
 works?
 It sure would be nice to get something into 2.5.6 but we're about out
 of time for that because I need to put it out this weekend before I
 start a new (temporary) job on Monday.  I imagine that the issue I
 was experiencing could be a separate one and this patch really would
 help other hangs people are having; can anybody give me an argument
 for putting in the calls to shutdown() anyway?  I would make it
 only happen on Cygwin, because it is unknown if they will cause harm
 on other platforms.

Those platforms would have to be fairly broken. The behaviour of shutdown is
pretty clearly defined.


Max.

-- 
To unsubscribe or change options: http://lists.samba.org/mailman/listinfo/rsync
Before posting, read: http://www.tuxedo.org/~esr/faqs/smart-questions.html



Re: Please test rsync-2.5.6pre2

2003-01-21 Thread Max Bowsher
Dave Dykstra wrote:
 Changes since 2.5.5pre1:

   ENHANCEMENTS:

 * Set the default value of --modify-window to 2 on Cygwin.  (Max
 Bowsher)

No, not me. I only got involved to suggest an alternative to the deprecated
AC_CYGWIN autoconf macro.
I am, in fact, undecided on whether the --modify-window change is a good
idea or not.


Max.

-- 
To unsubscribe or change options: http://lists.samba.org/mailman/listinfo/rsync
Before posting, read: http://www.tuxedo.org/~esr/faqs/smart-questions.html



Re: Finished storage compression patch for rsync

2003-01-19 Thread Max Bowsher
Harald Fielker wrote:
 Am Samstag, 18. Januar 2003 22:54 schrieb Max Bowsher:
 Green, Paul wrote:
 You might consider using zlib instead of gzip; same algorithm, same
 author, but you can access the compression code via a subroutine
 
 Do you have an idea how i can use it for compressing a whole file?
 
 Is there a de/compress (char *file) function?
 
 interface. You would not have to spawn another process to run gzip,
 and you would not be dependent upon the user having gzip installed.
 
 You are right - an internal compression to rsync would be nice. But i
 would also suggest having a userdefinable option for the compressing
 program. I prefer lzo (http://www.oberhumer.com/opensource/lzo/). The
 compressor depends on the files you are using, e.g. bzip2 is good for
 small textfiles - lzo is fast and can be used for large database
 files where there are changes every 3-4 days.
 
 Well, I presume it is, since it's what rsync uses to implement
 in-transfer compression (-z option).
 
 Which means you shouldn't even need to deal with adding it to the
 rsync build system.
 
 Just tell me the function i have to call ;)

I believe gzopen/gzread/gzwrite/gzclose would be the easiest to use.

Max.

-- 
To unsubscribe or change options: http://lists.samba.org/mailman/listinfo/rsync
Before posting, read: http://www.tuxedo.org/~esr/faqs/smart-questions.html



Re: Windows and default --modify-window=0

2003-01-10 Thread Max Bowsher
Dave Dykstra wrote:
 Ok, I agree --modify-window should default to 2 (or 1 if that's all
 that's really needed) on cygwin.  However, I don't like os-specific
 defines.

They have the advantage that the entire logic is visible in the .c file,
rather than split between the .c and configure.in.

 That _WIN32 we've got there is the only one currently in the code, and
 there's no occurrances of __CYGWIN__.   I'd rather have a configure.in
 rule for it.  Any suggestions on a good one?  At a minimum there's an
 AC_CYGWIN macro but that's not much different than just checking for
 __CYGWIN__.  Probably it would be worth calling AC_CYGWIN and then
 setting
 a DEFAULT_MODIFY_WINDOW to 2 in configure if $CYGWIN=yes.

AC_CYGWIN is obsolete - the autoconf manual recommends something like this:
AC_CANONICAL_HOST  # at some point above
case $host_os in
  *cygwin* ) DEFAULT_MODIFY_WINDOW=2;;
 * ) DEFAULT_MODIFY_WINDOW=0;;
esac
AC_SUBST(DEFAULT_MODIFY_WINDOW)
 As far as I
 know there is no other port of rsync to Windows yet except under
 Cygwin
 so I don't think it is worth putting in extra code to support
 something
 that may never be used.  Or, perhaps we should key off of the $EXEEXT
 variable which gets set to '.exe' on Windows; anybody have an opinion
 on
 that?

Yuk! :-)



Max.

-- 
To unsubscribe or change options: http://lists.samba.org/mailman/listinfo/rsync
Before posting, read: http://www.tuxedo.org/~esr/faqs/smart-questions.html



Re: exclude pattern

2003-01-09 Thread Max Bowsher
-- wrote:
 Yes, I know that's a newbie question.
 
 I want to rsync a tree SERVER1:/src/repository to
 SERVER2:/otherlocation/repository
 with one rsync command.
 
 Under repository are the directories
 foo and
 foo/bar/foo
 
 
 Now I want to rsync foo/bar/foo but not foo.
 I want to use the --exclude-from switch (to be able to specify more
 exclude patterns).
 
 Could you please tell me, what the command and pattern has to look
 like? 

+ /foo/bar/
- /foo/*
+ /foo/bar/foo/
- /foo/bar/*


Max.

-- 
To unsubscribe or change options: http://lists.samba.org/mailman/listinfo/rsync
Before posting, read: http://www.tuxedo.org/~esr/faqs/smart-questions.html



Re: Proper --exclude= syntax?

2003-01-08 Thread Max Bowsher

- Original Message -
From: Dan Kressin [EMAIL PROTECTED]
To: [EMAIL PROTECTED]
Sent: Wednesday, January 08, 2003 10:15 PM
Subject: Proper --exclude= syntax?


 I'm currently syncing the home directories on two boxes with the syntax:

 dest-host# rsync -av -e ssh --delete --progress source-host:/home/
/home/

 That's working well.  Now I want to exclude /home/httpd/* from the
process.
 (I don't want web changes on one box to affect the other box.)  Which of
the
 following is the best/correct one to use?

 1) --exclude=/home/httpd/*
 2) --exclude=/home/httpd/
 3) --exclude=/home/httpd

Won't work with command above. They refer to /home/home/httpd.

 4) --exclude=httpd/*

Would sync perms on httpd, but not contents, also, would apply to all dirs
called httpd anywhere in /home/.

 5) --exclude=httpd/

Would exclude all dirs called httpd anywhere in /home/.

 6) --exclude=httpd

Would exclude all dirs or files called httpd anywhere in /home/.

I would use --exclude=/httpd/

Max.

-- 
To unsubscribe or change options: http://lists.samba.org/mailman/listinfo/rsync
Before posting, read: http://www.tuxedo.org/~esr/faqs/smart-questions.html



Re: IPv6 hosts allow|deny

2003-01-05 Thread Max Bowsher
Bert Vermeulen wrote:
 Hi all,

 Does anyone know what the status is of Hideaki Yoshifuji's IPv6 ACL
 patch? He's submitted this twice now, and that was 3 months ago.
 Judging by the comments made when this was submitted, it's apparently
 not understood how important this is.

 - if you IPv6 on your rsync server, you can not secure it with hosts
   allow.

 - if you enable IPv6 on an rsync server that's secured with hosts
   deny to keep certain hosts out, well, they can get in again -- if
   they also have IPv6.

 Please, can this patch be merged into the next release? This is very
 important! It is NOT new functionality, it's a security fix.

I think the problem is that wget currently has *no active maintainers*.

Based on a recent thread, there is no-one with CVS commit priviledges who
reads this list.

Max.

-- 
To unsubscribe or change options: http://lists.samba.org/mailman/listinfo/rsync
Before posting, read: http://www.tuxedo.org/~esr/faqs/smart-questions.html



Re: IPv6 hosts allow|deny

2003-01-05 Thread Max Bowsher
Bert Vermeulen wrote:
 On Sun, 5 Jan 2003, Max Bowsher wrote:
 
 Bert Vermeulen wrote:
 Hi all,
 
 Does anyone know what the status is of Hideaki Yoshifuji's IPv6 ACL
 patch? He's submitted this twice now, and that was 3 months ago.
 Judging by the comments made when this was submitted, it's
 apparently not understood how important this is.
 
 - if you IPv6 on your rsync server, you can not secure it with
   hosts allow.
 
 - if you enable IPv6 on an rsync server that's secured with hosts
   deny to keep certain hosts out, well, they can get in again -- if
   they also have IPv6.
 
 Please, can this patch be merged into the next release? This is very
 important! It is NOT new functionality, it's a security fix.
 
 I think the problem is that wget currently has *no active
 maintainers*. 
 
 Based on a recent thread, there is no-one with CVS commit
 priviledges who reads this list.
 
 I'm talking about rsync. This is the rsync list.

OK... That was a fairly impressive Doh! moment! Ooops!

Max.
-- 
To unsubscribe or change options: http://lists.samba.org/mailman/listinfo/rsync
Before posting, read: http://www.tuxedo.org/~esr/faqs/smart-questions.html



Re: rsync feature suggestion

2003-01-03 Thread Max Bowsher
Hadmut Danisch wrote:
 I'd like to suggest a new feature to rsync.

 I am mirroring a debian archive, but unfortunately,
 debian mixes all files of several distributions in a
 subtree /pool. There is no way to select only the files
 of a certain distribution through a simple exclude/include
 expression.

 There is a tool called debmirror, which first downloads
 the distribution index files, extracts all the filenames/paths
 of the files needed and then calls rsync for every single file.
 Thats certainly not useful, especially since rsync shows the
 servers motd for every single file.

I was about to suggest:
$ rsync --include-from=list-file --exclude=\*
but of course that will exclude the parent directories of files you want,
causing them to be ignored.

This might work:
$ rsync --include-from=list-file --include=\*\*/ --exclude=\*

although it will mirror the entire directory structure (but not unspecified
files).

Probably, rsync should be taught that: If I explicitly include a file, look
for it explicitly, even if I've excluded a parent directory.

Max.


-- 
To unsubscribe or change options: http://lists.samba.org/mailman/listinfo/rsync
Before posting, read: http://www.tuxedo.org/~esr/faqs/smart-questions.html



Re: Rsync service on Win2k?

2002-11-29 Thread Max Bowsher
John Morgan Salomon [EMAIL PROTECTED] wrote:

 I'm hoping someone could give me a quick tip or two on getting rsync
 working as a Win2k service.  I'm not real proficient with Win2k, so
  be gentle. The posts I could
 find in the archive all seeem to have gotten past this basic problem!

 I've installed the latest Cygwin, as well as the Cygwin rsync package.

 cygrunsrv -I rsyncd -d Rsync daemon -p /usr/bin/rsync.exe -a
 --config=/etc/rsyncd.conf --daemon
 installs the service;  rsyncd.exe --config=/etc/rsyncd.conf --daemon
 runs it from a bash shell,
 but I can't seem to start it either using cygrunsrv -S rsyncd, or
 from the Services manager.

 I've also tried with --no-detach and -e CYGWIN='binmode tty ntsec' on
 the cygrunsrv command line,
 as described at http://acd.ucar.edu/~fredrick/win2k/rsync/

 Lastly, I tried getting it running via srvany.exe (from the Win2k
 resource kit) and srvinstw, with
 even less intelligible output.

cygrunsrv is definitely the way to go, not srvany.

--no-detach is *required*.

--config=/etc/rsyncd.conf should be a no-op, as that is the default path to
rsyncd.conf.

Is there any output in /var/log/rsyncd.log ?

Post your rsyncd.conf and the output of mount -m.

Max.

-- 
To unsubscribe or change options: http://lists.samba.org/mailman/listinfo/rsync
Before posting, read: http://www.tuxedo.org/~esr/faqs/smart-questions.html



Re: Include / exclude patterns

2002-11-28 Thread Max Bowsher
Carlos Molina [EMAIL PROTECTED] wrote:

 -BEGIN PGP SIGNED MESSAGE-
 Hash: SHA1

 Greetings.

 I'm trying to make some backups using rsync, but I have some questions
 about it.

 First, on the receiving side, i make a test with this line.

 rsync -vv -e ssh --recursive --include-from=include.txt
 cmolina@www-01:/ /tmp/cmolina

 On include.txt I have.
 + etc
 + home/cmolina/source
 + home/cmolina
 + var/spool
 - - dev/
 - - home/cmolina/
 - - tmp/
 - - root/
 - - disk2/
 - - home/
 - - usr/
 - - lib/
 - - var/
 - - bin/
 - - boot/
 - - dev/
 - - etc/
 - - floppy/
 - - initrd/
 - - lost+found
 - - proc/
 - - opt/
 - - sbin/
 - - vmlinuz
 - - /*

What are you tring to do with the double - signs?

 Note that the source path is /.

 Well, in resume, I'm trying to bypass the default rsync selection
 mechanism (include all the objects that aren't specified on the list),
 because we want to deny (exclude) all filenames, directories,
 archives, etc, and only permit the files, directories,
 SUBDIRECTORIES, that we specify on a include file.

 For example, we want to exclude anything, and only include the
 following directories (and it's contents)


 /etc
 /home/cmolina/source
 /home/cmolina
 /var/spool

If you want everything under /home/cmolina, why is /home/cmolina/source also
in your list?

Anyway:

+ /etc
+ /home/cmolina
+ /var/spool
- /*

Max.

-- 
To unsubscribe or change options: http://lists.samba.org/mailman/listinfo/rsync
Before posting, read: http://www.tuxedo.org/~esr/faqs/smart-questions.html



Re: Include / exclude patterns

2002-11-28 Thread Max Bowsher
Carlos Molina [EMAIL PROTECTED] wrote:

 + /etc
 + /home/cmolina
 + /var/log
 - - /*

Huh? - - ? Mistake again?

 rsync isn't include directories under /home and /var, because it
 exclude recursively on /*

Well sure, but it would have included dirs under /home/cmolina  and
/var/log.

The / in /* anchors to the toplevel.

Works for me, and looks like it was working for you from the output you
sent.

Max.

-- 
To unsubscribe or change options: http://lists.samba.org/mailman/listinfo/rsync
Before posting, read: http://www.tuxedo.org/~esr/faqs/smart-questions.html



Re: Include / exclude patterns

2002-11-28 Thread Max Bowsher
Carlos Molina [EMAIL PROTECTED] wrote:

 Nope, isn't works, because rsync only fetchs /etc directory.
 On the output, you could see that /home nad /var is excluded (I
 suppose that is excluded by /* pattern)

Blah. Your right. This will work:

+ /etc
+ /home
+ /home/cmolina
- /home/*
+ /var
+ /var/spool
- /var/*
- /*


 Can you explain me with more detail what you refer with 
 The / in /* anchors to the toplevel.
 

/* will match root-of-rsync/foo, but not root-of-rsync/foo/bar.
Of course, (and this is what I forgot), if root/foo is excluded, then
rsync will never bother to look inside at root/foo/bar.

Max.

-- 
To unsubscribe or change options: http://lists.samba.org/mailman/listinfo/rsync
Before posting, read: http://www.tuxedo.org/~esr/faqs/smart-questions.html



Re: Syntax for using rsync options --exclude and --delete!

2002-11-20 Thread Max Bowsher
[EMAIL PROTECTED] [EMAIL PROTECTED] wrote:

 I was wondering if anyone has a viable syntax solution for using
 rsync with the --exclude and --delete option.
...
 Current Syntax:
 rsync -vaox --exclude .snapshot * [destination]
 NOTE: Current directory is source.

I believe changing * to . will solve your problem.

I think delete disables itself when rsync is given more than 1 source.
(i.e. * expands to multiple objects, whereas . is a single source)

 Btw - I am using rsync version 2.3.1
That's ancient - Upgrade!

Max.

-- 
To unsubscribe or change options: http://lists.samba.org/mailman/listinfo/rsync
Before posting, read: http://www.tuxedo.org/~esr/faqs/smart-questions.html



Re: The exclude option of Rsync not work right.

2002-11-19 Thread Max Bowsher
Lori Anderson [EMAIL PROTECTED] wrote:

 Can someone explain why my exclude option is not excluding filles as
 instructed in my script below.

 4. rsync /software/testdir/  --exclude='/software/testdir/test.sql'
 serv602:/software/testdir/

You are excluding /software/testdir/software/testdir/test.sql with that
option.

Max.

-- 
To unsubscribe or change options: http://lists.samba.org/mailman/listinfo/rsync
Before posting, read: http://www.tuxedo.org/~esr/faqs/smart-questions.html



Re: deny host and auth users not working over ssh

2002-11-19 Thread Max Bowsher
johnnyfulcrum [EMAIL PROTECTED] wrote:

 I have a solaris 8 box with the latest ssl, ssh, and rsync all set up.
  ssh and an apache-sll site are running good - I feel confident that
 ssl and ssh are set up correctly, but when I use rsync over ssh, it
 (rsync) will allow me to sync as any (system) user from any host ecven
 though the rsyncd.conf file in /etc has user auth = one real system
 user and host deny = *
 
 is there something I'm missing here?  Seems I shouldn't be able to run
 rsync

rsync*d*.conf.

If you are using the ssh access method, then there is no rsyncd involved.


Max.

-- 
To unsubscribe or change options: http://lists.samba.org/mailman/listinfo/rsync
Before posting, read: http://www.tuxedo.org/~esr/faqs/smart-questions.html



Re: Setting the File/Folder chmod bits - Wish List ?

2002-11-18 Thread Max Bowsher
jw schultz [EMAIL PROTECTED] wrote:

 PS.  In POSIX filesystems we don't have folders.  We have
 directories. And the difference matters :)

There's a difference? Can you explain it? 

Thanks,

Max.

-- 
To unsubscribe or change options: http://lists.samba.org/mailman/listinfo/rsync
Before posting, read: http://www.tuxedo.org/~esr/faqs/smart-questions.html



Re: Win32 Version?

2002-10-28 Thread Max Bowsher
Nitin Agarwal [EMAIL PROTECTED] wrote:

 Hi
 I have used the rsync.exe (precompiled binary) from the net.
 I installed rsync as service in Windows NT server using SRVANY and
 INSTSRV.

I don't know whether it makes any difference or not, but if your rsync.exe
is Cygwin-based (and it must be, because there is no native Windows port),
then using Cygwin's own service tool (cygrunsrv) is probably a good idea.

Max.

-- 
To unsubscribe or change options: http://lists.samba.org/mailman/listinfo/rsync
Before posting, read: http://www.tuxedo.org/~esr/faqs/smart-questions.html



Re: rsync with large gzip files.

2002-10-27 Thread Max Bowsher
Leaw, Chern Jian [EMAIL PROTECTED] wrote:
 # rsync -avz  /fs10/archives/archive.gz hostB:/fs10/archives

Try without -z. If the file is already gzipped, you won't be losing much
time.

 # /usr/bin/rsync --version
 rsync version  2.4.6 protocol version 24

Quite old now. You should probably try upgrading. I think quite a few fixes
happened between 2.4.6 and 2.5.5 (current).

 Those g-zipped files were compressed using gzip version 1.2.4(18 Aug
 93), and with the following method:
 # cat dir1 dir2 dir3 ... | gzip  archives.gz

What does cat-ing a directory do? My cat just gives the error 'Is a
directory'.

Max.

-- 
To unsubscribe or change options: http://lists.samba.org/mailman/listinfo/rsync
Before posting, read: http://www.tuxedo.org/~esr/faqs/smart-questions.html



Re: Rsync from Windows to Windows

2002-10-04 Thread Max Bowsher

Bruno Ferreira wrote:
 At 14:32 04-10-2002 +0530, you wrote:
 Hi..
 Can anybody please help me in configuring RSYNC to copy files from
 WINDOWS NT to WINDOWS NT
 
  Here's one way, there's always some others:
 
 
  Create a share in each machine, one readable from the source
 one and one read/writable on the destination one.

By doing this you lose any benefit from rsyncs partial-update algorithm.

You must either use ssh or an rsync daemon to get the benefits of this.

rsync on Windows requires Cygwin.

Max.
-- 
To unsubscribe or change options: http://lists.samba.org/mailman/listinfo/rsync
Before posting, read: http://www.tuxedo.org/~esr/faqs/smart-questions.html



Re: Patronizing the exclude * option

2002-08-01 Thread Max Bowsher

Maurice Volaski wrote:
 I need to get around the requirement of --exclude=* to have all the
 parent directories of the files and directories that are to be
 included. So given the file..

 /startdirectory/subdirectory1/subdirectory2/filetobecopied

 I need to include
 /
 /subdirectory1
 /subdirectory1/subdirectory2

Maybe --include=*/ --exclude=* ?

Of course, that will sync the entire directory tree, but without files that are
not explicitely included.
Ugly, but won't waste much transfer time.

To the list in general:
Wasn't there a --files-from option someone was working on?

Max.


-- 
To unsubscribe or change options: http://lists.samba.org/mailman/listinfo/rsync
Before posting, read: http://www.tuxedo.org/~esr/faqs/smart-questions.html



Re: Status Query - Please respond - Re: Patch to avoid 'Connection reset by peer' error for rsync on cygwin

2002-05-17 Thread Max Bowsher

Combined reply:

Mark - Point taken. But even if it worked correctly everywhere, to me there
seems to be something aesthetically wrong about just letting sockets close
themselves. Kind of like a malloc() without a free().

Wayne - Wouldn't the atexit solution require that we keep a list of fds to
close? Anyway, I think it is now up to me to make a patch which fixes the
problem in the most discreet and unsweeping manner possible, and then post it
for Martin to decide.


Max.


Mark Eichin [EMAIL PROTECTED] wrote:
 Just because Linux lets you get away without it doesn't mean its a good idea.

 Except this has nothing to do with linux - this is unix behaviour that
 goes all the way back, it's part of the process model.  It's part of
 what exiting *does*, so it *is* a bug in cygwin if it isn't doing the
 cleanup (and really, cygwin does so many other bizarre things under
 the covers to create Unix/POSIX semantics in the Very Different win32
 environment, I'm more than a little surprised it isn't doing this
 already... skeptical, even, though I haven't been deep inside cygwin
 in years.)

Wayne Davison [EMAIL PROTECTED] wrote:
 On Thu, 16 May 2002, Max Bowsher wrote:
 That just moves the shutdown call from where you finish with the fd to
 where you start using the fd - that's got to be less intuitive.

 Being more or less intuitive is not the point.  The idea was to have as
 little cygwin kludge code as possible.  Thus, we'd just have one call to
 atexit() during startup, with the single cleanup function being able to
 handle any and all opened sockets, and we're done (if this is even
 feasible -- I haven't looked into it).  This was prompted by Martin's
 statement that he considers this a cygwin bug -- I was assuming that he
 didn't want to make sweeping changes to all the cleanup code in rsync.
 Whether he wants to handle this in a more invasive manner is up to him.

 ..wayne..


-- 
To unsubscribe or change options: http://lists.samba.org/mailman/listinfo/rsync
Before posting, read: http://www.tuxedo.org/~esr/faqs/smart-questions.html



Re: Status Query - Please respond - Re: Patch to avoid 'Connection reset by peer' error for rsync on cygwin

2002-05-16 Thread Max Bowsher

No. That just moves the shutdown call from whren you finish with the fd to where
you start using the fd - that's got to be less intuitive.
Surely it isn't too much to close file descriptors you open? Just because Linux
lets you get away without it doesn't mean its a good idea.

Anyway, if I provide a patch that neatly closes socket fds when they are no
longer needed, will it get applied?

Max.

Wayne Davison [EMAIL PROTECTED] wrote:
 Here's an idea which I haven't had a chance to investigate:

 Would it be possible to use atexit() to register a call to shutdown()
 for cygwin (or a call to a custom function that would call shutdown()
 for the appropriate socket fds)?  This should allow cgywin's broken
 socket code to get properly cleaned up without having to sprinkle a
 bunch of cygwin-specific code all over the source (as long as the
 socket fds don't get closed before we start the exit handling).

 ..wayne..


-- 
To unsubscribe or change options: http://lists.samba.org/mailman/listinfo/rsync
Before posting, read: http://www.tuxedo.org/~esr/faqs/smart-questions.html



Re: Status Query - Please respond - Re: Patch to avoid 'Connection reset by peer' error for rsync on cygwin

2002-05-15 Thread Max Bowsher

I wasn't. But he's addressing the same problem, in a difference case to my
initial patch

Max.

 Are you all aware of the work done by Jonathan Kamens last July?
 See bug 3236 ...

 http://rsync.samba.org/cgi-bin/rsync/incoming?id=3236

 Sorry if this has already been discussed: I am joining the thread late.

 Bob Byrnese-mail: [EMAIL PROTECTED]



-- 
To unsubscribe or change options: http://lists.samba.org/mailman/listinfo/rsync
Before posting, read: http://www.tuxedo.org/~esr/faqs/smart-questions.html



Re: Status Query - Please respond - Re: Patch to avoid 'Connection reset by peer' error for rsync on cygwin

2002-05-14 Thread Max Bowsher

 After thinking about it a bit more I'm somewhat inclined to call it a
 bug in Cygwin and try to get them to fix it.

Well, you could, but I'd much prefer it if you didn't :-)
I guess its time for you to make an executive descision - Is it reasonable to
include code in rsync to close sockets, even though exit() does it anyway on
most platforms. I would argue that a few close_socket() calls woudn't cause any
clutter - but then my interest is obviously focused on cygwin.

If you do give the go-ahead, then should I fix this inconsistency whilst I am at
it: In main(), rsync decides whether to be a daemon, server, or client. The
functions for some code paths are designed not to return, whilst others are
designed to return. Would it be better for all code paths to return to main _as
long as that does not cause extra mess_?


Thanks,

Max.

More context below:

Martin Pool [EMAIL PROTECTED] wrote:
 On 10 May 2002, Max Bowsher [EMAIL PROTECTED] wrote:

 The problem was especially severe here, because rsync didn't even
 close the socket in these cases - it would write its last data, then return a
 couple of times, and exit().

 It should not matter:

The function _exit terminates the calling process
immediately. Any open file descriptors belonging to the
process are closed; any children of the process are inherited
by process 1, init, and the process's parent is sent a SIGCHLD
signal.

 We could have a shutdownsocket(). Is it worth it for just for 2 lines of
code?
 shutdown(fd, SHUT_WR);
 close(fd);

 Yes, because (if this is really necessary) then it's a workaround for
 a platform bug and so not obvious.

 After thinking about it a bit more I'm somewhat inclined to call it a
 bug in Cygwin and try to get them to fix it.



-- 
To unsubscribe or change options: http://lists.samba.org/mailman/listinfo/rsync
Before posting, read: http://www.tuxedo.org/~esr/faqs/smart-questions.html



Re: Status Query - Please respond - Re: Patch to avoid 'Connection reset by peer' error for rsync on cygwin

2002-05-10 Thread Max Bowsher

Martin Pool [EMAIL PROTECTED] wrote:
 Sorry, I've been out of town this week.

No problem.

 This is the shutdown one, right?  I wanted to check about portability
 before we put it in.  Snader's Effective TCP/IP Programming says that

   shutdown(fd, 1);

 is OK on both Unix and Windows and will avoid errors from closing the
 socket.  So I think it's OK to put it in.  Winsock misinterprets other
 values of the second parameter so we can't use them.

Yes, this is the shutdown one. This issue certainly does not require any other
shutdown second parameter, so we are safe there.

 I don't understand why you need to only insert this call here and
 not in every case where a socket is closed.  If there's no specific
 reason we should have a common shutdownsocket() routine and call it;
 if there is a reason we should document it.

Kludginess. I did the quickest fix to the immediate problem I had, which didn't
require me to trace through the lifetime of all socket handles used everywhere
in rsync. The problem was especially severe here, because rsync didn't even
close the socket in these cases - it would write its last data, then return a
couple of times, and exit().

We could have a shutdownsocket(). Is it worth it for just for 2 lines of code?
shutdown(fd, SHUT_WR);
close(fd);

If you say yes, then fair enough.

In any case, I will study the rsync code in greater detail, and produce a patch
covering every case a socket is closed.

Max.

PS: Someone mentioned that 2.5.6 has branched in CVS. I'm a bit of a CVS newbie
unfortunately - what is the command for 'what branches exist in the repository?'



-- 
To unsubscribe or change options: http://lists.samba.org/mailman/listinfo/rsync
Before posting, read: http://www.tuxedo.org/~esr/faqs/smart-questions.html



Avoid 'Connection reset by peer' on cygwin - agree hold until after 2.5.6 and note to Lapo Luchini

2002-05-10 Thread Max Bowsher

 I think it might be too risky for 2.5.6 and perhaps should wait to 2.6.0.

 - Dave

Yes, now the small fix has turned into a multi-source file minor redesign, lets
hold it until after 2.5.6 - at least for the standard release.

To Lapo Luchini: Maybe this could go into the cygwin 2.5.6-1 as a temporary
measure until it is put into mainline rsync? (It is a patch to solve the Daemon
mode sometimes produces read error: Connection reset by peer at the very end
of transfer. problem)


Max.



-- 
To unsubscribe or change options: http://lists.samba.org/mailman/listinfo/rsync
Before posting, read: http://www.tuxedo.org/~esr/faqs/smart-questions.html



Re: Patch to avoid 'Connection reset by peer' error for rsync on cygwin

2002-05-01 Thread Max Bowsher

What is the status of my patch?

If the answer is 'In a ToDo list', then I will be quite happy, but if there are
any objections to it, I would like to resolve them.

Thankyou.

Max.


-- 
To unsubscribe or change options: http://lists.samba.org/mailman/listinfo/rsync
Before posting, read: http://www.tuxedo.org/~esr/faqs/smart-questions.html



Re: Patch to avoid 'Connection reset by peer' error for rsync on cygwin

2002-04-29 Thread Max Bowsher

What is the status of this patch? (Ideally I'd like it to make it in to 2.5.6,
so I can stop using a modified version). I have successfully used rsync with the
patch on Linux, and have done a test where a client does connect(), then
sleep(), whilst the server does write(), shutdown(,SHUT_WR),close(), before the
client does read(), and this completes successfully.

If there is anything else I should do to help it along, please let me know.

Max.


-- 
To unsubscribe or change options: http://lists.samba.org/mailman/listinfo/rsync
Before posting, read: http://www.tuxedo.org/~esr/faqs/smart-questions.html



Re: Patch to avoid 'Connection reset by peer' error for rsync on cygwin

2002-04-26 Thread Max Bowsher

I though that shutdown acts as below:
--
Syntax:
int shutdown(int sockfd, int howto);
returns 0 if OK, -1 on error.

Action of the function depends on the value of howto -
SHUT_RD - read half of the connection is closed. The data currently in the
socket receive buffer is discarded.
SHUT_WR - write half of the connection is closed. The data in the socket send
buffer is sent followed by the normal TCP connection termination sequence.
SHUT_RDWR - both read and write halves of the connection are closed.
--
( from
http://www.google.com/search?q=cache:B6qVFvpm-p4C:www.ncst.ernet.in/~netfac/PGDI
T/ppt/IOmultiplex.ppt+Unix+socket+programming+shutdown+SHUT_WRhl=enie=UTF8)

SUSv2 is annoyingly somewhat vague on the specifics.

Perhaps you were thinking of SHUT_RD as discarding data? My patch used only
SHUT_WR, so it should be safe unless the above is totally wrong.

I've just done a quick test with my patch on Linux, and didn't see any problem.


Max.


Martin Pool [EMAIL PROTECTED] wrote:
 From memory, Practical TCP Programming says that this behaviour is
 caused by a misunderstanding of the sockets API by the WinSock
 programmers.  The correct meaning of shutdown() on Unix is to throw
 away any outstanding data and close the socket immediately.  Normally,
 when you close a socket, you do want to let any pending data get
 across, so it's rarely used.

 On Windows shutdown() does not throw away data, and should be called.
 (Trust M$ to get it backwards and force everybody else to adapt.)

 So the patch cannot go in as is, because I think it will break Unix.
 Something like it can go in, #ifdefed for W32.




smime.p7s
Description: application/pkcs7-signature


Any chance of --no-detatch in the next release

2001-11-30 Thread Max Bowsher

This option is required for use on cygwin in server mode - so integrating it
into the main code would be very helpful for us cygwinners. It is after all
a rather small patch - doesn't clutter up the code that much :-)

Max.