0%

There is a whitepaper on the UBIFS page, and LWN wrote about it in the LogFS article.
The on-flash tree looks much like the structure used by ext2. There are some differences in how it is managed, however. The log structure of the filesystem implies that blocks cannot be rewritten in place; any time a block is changed it must be moved and written to a new location. If there are pointers to the moved block (think about the usual indirect blocks used to store the layout of larger files), the blocks containing the pointers must also be changed, and thus moved. That, in turn, will require changes at the next level up in the tree. Thus changes at the bottom of the tree will propagate upward all the way to the root. This is the “wandering tree” algorithm. One of the advantages is that the old filesystem structure remains valid until the root is rewritten - a crash could cause the loss of the last operation, but it will leave previous data and the structure of the filesystem intact.
Actually managing the entire directory tree as a wandering tree would be expensive; beyond that, files with multiple hard links break the tree structure and make wandering trees much harder to implement. So the actual tree implemented by LogFS just has two levels. There is an “inode file” containing the inode structures for every file and directory existing within the filesystem; each inode then points to the associated blocks holding the file’s data. Directory entries contain a simple integer index giving the inode offset within the inode file. So changes to an inode only require writing the inode itself and the inode file; the rest of the directory structure need not be touched.

fio是平时常用的工具之一,然而它有很多参数用于定制不同的压力模式,输出也包含很多信息,之前没有仔细研究。本文搞清楚一些常用参数所定制的行为,并且详细解读一下输出的信息。

阅读全文 »

最近看了下namazu,试图使用它来模拟filesystem以及ethernet的抖动以及错误,发现ethernet inspector使用的是netfilter queue;这里对它做一个简单的调研。

阅读全文 »

本文介绍抓包工具tcpdump在linux下的使用。Linux的tcpdump manual中包含许多选项以及复杂的filter表达式,我们工作中往往用不到这么多的选项和太复杂的filter。所以本文介绍一些常用的选项和filter规则,尽可能的通过一些例子来说明。

阅读全文 »