My view on the relationship between Linux directory and file

Source: Internet
Author: User


my view on the file system access of Linux

Learning Linux , influenced by the previous habit of using Windows , often confuses the concept of Linux files.

Today, I carefully combed the relationship between the Linux directory and the file.

Linux file systems are different from windows, and all directories and files are derived from the/ root directory.

The management of a file is managed by a unique inode number that is distributed uniformly by the system .

Linux , Everything is a file,/ directory is no exception, is also a file, the content of the file is logically in/ directory under the directory and the meta-information of the file [ include Inode node, file name, size, permissions, owner, etc.]

As shown, after ls views the file list, the following results are obtained

650) this.width=650; "src=" Http://s3.51cto.com/wyfs02/M00/38/78/wKiom1Oz2UaTql_aAAMpEvgu83U193.jpg "title=" Picture 1.png "alt=" Wkiom1oz2uatql_aaampevgu83u193.jpg "/>

Here, you can think of Linux files that contain only the contents of the file, that is, its data information, not including the meta-information of the file.

Its meta-information is in the data information of the directory that contains it.

For the sake of understanding, I drew a picture to show its relationship .

650) this.width=650; "src=" Http://s3.51cto.com/wyfs02/M02/38/78/wKioL1Oz2S_CYA6GAAgG73Z9ufw857.jpg "title=" Picture 2.png "alt=" Wkiol1oz2s_cya6gaagg73z9ufw857.jpg "/>

I hope my understanding will be helpful to the people who read this article.


This article is from the "909 is a goal" blog, please be sure to keep this source http://robert1joy.blog.51cto.com/4489523/1433661

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.