samba-bugs@samba.org
2004-Aug-05 05:11 UTC
[Bug 1582] New: rsync dry run cannot find missing folders, contradicts actual run.
https://bugzilla.samba.org/show_bug.cgi?id=1582 Summary: rsync dry run cannot find missing folders, contradicts actual run. Product: rsync Version: 2.6.2 Platform: All OS/Version: IRIX Status: NEW Severity: normal Priority: P3 Component: core AssignedTo: wayned@samba.org ReportedBy: weyerse@sgi.com QAContact: rsync-qa@samba.org If you are telling rsync to sync to a folder which does not exist, it would normally create the folder and then continue to run normally. But if you were to use the -n dry run option, it can not create the folder and errors out. This leaves a user confused as to what happened. Here is an example, in this example, junkdir does not exist on elk but does exist on the host. Normally rsync would then create the directory then copy the junkdir4 directory as it should. But with the dry run option (and the -vvv debugging option to show what is happening) I get this: /sw/pd/bin/rsync262 -azvvvn --delete --rsync-path=/sw/pd/bin/rsync262 /export/sw/irix/testirix6/junkdir/junkdir4 elk:/export/sw/irix6/sw01/testirix6/junkdir/ opening connection using rsh elk /sw/pd/bin/rsync262 --server -vvvnlogDtprz --delete . /export/sw/irix6/sw01/testirix6/junkdir/ building file list ... [sender] make_file(junkdir4,*,2) [sender] expand file_list to 131072 bytes, did move [sender] make_file(junkdir4/gar1,*,2) [sender] make_file(junkdir4/gar2,*,2) [sender] make_file(junkdir4/gar3,*,2) [sender] make_file(junkdir4/gardir1,*,2) [sender] make_file(junkdir4/gardir1/blah2,*,2) [sender] make_file(junkdir4/gardir1/blah3,*,2) [sender] make_file(junkdir4/gardir1/blah1,*,2) [sender] clearing per-dir .cvsignore exclude list [sender] clearing per-dir .cvsignore exclude list done send_file_list done send_files starting server_recv(2) starting pid=433406 recv_file_name(junkdir4) recv_file_name(junkdir4/gar1) recv_file_name(junkdir4/gar2) recv_file_name(junkdir4/gar3) recv_file_name(junkdir4/gardir1) recv_file_name(junkdir4/gardir1/blah2) recv_file_name(junkdir4/gardir1/blah3) recv_file_name(junkdir4/gardir1/blah1) received 8 names recv_file_list done get_local_name count=8 /export/sw/irix6/sw01/testirix6/junkdir/ created directory /export/sw/irix6/sw01/testirix6/junkdir/ push_dir "/export/sw/irix6/sw01/testirix6/junkdir/" failed: No such file or directory (2) rsync error: errors selecting input/output files, dirs (code 3) at main.c(355) _exit_cleanup(code=3, file=main.c, line=355): about to call exit(3) rsync: connection unexpectedly closed (8 bytes read so far) rsync error: error in rsync protocol data stream (code 12) at io.c(342) _exit_cleanup(code=12, file=io.c, line=342): about to call exit(12) Now if I were to run this without the -n option, it would run normally, which contradicts what -n option tells us. /sw/pd/bin/rsync262 -azvvv --delete --rsync-path=/sw/pd/bin/rsync262 /export/sw/irix/testirix6/junkdir/junkdir4 elk:/export/sw/irix6/sw01/testirix6/junkdir/ opening connection using rsh elk /sw/pd/bin/rsync262 --server -vvvlogDtprz --delete . /export/sw/irix6/sw01/testirix6/junkdir/ building file list ... [sender] make_file(junkdir4,*,2) [sender] expand file_list to 131072 bytes, did move [sender] make_file(junkdir4/gar1,*,2) [sender] make_file(junkdir4/gar2,*,2) [sender] make_file(junkdir4/gar3,*,2) [sender] make_file(junkdir4/gardir1,*,2) [sender] make_file(junkdir4/gardir1/blah2,*,2) [sender] make_file(junkdir4/gardir1/blah3,*,2) [sender] make_file(junkdir4/gardir1/blah1,*,2) [sender] clearing per-dir .cvsignore exclude list [sender] clearing per-dir .cvsignore exclude list done send_file_list done send_files starting server_recv(2) starting pid=432780 recv_file_name(junkdir4) recv_file_name(junkdir4/gar1) recv_file_name(junkdir4/gar2) recv_file_name(junkdir4/gar3) recv_file_name(junkdir4/gardir1) recv_file_name(junkdir4/gardir1/blah2) recv_file_name(junkdir4/gardir1/blah3) recv_file_name(junkdir4/gardir1/blah1) received 8 names recv_file_list done get_local_name count=8 /export/sw/irix6/sw01/testirix6/junkdir/ created directory /export/sw/irix6/sw01/testirix6/junkdir send_file_list done deleting in junkdir4 recv_files(8) starting generator starting pid=432780 count=8 delta transmission enabled recv_generator(junkdir4,0) set modtime of junkdir4 to (1091220597) Fri Jul 30 15:49:57 2004 junkdir4/ recv_generator(junkdir4/gar1,1) send_files(1, /export/sw/irix/testirix6/junkdir/junkdir4/gar1) send_files mapped /export/sw/irix/testirix6/junkdir/junkdir4/gar1 of size 0 calling match_sums /export/sw/irix/testirix6/junkdir/junkdir4/gar1 junkdir4/gar1 sending file_sum false_alarms=0 tag_hits=0 matches=0 sender finished /export/sw/irix/testirix6/junkdir/junkdir4/gar1 recv_generator(junkdir4/gar2,2) send_files(2, /export/sw/irix/testirix6/junkdir/junkdir4/gar2) send_files mapped /export/sw/irix/testirix6/junkdir/junkdir4/gar2 of size 0 calling match_sums /export/sw/irix/testirix6/junkdir/junkdir4/gar2 junkdir4/gar2 sending file_sum false_alarms=0 tag_hits=0 matches=0 sender finished /export/sw/irix/testirix6/junkdir/junkdir4/gar2 recv_generator(junkdir4/gar3,3) send_files(3, /export/sw/irix/testirix6/junkdir/junkdir4/gar3) send_files mapped /export/sw/irix/testirix6/junkdir/junkdir4/gar3 of size 0 calling match_sums /export/sw/irix/testirix6/junkdir/junkdir4/gar3 junkdir4/gar3 sending file_sum false_alarms=0 tag_hits=0 matches=0 sender finished /export/sw/irix/testirix6/junkdir/junkdir4/gar3 recv_generator(junkdir4/gardir1,4) set modtime of junkdir4/gardir1 to (1091218088) Fri Jul 30 15:08:08 2004 junkdir4/gardir1/ recv_generator(junkdir4/gardir1/blah1,5) send_files(5, /export/sw/irix/testirix6/junkdir/junkdir4/gardir1/blah1) send_files mapped /export/sw/irix/testirix6/junkdir/junkdir4/gardir1/blah1 of size 0 calling match_sums /export/sw/irix/testirix6/junkdir/junkdir4/gardir1/blah1 junkdir4/gardir1/blah1 sending file_sum false_alarms=0 tag_hits=0 matches=0 sender finished /export/sw/irix/testirix6/junkdir/junkdir4/gardir1/blah1 recv_generator(junkdir4/gardir1/blah2,6) send_files(6, /export/sw/irix/testirix6/junkdir/junkdir4/gardir1/blah2) send_files mapped /export/sw/irix/testirix6/junkdir/junkdir4/gardir1/blah2 of size 0 calling match_sums /export/sw/irix/testirix6/junkdir/junkdir4/gardir1/blah2 junkdir4/gardir1/blah2 sending file_sum false_alarms=0 tag_hits=0 matches=0 sender finished /export/sw/irix/testirix6/junkdir/junkdir4/gardir1/blah2 recv_generator(junkdir4/gardir1/blah3,7) send_files(7, /export/sw/irix/testirix6/junkdir/junkdir4/gardir1/blah3) send_files mapped /export/sw/irix/testirix6/junkdir/junkdir4/gardir1/blah3 of size 0 calling match_sums /export/sw/irix/testirix6/junkdir/junkdir4/gardir1/blah3 junkdir4/gardir1/blah3 sending file_sum false_alarms=0 tag_hits=0 matches=0 sender finished /export/sw/irix/testirix6/junkdir/junkdir4/gardir1/blah3 generate_files phase=1 send_files phase=1 recv_files(junkdir4/gar1) got file_sum renaming junkdir4/.gar1.433730 to junkdir4/gar1 set modtime of junkdir4/gar1 to (1091205050) Fri Jul 30 11:30:50 2004 recv_files(junkdir4/gar2) got file_sum renaming junkdir4/.gar2.433730 to junkdir4/gar2 set modtime of junkdir4/gar2 to (1091205050) Fri Jul 30 11:30:50 2004 recv_files(junkdir4/gar3) got file_sum renaming junkdir4/.gar3.433730 to junkdir4/gar3 set modtime of junkdir4/gar3 to (1091205050) Fri Jul 30 11:30:50 2004 recv_files(junkdir4/gardir1/blah1) got file_sum renaming junkdir4/gardir1/.blah1.433730 to junkdir4/gardir1/blah1 set modtime of junkdir4/gardir1/blah1 to (1091218088) Fri Jul 30 15:08:08 2004 recv_files(junkdir4/gardir1/blah2) got file_sum renaming junkdir4/gardir1/.blah2.433730 to junkdir4/gardir1/blah2 set modtime of junkdir4/gardir1/blah2 to (1091218088) Fri Jul 30 15:08:08 2004 recv_files(junkdir4/gardir1/blah3) got file_sum renaming junkdir4/gardir1/.blah3.433730 to junkdir4/gardir1/blah3 set modtime of junkdir4/gardir1/blah3 to (1091218088) Fri Jul 30 15:08:08 2004 recv_files phase=1 generate_files phase=2 send files finished total: matches=0 tag_hits=0 false_alarms=0 data=0 recv_generator(junkdir4,0) set modtime of junkdir4 to (1091220597) Fri Jul 30 15:49:57 2004 recv_generator(junkdir4/gardir1,4) set modtime of junkdir4/gardir1 to (1091218088) Fri Jul 30 15:08:08 2004 generate_files finished recv_files finished wrote 361 bytes read 140 bytes 1002.00 bytes/sec total size is 0 speedup is 0.00 _exit_cleanup(code=0, file=main.c, line=633): about to call exit(0) This becomes a problem because we need the dry run to work exactly as a normal run would, only without actually running. Therefore a user can find out what will happen in rsyncing the directories without it actually happening. If they find they have this error then running the normal command would be questionable. I hope this report has been satisfactory. -- Configure bugmail: https://bugzilla.samba.org/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are the QA contact for the bug, or are watching the QA contact.