FAQ Search Today's Posts Mark Forums Read
» Video Reviews

» Linux Archive

Linux-archive is a website aiming to archive linux email lists and to make them easily accessible for linux users/developers.


» Sponsor

» Partners

» Sponsor

Go Back   Linux Archive > Gentoo > Gentoo User

 
 
LinkBack Thread Tools
 
Old 09-30-2010, 01:10 PM
Florian Philipp
 
Default Normal disk speed?

Am Donnerstag 30 September 2010, 12:58:36 schrieb Adam Carter:
> Taring my mp3 collection from 2.5in 500MB internal sata drive (sda) to
> esata 3.5in 500MB drive (sdb) and it seems slow. In vmstat i can see that
> the external drive writes faster than the internal can read (external has
> periods of inactivity)
[...]
> So 21221MB in 610 seconds = 35 MB/s
>
> # hdparm -t /dev/sda
>
> /dev/sda:
> Timing buffered disk reads: 220 MB in 3.01 seconds = 73.14 MB/sec (77
> with --direct)
[...]
> So the should i expect filesystem (reiser3) and other overhead to cut the
> read performance to less than half of what hdparm reports? Anything else i
> can look at to speed it up? Im using CFQ io scheduler.

35 MB/s is a pretty normal value for a 5400 RPM laptop HDD.

An HDD gets slower when you read the inner tracks. The angular velocity is
constant (5400 RPM) while the tangential velocity gets lower with the radius.

Inner tracks are mapped to the sectors at the far end of the partition table.
That's why you should always put swap and system partitions at the front of
your partition table and use its end for bulk data.

I guess your mp3 collection is stored somewhere at the middle or end of your
internal disk (inner tracks) while your external disk is nearly empty and
therefore stores data on the outer tracks.

Hope this helps.
Florian Philipp
 
Old 09-30-2010, 01:26 PM
James
 
Default Normal disk speed?

Adam Carter <adamcarter3 <at> gmail.com> writes:


> Taring my mp3 collection from 2.5in 500MB internal sata drive
> (sda) to esata 3.5in 500MB drive (sdb) and it seems slow.


Well, there are multiple avenues to nail down your specific issues,
most documented or hinted at in the archives of this list.....

Here is some fuel for thought, on a higher plain:
http://en.wikipedia.org/wiki/Btrfs
http://en.wikipedia.org/wiki/B-tree

So you have at least (2) issues.

1. Your specific hardware
http://www.coker.com.au/bonnie++/
bonnie is also in portage
[eix bonnie]

2. The longer view of increasing
file system performance, particularly
in a distributed resources environment:

(CEPHGS, GlusterFS, BTRFS, others?) is the subject
of a hot debate, probably overdue for the devs
or the brilliant, on this list, to update
us commoners? (here goes another religious war!)

hth,
James
 
Old 09-30-2010, 04:00 PM
Peter Humphrey
 
Default Normal disk speed?

On Thursday 30 September 2010 14:10:42 Florian Philipp wrote:

> An HDD gets slower when you read the inner tracks. The angular
> velocity is constant (5400 RPM) while the tangential velocity gets
> lower with the radius.

Are you telling us that the length of a stored bit is constant? I'd have
thought it was the time needed to read or write a bit that was constant;
otherwise the electronics would get extremely complex. In that case it's
the angular velocity that counts, not the linear velocity, and it
matters not which track your data are on. (If a block goes past the head
twice as fast, it also occupies twice the space, so you're back where
you were.)

That's the way it was with our imposing new 2MB disks in 1974, anyway.
They occupied boxes four feet tall and six feet long, and had external
air systems; I was one of those responsible for the maintenance; we were
sent on a training course specifically for the disks. I can't remember
who made them, but they were part of a Ferranti Argus 500 system at the
then national grid control centre.

Maybe technology has changed since then.

--
Rgds
Peter. Linux Counter 5290, 1994-04-23.
 
Old 09-30-2010, 04:12 PM
Nikos Chantziaras
 
Default Normal disk speed?

On 09/30/2010 07:00 PM, Peter Humphrey wrote:

On Thursday 30 September 2010 14:10:42 Florian Philipp wrote:


An HDD gets slower when you read the inner tracks. The angular
velocity is constant (5400 RPM) while the tangential velocity gets
lower with the radius.


