码迷,mamicode.com
首页 > 其他好文 > 详细

chattr

时间:2015-09-14 12:14:28      阅读:181      评论:0      收藏:0      [点我收藏+]

标签:

chattr

chattr

Table of Contents

chattr, lsattr

a    只能追加, 不能删除
A    不会修改 atime, 避免大量的磁盘 IO
c    数据压缩
C    will not be subject to copy-on-write updates
     写时复制(COW): 假如要复制一个文件, COW 那么他不会直接复制, 而是建立一条到原来数据的通道, 如果你只是读数据, 那么他会直接呈现给你
     知道你要写数据, 它才会自己开始修改自己的数据

     应用场景: lvm snapshot, 程序设计语言的引用计数, linux 的 fork (子进程也是 cow)
i    不可删除, 不可重命名, 不能被链接和修改数据
I    hashed trees 索引
j    all of its data written to the ext3 or ext4 journal before being  written  to the  file  itself

chattr +xxx FILE_NAME

相关阅读

chattr

标签:

原文地址:http://www.cnblogs.com/sunznx/p/4806618.html

(0)
(0)
   
举报
评论 一句话评论(0
登录后才能评论!
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!