Charles,
Please read the whole thread, which starts at
https://lists.debian.org/debian-user/2020/04/msg01361.html. It is clear
there that -p has no effect on that particular case of smb destinations.
A similar problem is happening with mv.
I resurrect my stretch workstation and the behavior is different from
buster, when copying a file with -pi from ext4 to smb.
On 4/29/20 3:16 PM, Charles Curley wrote:
On Wed, 29 Apr 2020 12:22:41 -0400
Alberto Sentieri <2...@tripolho.com> wrote:
cp and mv are not preserving the file timestamps when copying from a
ext4 file system to a smb file system.
What I see is:
* mv does preserve the time of the file, regardless of copying to an
SMB share or not.
* cp indeed does not preserve the time of the original file, regardless
of copying to an SMB share or not.
mv simply moves a directory entry, including the inode, from here to
there. cp creates a new directory entry at the destination. So these
results make sense.
To have cp preserve the time (i.e. copy the original file's time to the
copy), use its -p option.
Also, check for aliases that might include options you don't want.