Are you telling us that the length of a stored bit is constant? I'd have
thought it was the time needed to read or write a bit that was constant;
otherwise the electronics would get extremely complex. In that case it's
the angular velocity that counts, not the linear velocity, and it
matters not which track your data are on. (If a block goes past the head
twice as fast, it also occupies twice the space, so you're back where
you were.)


Uhm, no. The higher the linear velocity, the higher the read/write
speed. This can be proven with any disk benchmark that can bench the
whole disk. You get a graph that begins low and ends high (and the
difference between inner and outer region is substantial, almost 2:1).
 
Old 09-30-2010, 04:50 PM
Florian Philipp
 
Default Normal disk speed?

Am 30.09.2010 18:00, schrieb Peter Humphrey:
> On Thursday 30 September 2010 14:10:42 Florian Philipp wrote:
>
>> An HDD gets slower when you read the inner tracks. The angular
>> velocity is constant (5400 RPM) while the tangential velocity gets
>> lower with the radius.
>
> Are you telling us that the length of a stored bit is constant? I'd have
> thought it was the time needed to read or write a bit that was constant;
> otherwise the electronics would get extremely complex. In that case it's
> the angular velocity that counts, not the linear velocity, and it
> matters not which track your data are on. (If a block goes past the head
> twice as fast, it also occupies twice the space, so you're back where
> you were.)

Yes, the length of a block is constant. If the innermost "ring" (track)
contains 4 blocks, the next ring contains maybe 5 blocks.[1]

Put another way: If you could pack your bits more densely on innermost
tracks, why wouldn't you pack them that densely on the whole disk and
thereby increase the overall capacity?

>
> That's the way it was with our imposing new 2MB disks in 1974, anyway.
> They occupied boxes four feet tall and six feet long, and had external
> air systems; I was one of those responsible for the maintenance; we were
> sent on a training course specifically for the disks. I can't remember
> who made them, but they were part of a Ferranti Argus 500 system at the
> then national grid control centre.
>
> Maybe technology has changed since then.
>

Well, we are talking about devices employing the GMR effect while also
doing error correction and remapping of defect sectors on-the-fly. I
guess a little lookup table from track number to time-per-block doesn't
add too much complexity.

You can easily test this if you have various partitions on your HDD.
Just compare dd throughput for your first partition versus your last one.

[1] The numbers are arbitrary. The number increases linearly. C = 2*pi*r
 
Old 09-30-2010, 04:53 PM
Volker Armin Hemmann
 
Default Normal disk speed?

On Thursday 30 September 2010, Adam Carter wrote:
> Taring my mp3 collection from 2.5in 500MB internal sata drive (sda) to
> esata 3.5in 500MB drive (sdb) and it seems slow. In vmstat i can see that
> the external drive writes faster than the internal can read (external has
> periods of inactivity)
> # time tar cf /mnt/usbdrive/mp3back.tar mp3/
>
> real 10m9.679s
> user 0m1.577s
> sys 2m1.769s
> # du -ks mp3/
> 21221661 mp3/
>
> So 21221MB in 610 seconds = 35 MB/s
>
> # hdparm -t /dev/sda
>
> /dev/sda:
> Timing buffered disk reads: 220 MB in 3.01 seconds = 73.14 MB/sec (77
> with --direct)
>
> FWIW;
> # hdparm /dev/sda
>
> /dev/sda:
> multcount = 16 (on)
> IO_support = 1 (32-bit)
> readonly = 0 (off)
> readahead = 256 (on)
> geometry = 60801/255/63, sectors = 976773168, start = 0
>
>
> So the should i expect filesystem (reiser3) and other overhead to cut the
> read performance to less than half of what hdparm reports? Anything else i
> can look at to speed it up? Im using CFQ io scheduler.

as soon as your harddisk seeks you are lucky to be above 5mb/sec. Yes, even
with a modern harddrive. Just look up the seek times and do the math.

Your harddisk seeks, everything is slow.
 
Old 09-30-2010, 09:43 PM
Peter Humphrey
 
Default Normal disk speed?

