I am trying to understand what it happens to a file when I move it from a directory to another, inside the same File System.
Here is the example I made up.
I have two directories and a file :
Here I have some details about the file
784088 -rw-r--r-- 1 myUser myUser 0 Oct 25 02:18 fileName.txt
Then, I moved the file
dir2 by issuing the following command:
~/Documents/dir1$ mv fileName.txt ../dir2
and here I have the details about the file
ls -li) after having issued
784088 -rw-r--r-- 1 myUser myUser 0 Oct 25 02:22 fileName.txt
What I expected was a change of inode number, but I was wrong . So, for what I have understood up to now, by moving a file inside the same File System:
- the data block is not touched (that's good to me)
- the inode (that is strange to me)
Can anyone tell me then what it changes in file properties (apart from modification time)?
Thank you in advance, really.