From: SourceForge.net <no...@so...> - 2008-10-27 22:55:23
|
Bugs item #2152550, was opened at 2008-10-08 05:29 Message generated for change (Comment added) made by henryn You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=622063&aid=2152550&group_id=98788 Please note that this message will contain a full copy of the comment thread, including the initial issue submission, for this request, not just the latest update. Category: None Group: v0.8.x (devel) Status: Open Resolution: None Priority: 5 Private: No Submitted By: Xuefer (xuefer) Assigned to: Nobody/Anonymous (nobody) Summary: rsync cannot set mtime correctly on cofs Initial Comment: $ cd ~ (native mount, non-cofs, good result) $ rm -f a b; touch -d 1970-1-1 a ; rsync -a a b; ls --full-time a b ; rm -f a b-rw-r--r-- 1 xuefer xuefer 0 1970-01-01 00:00:00.000000000 +0800 a -rw-r--r-- 1 xuefer xuefer 0 1970-01-01 00:00:00.000000000 +0800 b $ cd /c/tmp (cofs mount, wrong result) $ rm -f a b; touch -d 1970-1-1 a ; rsync -a a b; ls --full-time a b ; rm -f a b-rwxr-xr-x 1 xuefer users 0 1970-01-01 00:00:00.000000000 +0800 a* -rwxr-xr-x 1 xuefer users 0 2008-10-08 11:29:22.000000000 +0800 b* ---------------------------------------------------------------------- Comment By: Henry N. (henryn) Date: 2008-10-27 23:55 Message: This bug is fixed by SVN revision r1127 and has nothing to do with nocache and Bug #2176188. The parameter for set atime and mtime are swapped by wrong variable names. The current snapshot http://www.colinux.org/snapshots/ includes this change. For rsync test have added "stat a b", this shows the swapped times. The test script: cd /mnt/temp rm -f a b sleep 1 touch -d 1970-1-1 a rsync -a a b ls --full-time a b stat a b Before r1127 (non interesting lines removed): -rwxr-xr-x 1 root root 0 1970-01-01 00:00:00.000000000 +0000 a -rwxr-xr-x 1 root root 0 2008-10-27 22:31:25.000000000 +0000 b File: `a' Access: 1970-01-01 00:00:00.000000000 +0000 Modify: 1970-01-01 00:00:00.000000000 +0000 Change: 2008-10-27 22:31:27.000000000 +0000 File: `b' Access: 1970-01-01 00:00:00.000000000 +0000 Modify: 2008-10-27 22:31:25.000000000 +0000 Change: 2008-10-27 22:31:27.000000000 +0000 After r1127 (non interesting lines removed): -rw-r--r-- 1 root root 0 1970-01-01 00:00:00.000000000 +0000 a -rw-r--r-- 1 root root 0 1970-01-01 00:00:00.000000000 +0000 b File: `a' Access: 1970-01-01 00:00:00.000000000 +0000 Modify: 1970-01-01 00:00:00.000000000 +0000 Change: 2008-10-27 22:37:22.000000000 +0000 File: `b' Access: 2008-10-27 22:37:22.000000000 +0000 Modify: 1970-01-01 00:00:00.000000000 +0000 Change: 2008-10-27 22:37:22.000000000 +0000 The same script on /tmp (cobd), have same times: -rw-r--r-- 1 root root 0 1970-01-01 00:00:00.000000000 +0000 a -rw-r--r-- 1 root root 0 1970-01-01 00:00:00.000000000 +0000 b File: `a' Access: 1970-01-01 00:00:00.000000000 +0000 Modify: 1970-01-01 00:00:00.000000000 +0000 Change: 2008-10-27 22:56:18.000000000 +0000 File: `b' Access: 2008-10-27 22:56:18.000000000 +0000 Modify: 1970-01-01 00:00:00.000000000 +0000 Change: 2008-10-27 22:56:18.000000000 +0000 ---------------------------------------------------------------------- Comment By: Henry N. (henryn) Date: 2008-10-26 21:55 Message: This is a duplicate of bug# 2176188 "file sync wrong on cofs". Rsync creates temporally files like ".b..b8jlLdx". Than rsync tries to change attributes after rename. The rename is not complete from async file close, so the file can't reopen shortly for time modifications. As workaround you can add "nocache" to the mount options, then it works. ---------------------------------------------------------------------- You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=622063&aid=2152550&group_id=98788 |