12 2012 档案

linux-raid (二) faulty 和 multipath
摘要:源文件 linux/drivers/md/faulty.c linux/drivers/md/multipath.h linux/drivers/md/multipath.clinux-raid 之 faulty个人对它兴趣不大,这里简单记录一下介绍。faulty 模块实现了 fautly-device-simulator personality for md: The "faulty" module allows for a block device that occasionally returns read or write errors. It is useful 阅读全文

posted @ 2012-12-29 13:24 refrag 阅读(1802) 评论(0) 推荐(2)

linux-raid (一) md
摘要:源文件 linux/include/uapi/linux/raid/md_p.h linux/include/uapi/linux/raid/md_u.h linux/drivers/md/md.h linux/drivers/md/md.cmd 是 multiple devices 的缩写,实现了 MD RAID Framework。它将 RAID drivers 跟上层的 block layer 连接在一起,这样可以通过 block layer 访问到底层的 RAID drivers,比如 RAID1/RAID5 driver。同时它作为一个 RAID driver 之上的抽象层,... 阅读全文

posted @ 2012-12-27 23:32 refrag 阅读(6562) 评论(1) 推荐(2)

linux-raid (四) raid0
摘要:源文件 linux/src/drivers/md/raid0.h linux/src/drivers/md/raid0.c linux/src/drivers/md/md.h linux/src/drivers/md/md.cRAID 0 是将数据分散存放到不同磁盘上,比如有 8 个数据块大小的数据,同时有 2 块同样大小的磁盘,这 8 块数据会将 1,3,5,7 存放到第 1 块盘上,其他数据块存放到第 2 块磁盘上。如果两块盘大小不一样,则每块盘会使用最小磁盘大小的空间;最后单独使用余下盘上的空间。RAID 0 没有冗余,1 块盘坏掉,数据也就丢失了。mdadm --create ... 阅读全文

posted @ 2012-12-22 00:48 refrag 阅读(2494) 评论(0) 推荐(1)

linux-raid (三) linear mode
摘要:源文件 linux/drivers/md/md.h linux/drivers/md/md.c linux/drivers/md/linear.h linux/drivers/md/linear.clinear raid 是将一组盘组成一个虚拟的大磁盘,写的时候,先往一块盘上写,写满之后再写另一块盘。linear raid 没有纠错机制,坏掉一块盘,这个 raid 盘就坏掉了。写时的性能有可能会有提高,比如,写的数据分布在不同盘上。linear/raid0 不支持 spare disks,也不使用 bitmap;不支持 takeover。mdadm --create /dev/mdX ... 阅读全文

posted @ 2012-12-20 21:04 refrag 阅读(2908) 评论(0) 推荐(1)

开始接触 Pexpect
摘要:http://www.noah.org/wiki/pexpect最近有些时间,就想把一部分工作自动化掉,这部分工作很大一部分是需要处理交互的。一直没有看过 Expect,打算趁这个机会系统学习一下。个人一直喜欢用 Python,就想学习 Python 版本的 Expect —— Pexpect。一开始以为 Pexpect 就是在 Expect 基础上封装出来的接口,读了介绍性文档后发现自己想错了:Pexpect is pure Python. Unlike other Expect-like modules for Python Pexpect does not require TCL or 阅读全文

posted @ 2012-12-13 09:40 refrag 阅读(451) 评论(0) 推荐(0)

关于 Btrfs 中的 RAID1 —— 了解 btrfs 的 raid1
摘要:https://btrfs.wiki.kernel.org/index.php?title=FAQhttps://btrfs.wiki.kernel.org/index.php?title=SysadminGuidehttp://marc.info/?l=linux-btrfs&m=132575546926358&w=2邮件列表里面有个比较有意思的话题: Why does Btrfs allow raid1 with mismatched drives?把里面的讨论和 btrfs wiki 中关于 RAID1 的解释总结了一下: * 创建 mkfs.btrfs -m ra... 阅读全文

posted @ 2012-12-05 13:47 refrag 阅读(3959) 评论(1) 推荐(1)

关于 Btrfs 的一些概念和约定
摘要:https://btrfs.wiki.kernel.org/index.php/Data_Structures https://btrfs.wiki.kernel.org/index.php/File:References.pnghttps://btrfs.wiki.kernel.org/index.php/Treeshttps://btrfs.wiki.kernel.org/index.php/File:Directory-structure.pngBtrfs Terms https://btrfs.wiki.kernel.org/index.php/GlossaryDUP DUP... 阅读全文

posted @ 2012-12-03 11:09 refrag 阅读(1328) 评论(0) 推荐(0)

导航