博客
关于我
强烈建议你试试无所不能的chatGPT,快点击我
kswapd0 swap管理器,kjournald ext3日志进程,pdflush
阅读量:2353 次
发布时间:2019-05-10

本文共 1687 字,大约阅读时间需要 5 分钟。

原文:http://hi.baidu.com/dmkj2008/blog/item/a863231f0f284075f624e43a.html

1.kswapd0

Linux uses kswapd for virtual memory management such that pages that have been recently accessed are kept in memory and less active pages are paged out to disk.
(what is a page?)…Linux uses manages memory in units called pages.
So,the kswapd process regularly decreases the ages of unreferenced pages…and at the end they are paged out(moved out) to disk

系统每过一定时间就会唤醒kswapd,看看内存是否紧张,如果不紧张,则睡眠,kswapd中,有2个阀值,pages_higepages_low,当空闲内存页的数量低于pages_low的时候,kswapd进程就会扫描内存并且每次释放出32free pages,直到free page的数量到达pages_high.

2.kjournald

EXT3文件系统的日志进程,具有3种模式:

journal - logs all filesystem data and metadata changes. The slowest of the three ext3 journaling modes, this journaling mode minimizes the chance of losing the changes you have made to any file in an ext3 filesystem.(记录所有文件系统上的元数据改变,最慢的一种模式,)

ordered - only logs changes to filesystem metadata, but flushes file data updates to disk before making changes to associated filesystem metadata. This is the default ext3 journaling mode.(默认使用的模式,只记录文件系统改变的元数据,并在改变之前记录日志)

writeback - only logs changes to filesystem metadata but relies on the standard filesystem write process to write file data changes to disk. This is the fastest ext3 journaling mode.(最快的一种模式,同样只记录修改过的元数据,依赖标准文件系统写进程将数据写到硬盘)

修改模式EXT3的工作模式;

vim /etc/fstab

3.pdflush

pdflush用于将内存中的内容和文件系统进行同步,比如说,当一个文件在内存中进行修改,pdflush负责将它写回硬盘.每当内存中的垃圾页(dirty page)超过10%的时候,pdflush就会将这些页面备份回硬盘.这个比率是可调节的,通过/etc/sysctl.conf中的 vm.dirty_background_ratio项 默认值为10 也可以

cat /proc/sys/vm/dirty_background_ratio 查看当前的值

/dev/hda5 /opt ext3 data=writeback 1 0

详细介绍:
http://www.linuxplanet.com/linuxplanet/reports/4136/5/

转载地址:http://fsztb.baihongyu.com/

你可能感兴趣的文章
Drools Workbench 7.5.0.Final安装运行
查看>>
Docker快速部署Redis
查看>>
Spring boot shiro session cache ecache redis 共存配置
查看>>
一看就懂的设计模式--设计模式分类
查看>>
一看就懂的设计模式--模板方法
查看>>
一看就懂的设计模式--享元模式
查看>>
一看就懂的设计模式--策略模式
查看>>
spring Cloud 组建图
查看>>
腾讯云
查看>>
什么服务器比较好?
查看>>
阿里云+腾讯云采购季优惠攻略
查看>>
PCB设计容易出错的地方都有哪些?
查看>>
挠性电路板和刚性电路板的区别,以及柔性电路板焊接方法操作步骤
查看>>
如何做好一块PCB板,大神从以下几个方面做了论述
查看>>
学习笔记1之static
查看>>
学习笔记2之继承
查看>>
循环链表实现增、删、改、查等功能
查看>>
Android实现超链接和跑马灯
查看>>
实现二叉树先序、中序、后序遍历
查看>>
Socket客户端服务器连接
查看>>