On Thursday 30 September 2010 17:50:41 Florian Philipp wrote:
> Am 30.09.2010 18:00, schrieb Peter Humphrey:
> > On Thursday 30 September 2010 14:10:42 Florian Philipp wrote:
> >> An HDD gets slower when you read the inner tracks. The angular
> >> velocity is constant (5400 RPM) while the tangential velocity gets
> >> lower with the radius.
> >
> > Are you telling us that the length of a stored bit is constant? I'd
> > have thought it was the time needed to read or write a bit that
> > was constant; otherwise the electronics would get extremely
> > complex. In that case it's the angular velocity that counts, not
> > the linear velocity, and it matters not which track your data are
> > on. (If a block goes past the head twice as fast, it also occupies
> > twice the space, so you're back where you were.)
>
> Yes, the length of a block is constant. If the innermost "ring"
> (track) contains 4 blocks, the next ring contains maybe 5 blocks.[1]
>
> Put another way: If you could pack your bits more densely on
> innermost tracks, why wouldn't you pack them that densely on the
> whole disk and thereby increase the overall capacity?
>
> > That's the way it was with our imposing new 2MB disks in 1974,
> > anyway. They occupied boxes four feet tall and six feet long, and
> > had external air systems; I was one of those responsible for the
> > maintenance; we were sent on a training course specifically for
> > the disks. I can't remember who made them, but they were part of a
> > Ferranti Argus 500 system at the then national grid control
> > centre.
> >
> > Maybe technology has changed since then.
>
> Well, we are talking about devices employing the GMR effect while
> also doing error correction and remapping of defect sectors
> on-the-fly. I guess a little lookup table from track number to
> time-per-block doesn't add too much complexity.
>
> You can easily test this if you have various partitions on your HDD.
> Just compare dd throughput for your first partition versus your last
> one.

Seems like technology has moved on. Well, it has had 35 years or more.

--
Rgds
Peter. Linux Counter 5290, 1994-04-23.
 
Old 10-01-2010, 01:12 AM
Adam Carter
 
Default Normal disk speed?

Your harddisk seeks, everything is slow.



So does that then mean that my options are;
1. Defragment, so there is less seeking
2. Get an SSD

Since 2 is too expensive for a decent size drive, is there anything i can do about 1 without a backup and restore operation? Or will the fragmentation be very small on reiser3 anyway (i mount with notail) so I should just accept things as they are.
 
Old 10-01-2010, 04:41 AM
Volker Armin Hemmann
 
Default Normal disk speed?

On Friday 01 October 2010, Adam Carter wrote:
> > Your harddisk seeks, everything is slow.
> >
> > So does that then mean that my options are;
>
> 1. Defragment, so there is less seeking
> 2. Get an SSD
>
> Since 2 is too expensive for a decent size drive, is there anything i can
> do about 1 without a backup and restore operation? Or will the
> fragmentation be very small on reiser3 anyway (i mount with notail) so I
> should just accept things as they are.

every fs fragments over the course of time. Some more, some less. So as long
as you have harddisks:
get used to the seeking penalty.
 
Old 10-01-2010, 08:42 AM
Florian Philipp
 
Default Normal disk speed?

Am 01.10.2010 03:12, schrieb Adam Carter:
> Your harddisk seeks, everything is slow.
>
> So does that then mean that my options are;
> 1. Defragment, so there is less seeking
> 2. Get an SSD
>
> Since 2 is too expensive for a decent size drive, is there anything i
> can do about 1 without a backup and restore operation? Or will the
> fragmentation be very small on reiser3 anyway (i mount with notail) so I
> should just accept things as they are.

To prevent fragmentation, try to always keep a decent amount of free
space on each partition. That way, the FS driver can allocate space for
new files without too much fragmentation (a fragment every 2 MB or so
doesn't really hurt performance).

If you had enough free space on your partition when you created the
mp3-files there, I don't think fragmentation is an issue here. The files
likely never grew in size which would cause fragmentation.

Of course, the situation changes again when the free space on your file
system was already heavily fragmented even if there was enough of it. It
all depends on your usage pattern of that disk to make an educated guess
if that is true.

The good thing about hard disks is that you can usually hear whether
they are seeking or reading sequentially. If you hear a lot of seeking
on sequential operations, it is time to reformat the partition or at
least erase and recreate the affected files.

Hope this helps,
Florian Philipp
 

Thread Tools




All times are GMT. The time now is 12:30 AM.

VBulletin, Copyright ©2000 - 2014, Jelsoft Enterprises Ltd.
Content Relevant URLs by vBSEO ©2007, Crawlability, Inc.
Copyright 2007 - 2008, www.linux-archive.org