文件系统
维库,知识与思想的自由文库
|
计算机的文件系统是一种存储和组织计算机文件和数据的方法,它使得对其访问和查找变得容易。文件系统通常使用硬盘和光盘这样的存储设备,并维护文件在设备中的物理位置。但是,实际上文件系统也可能仅仅是一种访问数据的界面而已,实际的数据是通过网络协议(如NFS、SMB、9P等)提供的或者内存上,甚至可能根本不存在对应的文件(如 proc文件系统)。 严格地说, 文件系统是一套实现了数据的存储、分级组织、访问和获取等操作的抽象数据类型。
[编辑] 文件系统概觀文件系统是一种用于向用户提供底层数据访问的机制。它将设备中的空间划分为特定大小的块(扇区),一般每块512字节。数据存储在这些块中,大小被修正为占用整数个块。由文件系统软件来负责将这些块组织为文件和目录,并记录哪些块被分配给了哪个文件,以及哪些块没有被使用。 Traditional file systems offer facilities to create, move and delete both files and directories. They lack facilities to create additional links to a directory (hard links in Unix), rename parent links (".." in Unix-like OS), and create bidirectional links to files. Traditional file systems also offer facilities to truncate, append to, create, move, delete and in-place modify files. They do not offer facilities to prepend to or truncate from the beginning of a file, let alone arbitrary insertion into or deletion from a file. The operations provided are highly asymmetric and lack the generality to be useful in unexpected contexts. For example, interprocess pipes in Unix have to be implemented outside of the file system because the pipes concept does not offer truncation from the beginning of files. Secure access to basic file system operations can be based on a scheme of access control lists or capabilities. Research has shown access control lists to be difficult to secure properly, which is why research operating systems tend to use capabilities. Commercial file systems still use access control lists. see: secure computing Arbitrary attributes can be associated on advanced file systems, such as XFS, ext2/ext3, some versions of UFS, and HFS+, using extended file attributes. This feature is implemented in the kernels of Linux, FreeBSD and Mac OS X operating systems, and allows metadata to be associated with the file at the file system level. This, for example, could be the author of a document, the character encoding of a plain-text document, or a checksum. [编辑] 文件系统的类型文件系统的类型可以分为磁盘文件系统、网络文件系统和特殊文件系统。 [编辑] 磁盘文件系统磁盘文件系统是一种设计用来利用数据存储设备来保存文件的文件系统,最常用的数据存储设备是磁盘驱动器,可以直接或者间接地连接到计算机上。例如:FAT、NTFS、HFS、HFS+、ext2、ext3、ISO 9660、ODS-5和UDF。 有些文件系统是 行程文件系统(也有译作日志文件系统)或者 追踪文件系统. [编辑] 数据库文件系统文件管理方面的一个新概念是一种基于数据库的文件系统的概念。不再(或者不仅仅)使用分层结构管理,文件按照他们的特征进行区分,如文件类型、专题、作者或者亚数据进行区分。于是文件检索就可以按照SQL风格甚至自然语言风格进行。 [编辑] 事务文件系统[编辑] 网络文件系统[编辑] 特殊用途的文件系统[编辑] 与操作系统的关系[编辑] 平面文件系统[编辑] UNIX及UNIX类操作系统下的文件系统[编辑] Mac OS X 的文件系统[编辑] Bell实验室的PLAN9文件系统[编辑] Microsoft Windows的文件系统[编辑] OpenVMS的文件系统OpenVMS為Wang Mainframe 所使用的Operation System,以搭配Wang王安博士發明的Magnetic Drum的儲存設備。 [编辑] IBM大型机 MVS的文件系统[编辑] 参见 |


