Origin [Posts] the Unix directory structure

The origins of Unix directory structure

Author:  Ruan Yifeng

Date:  2012 February 6

Unix (includes Linux) beginner, often very confused, do not understand the meaning of what directory structure.

For example, there is a subdirectory of the root directory / bin, for storing binary program. However, / usr subdirectory there is / usr / bin, and / usr / local / bin, but also for storing binary program; some systems even / opt / bin. What's the difference between them?

For a long time, and I am very hard to understand, do not understand why this design. Like most people, I'm just based on "Unix file system structure Standard" (Filesystem Hierarchy Standard), rote different directories difference.

Yesterday, I read Rob Landley of brief explanation , suddenly realized that the Unix directory structure is history.

Saying 1969, Ken Thompson and Dennis Ritchie on a PDP-7 minicomputer invented Unix. In 1971, they will host upgrade to the PDP-11.

At that time, they used a technique called RK05 storage disk, a capacity is about 1.5MB.

没过多久,操作系统(根目录)变得越来越大,一块盘已经装不下了。于是,他们加上了第二盘RK05,并且规定第一块盘专门放系统程序,第二块盘专门放用户自己的程序,因此挂载的目录点取名为/usr。也就是说,根目录"/"挂载在第一块盘,"/usr"目录挂载在第二块盘。除此之外,两块盘的目录结构完全相同,第一块盘的目录(/bin, /sbin, /lib, /tmp...)都在/usr目录下重新出现一次。

后来,第二块盘也满了,他们只好又加了第三盘RK05,挂载的目录点取名为/home,并且规定/usr用于存放用户的程序,/home用于存放用户的数据。

从此,这种目录结构就延续了下来。随着硬盘容量越来越大,各个目录的含义进一步得到明确。

  /:存放系统程序,也就是At&t开发的Unix程序。

  /usr:存放Unix系统商(比如IBM和HP)开发的程序。

  /usr/local:存放用户自己安装的程序。

  /opt:在某些系统,用于存放第三方厂商开发的程序,所以取名为option,意为"选装"。

(完)

Guess you like

Origin www.cnblogs.com/jinanxiaolaohu/p/12322192.html