Does mv on a FAT filesystem actually rename or does it copy and delete?
Ralf Mardorf
silver.bullet at zoho.com
Sat Feb 3 15:46:15 UTC 2018
On Sat, 3 Feb 2018 12:29:10 +0000, Chris Green wrote:
>On Sat, Feb 03, 2018 at 09:50:31AM +0000, Chris Green wrote:
>> I want to rename some picture files on a mounted digital camera
>> filesystem. It is a VFAT filesystem.
>>
>> If I rename one of the files using 'mv <xxxx.yyy>' will the file
>
>Typo of course, I meant 'mv file1 file2'.
>
>> *actually* be renamed by changing the directory entry only or will
>> mv copy the file to one with the new name and then delete the old
>> one?
>Thanks for the answers so far but to re-emphasise why I asked the
>question:-
>
> I know that mv of a file in a directory on a Linux type filesystem
> will just write the new name of a file in the directory without
> moving the data/contents of the file.
>
> However in different circumstances (e.g. across filesystems) it
> *can't* do this and has to copy/delete. I was just asking if
> anyone knows if 'mv file1 file2' on a VFAT (i.e. not native Linux)
> filesystem does the 'easy' thing (copy/delete) or not.
As already pointed out, you still could run "strace" ;).
More information about the ubuntu-users
mailing list