learning linux (c) the system directory structure

After logging in the system, enter the command in the current command window:

 ls / 

You will see the following figure:

 

 Tree structure:

 

 

The following is an explanation of these directories:

  • / bin :
    bin Binary is the abbreviation This directory is the most frequently used commands.

  • / boot:
    Here are some of the core stored in files that are used when you start Linux, including some connection files and image files.

  • / dev:
    dev is Device (device) abbreviation is stored in the directory Linux external device, the access device in the manner of Linux and accessed files are the same.

  • / etc:
    This directory is used to store all of the systems management needs of configuration files and subdirectories.

  • / Home :
    the user's home directory, in Linux, each user has its own directory, the directory name is based on the general user account named.

  • / lib :
    this directory to store the system the most basic dynamic link shared libraries, its role is similar to Windows in the DLL file. Almost all applications need to use these shared libraries.

  • / Lost + found :
    Under normal circumstances this directory is empty, when the system illegal shutdown, some files stored here.

  • / Media :
    Linux system will automatically identify some devices, such as U disk, CD-ROM, etc., when the identification, linux identified device will mount this directory.

  • / mnt :
    The system provides this directory is to enable users to temporarily mount other file systems, we can drive mount / mnt /, and then enter the directory you can view the contents of the CD-ROM drive.

  • / opt :
     This is for the host to install additional software placed in the directory. For example, you install a ORACLE database you can put this directory. The default is empty.

  • / proc :
    This directory is a virtual directory, which is the system memory map, we can get system information directly access this directory through.
    Contents of this directory on your hard disk but not in memory, we can also directly modify certain files inside, such as the ping command can be shielded by the command of the host, so that others can not ping your machine:

    echo 1 > /proc/sys/net/ipv4/icmp_echo_ignore_all
  • / root :
    the directory for the system administrator, also known as super user's home directory permissions persons.

  • / sbin : S
    is the Super User's meaning here is stored in the system management program used by system administrators.

  • / selinux :
     This directory is Redhat / CentOS specific directory, Selinux is a security mechanism, similar to the windows firewall, but this mechanism is more complex, this directory is stored selinux related documents.

  • / SRV :
     the directory to store some data to be extracted after the service started.

  • /sys

     This is a core linux2.6 great changes. The directory of a file system sysfs 2.6 kernel emerging installation.

    sysfs file system integrates information on the following three kinds of file systems: for proc file system processes information for devfs file system devices and file systems for devpts pseudo terminal.

     

    The file system is a visual reflection of kernel device tree.

    When a kernel object is created, the corresponding files and directories are created kernel object subsystem.

  • / tmp :
    This directory is used to store temporary files.

  • / usr :
     This is a very important directory, many applications and user files are placed in this directory, similar to the program files directory under the windows.

  • / usr / bin:
    the application system users.

  • / usr / sbin:
    more advanced management programs and system daemons super users.

  • / usr / src:
    kernel source placement default directory.

  • / var :
    This directory contains a constantly expanding with something we were used to modify those directories are often placed in this directory. Including various log files.

  • / RUN :
    is an information since the temporary file system, storage system startup. When the system is restarted, the files in this directory should be deleted or cleared. If there is / var / run directory on your system, it should point to run.

In the Linux system, there are several directories is more important, usually need to be careful not to accidentally deleted or shuffle internal documents.

/ etc : top also mentioned, this is the system configuration file, if you change a file in the directory may cause the system will not boot.

/ bin, / sbin, / usr / bin, / usr / sbin : This is the system default directory to place executable file, such as ls is in / bin / ls directory under.

It is noteworthy that, / bin, / usr / bin system is for instruction (except the root pass the user) used by a user, and / sbin, / usr / sbin instruction is used to root.

/ var : This is a very important directory, a number of programs running on the system, each program will have a corresponding log is generated, and the log is recorded to this directory, particularly in / var / log 'directory, in addition pre-placement mail is also here.

Guess you like

Origin www.cnblogs.com/qingmuchuanqi48/p/12064598.html