inode query..

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi All,
I have a doubt here .. I have created a file and noted its inode number and then edited the file with vi, I am amused that inode entry got changed.
 
[root@linuxbox123 tennis]# touch test
[root@linuxbox123 tennis]# ls -il
total 0
131381 -rw-r--r--  1 root root 0 Mar  8 10:36 test
[root@linuxbox123 tennis]# vi test
[root@linuxbox123 tennis]# ls -il
total 4
131386 -rw-r--r--  1 root root 8 Mar  8 10:37 test
[root@linuxbox123 tennis]# cat test
test123
 
-------------------------------
[root@linuxbox123 tennis]# cat > test
Test123
 
[1]+  Stopped                 cat >test
[root@linuxbox123 tennis]# cat test
Test123
[root@linuxbox123 tennis]# ls -il
total 4
131386 -rw-r--r--  1 root root 8 Mar  8 11:25 test
[root@linuxbox123 tennis]#
--------------------------------
[root@linuxbox123 tennis]# vi test
[root@linuxbox123 tennis]# cat test
Test123
test123
[root@linuxbox123 tennis]# ls -il
total 4
131385 -rw-r--r--  1 root root 16 Mar  8 11:26 test
[root@linuxbox123 tennis]#
-----------------------------------
 
Now, I do not understand why this inode entries get changed with Vi but not cat , can any one please tell me why is it so..
 
thanks,
Nikhil
 
-- 
redhat-list mailing list
unsubscribe mailto:redhat-list-request@xxxxxxxxxx?subjecthttps://www.redhat.com/mailman/listinfo/redhat-list


[Index of Archives]     [CentOS]     [Kernel Development]     [PAM]     [Fedora Users]     [Red Hat Development]     [Big List of Linux Books]     [Linux Admin]     [Gimp]     [Asterisk PBX]     [Yosemite News]     [Red Hat Crash Utility]


  Powered by Linux