The details about the permissions and modification times of a file are stored in inode. Three time are present for a file – last modification time, last used time and last inode changed time.

We gave a file name to a file to identify it. But the system uses a i-number to identify a file. The i-number is stored in the inode.

ls -i – lists the i-number of each file in decimal.

When we use od -d, used to print the representation of all bytes in a file, the first two bytes represent the i-number.

i-number is connection(link) between the file name contents.

The rm command just break the link. Only if all the links are broken the file content is removed from the system.

ln old-file new-file

makes a link to the existing file. Means, the same file can be accessed using two names. Even if one is removed using rm command, the file can be accessed by the other name.

The integer shown after the permission when we use ls -l command shows the number of links to the files

-rw-rw-rw- 2 you

When we use a cp command the i-number of the two files will be different. But when we use mv command, the i-number remains the same.


About Odol Shinu

I've completed my B Tech in Information Technology in 2010 from Government Engineering College Sreekrishnapuram Palakkad under Calicut University.

Posted on August 14, 2010, in GNU/Linux. Bookmark the permalink. Leave a comment.

Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out /  Change )

Google+ photo

You are commenting using your Google+ account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )


Connecting to %s

%d bloggers like this: