On Wed, 31 Oct 2007, Graf, Peter wrote:
Additional info to my former mail:
1) My former mail contained a small inconsistency (after anonymizing the user
name). The following messages show the problem in a consistent way
(username, home-directory name):
...
prompt% cp -p ~/.cshrc ~/tmp/.cshrc
prompt% ls -l ~/.cshrc ~/tmp/.cshrc
-rwxr-x--- 1 pg mygroup 2180 Jan 19 2007 /home/pg/.cshrc
-rwxr-x--- 1 pg mygroup 2180 Oct 31 14:46 /home/pg/tmp/.cshrc
Timestamp was NOT preserved.
Does strace show the cause of the problem?
$ strace -e trace=file cp --preserve=timestamps a b
on my system gives:
[ snipped ld.so stuff ]
stat64("b", 0xffffd7f0) = -1 ENOENT (No such file or directory)
stat64("a", {st_mode=S_IFREG|0640, st_size=0, ...}) = 0
stat64("b", 0xffffd63c) = -1 ENOENT (No such file or directory)
open("a", O_RDONLY|O_LARGEFILE) = 3
open("b", O_WRONLY|O_CREAT|O_LARGEFILE, 0100640) = 5
utimes("/proc/self/fd/5", {1193849440, 0}) = 0
"utimes" is the relevent system call, which sets the timestamps on the
inode.
Cheers,
Phil
_______________________________________________
Bug-coreutils mailing list
[email protected]
http://lists.gnu.org/mailman/listinfo/bug-coreutils