RE: [SLE] The "cp" command is skipping files/dirs over nfs
Hello,
I am using "cp -pR /dir-local /dir-nfs-mount" and noticing that not everything is getting copied over. No one is accessing the files and they are not in use. Is there a way that "cp" can produce a log of what it can't copy or, better yet, force it to copy *everything*?
Thank you,
James
Are you coping the director or trying to copy just the files in the directory? Try "cp -Rp" /dir-local/* /dir-nfs-mount/yourdirectory
[]...Is it dot files that are missing?
A user alerted me that some of his files were missing and it appeared to be somewhat random. Trying to copy files and directories. There aren't any dot files in these directories. By the way, how can I list total file count in a directory? "du" shows total bytes, but what shows total files? This "cp" problem is pretty odd. Thanks, James
I use find /dir -depth | cpio -dvmp /new_dir to recursively copy objects because it lets me know if something was NOT copied properly. I do not like cp either on UNIX or Linux because I run into issues like you have described every now and then. LDB James D. Parra wrote:
Hello,
I am using "cp -pR /dir-local /dir-nfs-mount" and noticing that not everything is getting copied over. No one is accessing the files and they are not in use. Is there a way that "cp" can produce a log of what it can't copy or, better yet, force it to copy *everything*?
Thank you,
James
Are you coping the director or trying to copy just the files in the directory? Try "cp -Rp" /dir-local/* /dir-nfs-mount/yourdirectory
[]...Is it dot files that are missing?
A user alerted me that some of his files were missing and it appeared to be somewhat random. Trying to copy files and directories. There aren't any dot files in these directories.
By the way, how can I list total file count in a directory? "du" shows total bytes, but what shows total files?
This "cp" problem is pretty odd.
Thanks,
James
On Fri, 2005-10-14 at 17:08 -0700, James D. Parra wrote:
Hello,
I am using "cp -pR /dir-local /dir-nfs-mount" and noticing that not everything is getting copied over. No one is accessing the files and they are not in use. Is there a way that "cp" can produce a log of what it can't copy or, better yet, force it to copy *everything*?
Thank you,
James
Are you coping the director or trying to copy just the files in the directory? Try "cp -Rp" /dir-local/* /dir-nfs-mount/yourdirectory
[]...Is it dot files that are missing?
A user alerted me that some of his files were missing and it appeared to be somewhat random. Trying to copy files and directories. There aren't any dot files in these directories.
By the way, how can I list total file count in a directory? "du" shows total bytes, but what shows total files?
ls -1|wc -l will show a count of all of the files and dirs -- Ken Schneider UNIX since 1989, linux since 1994, SuSE since 1998
participants (3)
-
James D. Parra
-
Ken Schneider
-
Lawrence Bowie