I've never heard this before, any links or references?
Printable View
What I'm curious about is some watt/power use comparison benchmarks.
I've been using deadline on my laptop for a while, as I've noticed less power use. TBH, I don't know if it actually gives me better battery life or it's just me thinking it does.
Bellow, some of my readings
http://en.wikipedia.org/wiki/Noop_scheduler
http://grzen.blogspot.fr/2009/05/ssd...-linux_18.html
http://ubuntuforums.org/showthread.php?t=1178209
According to Wikipedia :
- " NOOP scheduler is best used with solid state devices such as flash memory or in general with devices that do not depend on mechanical movement ... "
- Deadline: " The kernel documentation suggest this is the preferred scheduler for database systems ... "
In Kernel doc /usr/src/linux/Documentation/block/cfq-iosched.txt says :
" That means by default we idle on queues/service trees. This can be very helpful on highly seeky media like single spindle SATA/SAS disks ... "
I'm looking for a way to specify the kernel which respective scheduler to use with SSD & HDD, using boot command such as : elevator-DEVICE=<scheduler> rather than dealing with /sys/block/DEVICE/queue/scheduler (which happens after boot, ie. rc.local)
With elevator=scheduler where scheduler is noop Or deadline Or cfq
In my Wiki, I post my Syslinux boot config file, check line #47
If you are using Grub, it looks like this in the /boot/grub/menu.lst file
Code:title Arch Linux
kernel /boot/vmlinuz-linux root=/dev/sdb2 ro vga=0xf01 rootdelay=0 quiet nomodeset elevator=deadline nmi_watchdog=0
initrd /boot/initramfs-linux.img
I suggest using PowerTOP v2 and check the main reasons of kernel wakeups
http://en.wikipedia.org/wiki/PowerTOP
I just got a new Sandisk extreme and I don't see these problems. Instead I now have the satisfying feeling of very rarely having to wait for my hard disk (biggest problem was the access time for many little files I think).
Not really sure if I got it correctly aligned though, we really need a simple tool for that doesn't use these legacy cylinders and sector sizes and a consistent terminology to describe SSDs...
This is with noop.Code:% sudo parted /dev/sda --list
Passwort:
Modell: ATA SanDisk SDSSDX24 (scsi)
Festplatte /dev/sda: 240GB
Sektorgröße (logisch/physisch): 512B/512B
Partitionstabelle: msdos
Disk Flags:
Nummer Anfang Ende Größe Typ Dateisystem Flags
1 1049kB 215GB 215GB primary ext4 boot
% dd if=/dev/zero of=zero.txt bs=50M count=20
20+0 Datensätze ein
20+0 Datensätze aus
1048576000 Bytes (1,0 GB) kopiert, 2,72858 s, 384 MB/s
% dd if=zero.txt of=zero2.txt bs=50M count=20
20+0 Datensätze ein
20+0 Datensätze aus
1048576000 Bytes (1,0 GB) kopiert, 2,80263 s, 374 MB/s
If "Anfang" means first sector of partition ? 2049kB seems not aligned as not being a multiple of 512 (physical sector size)
One easy way is to partition with Windows Seven startup DVD which cares about SSD then back during Linux installation, change part type to Ext FS
However both fdisk and parted are today ready for SSD presenting the sector way rather than CHS
That's what I meant. What is a "physical sector" size in a SSD? :)
Would resizing the beginning of the partition to the correct "sector" be the right thing to do or do I have to recreate the whole partition (and/or table)?
Right, english is better:
I have read that 64 heads and 32 sectors align to 1 MiB EBS blocks (64 * 32 * 512 = 1048576 byte = 1 MiB) so I tried that. I did this because the original default alignment of util linux fdisk 2.20 seemed to be wrong but it's more probable I only thought it was wrong when it was in fact correct.Code:~ % sudo LC_ALL=C fdisk -u -l /dev/sda
Disk /dev/sda: 240.1 GB, 240057409536 bytes
64 heads, 32 sectors/track, 228936 cylinders, total 468862128 sectors
Units = sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk identifier: 0x1d172924
Device Boot Start End Blocks Id System
/dev/sda1 * 2048 419432447 209715200 83 Linux
% sudo LC_ALL=C parted --list
Model: ATA SanDisk SDSSDX24 (scsi)
Disk /dev/sda: 240GB
Sector size (logical/physical): 512B/512B
Partition Table: msdos
Disk Flags:
Number Start End Size Type File system Flags
1 1049kB 215GB 215GB primary ext4 boot
Hopefully 1049kB (not 2049) is actually 512 kbyte * 2.
But it doesn't matter that much since I don't have too much bandwidth on this notebook anyway (will get replaced in the not so far future):
Code:% sudo LC_ALL=C hdparm -t /dev/sda
/dev/sda:
Timing buffered disk reads: 776 MB in 3.00 seconds = 258.59 MB/sec
TYVM for the links, I didn't really come across anything sugesting that deadline or noop would result in less writes, and the reason I'm so curious is because I've seen suggestions that noop can actually increase the number of writes, because it doesn't delay writes to "group" them like deadline and especially cfq, meaning more smaller writes, possibly being less efficient on SSDs with relatively large write block sizes.
Don't have any links for this though, but it does kind of make sense to me...
Also, somewhat off topic, but I'm adding an SSD to my desktop and considering putting the journal for the SSD's ext4 filesystem on a partition at the very start of a hard disk in the system, should reduce writes somewhat, with hopefully not much of a performance impact, any thoughts?