Skip to contentSkip to conversation

something about disk fragmentation

DISCUSSION jeff shia 4 participants 6 messages Jan 11, 2006 – Jan 16, 2006 1 message not in the archive Documentation

lore
Share & tools
lore

jeff shia

author
#0 lore raw

Hello,everyone

In a file system ,the disk fragmentation can slow down the data accessing
speed.How can I solve this kind of problem in a file system?I know that preallocation tech can do this.Is there any other solutions?
Thank you!

Yours
Jeff

#1 lore raw

2.6 kernel has 3 differen kind of io schedulers. Anticipatory io scheduler is the default one. You may try to select CFQ or deadline scheduler & see if that improves your performance. These schedulers have parameters which can be tuned also.

Regards
Ram Gupta

Quoted 15 lines · jeff shia

Hello,everyone

In a file system ,the disk fragmentation can slow down the data accessing
speed.How can I solve this kind of problem in a file system?I know that preallocation tech can do this.Is there any other solutions?
Thank you!

Yours
Jeff
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to [email protected]
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/

A message that is not in the archive (sent off-list or not yet received): [email protected]

#3 lore raw
Quoted 2 lines · jeff shia

Where Can I get the io schedulers?
Thank you!

See the documentation under the kernel source tree. The code is already there. You need only to select by passing correct kernel parameters.
elevator= [IOSCHED]
Format: {"as" | "cfq" | "deadline" | "noop"} See Documentation/block/as-iosched.txt and Documentation/block/deadline-iosched.txt for details.

Regards
Ram Gupta

#4 lore raw
Quoted 11 lines · Ram Gupta
Quoted 2 lines · jeff shia

Where Can I get the io schedulers?
Thank you!

See the documentation under the kernel source tree. The code is already there. You need only to select by passing correct kernel parameters.
elevator= [IOSCHED]
Format: {"as" | "cfq" | "deadline" | "noop"} See Documentation/block/as-iosched.txt and Documentation/block/deadline-iosched.txt for details.

It's much more convenient to do it dynamically (and saves you a reboot). Just do

# echo deadline > /sys/block/dev/queue/scheduler

to switch it at runtime, replace 'dev' with your hard drive name, eg hda or sda etc.

BTW, that option needs updating, you are supposed to use "anticipatory" for that scheduler (patch accepted :-).

Signature · 1 line
Jens Axboe
#5 lore raw

From: Randy Dunlap <[email protected]>

Update kernel-parameters.txt IOSCHED to spell out 'anticipatory'.

---
 Documentation/kernel-parameters.txt |    2 +-
 1 files changed, 1 insertion(+), 1 deletion(-)
Documentation/kernel-parameters.txt +1 -1
@@ -471,7 +471,7 @@ running once the system is up.
 			arch/i386/kernel/cpu/cpufreq/elanfreq.c.
 
 	elevator=	[IOSCHED]
-			Format: {"as" | "cfq" | "deadline" | "noop"}
+			Format: {"anticipatory" | "cfq" | "deadline" | "noop"}
 			See Documentation/block/as-iosched.txt and
 			Documentation/block/deadline-iosched.txt for details.
 

---