Dan

Authored Comments

mv can rename file in its directory entry, or put the name in some other directory, or rename and place the name in some other directory. In either case, the inode number of the file does not change after the move, so data blocks of the file are not touched.

But if the target is on a different filesystem, mv will copy the data blocks to the new location, then remove the directory entry (name:inode pair ) from the original directory.

When a file is moved (mv), the modification time (mtime) remains the same, as file data has not changed (though it may have been copied to a different filesystem).

In either case, you should see an updated ctime (change time), because file metadata (the name) has changed.

E.g.

mountpoint -q /srv && rsync /var/some/path /srv/some/other/path

Run rsync only if directory /srv is in use as a mount point.