2.6内核改变系统IO调度算法
2.6内核的四种调度算法 In the 2.6 kernel series,there are four interchangeable schedulers,as follows: cfq- “Completely Fair Queuing” makes a good default for most workloads on general-purpose servers.? as – “Anticipatory Scheduler” is best for workstations and other systems with slow,single-spindle storage. deadline – “Deadline” is a relatively simple scheduler which tries to minimize I/O latency by re-ordering requests to improve performance. Deadline的I/O调度器,在数据吞吐量非常大的数据库系统中表现得更有优势。 noop- “NOOP” is the most simple scheduler of all,and is really just a single FIFO queue. 修改默认的IO调度算法 There are two ways to change the I/O scheduler – at boot time,or with new kernels at runtime. For all Linux kernels,appending ‘elevator={noop|deadline}’ to the kernel boot string sets the I/O elevator. With GRUB,append the string to the end of the kernel command: title Fedora Core (2.6.9-5.0.3.EL_lustre.1.4.2custom) With newer Linux kernels (Red Hat Enterprise Linux v3 Update 3 does not have this feature. It is present in the main Linux tree as of 2.6.15),one can change the scheduler while running. If the file /sys/block/<DEVICE>/queue/scheduler exists (where DEVICE is the block device you wish to affect),it will contain a list of available schedulers and can be used to switch the schedulers. (sda is the <disk>): [root@cfs2]# cat /sys/block/sda/queue/scheduler The other schedulers (anticipatory and cfq) are better suited for desktop use. 查看当前的IO调度算法 dmesg | grep -i schedular 英文信息copy from lustre manual (编辑:李大同) 【声明】本站内容均来自网络,其相关言论仅代表作者个人观点,不代表本站立场。若无意侵犯到您的权利,请及时与联系站长删除相关内容! |