[sclug] performance puzzle

Alex Butcher lug at assursys.co.uk
Sat Jul 9 22:38:56 UTC 2005


On Sat, 9 Jul 2005, Tom Dawes-Gamble wrote:

> On Sat, 2005-07-09 at 13:27 +0100, Alex Butcher wrote:
>> On Sat, 9 Jul 2005, Tom Dawes-Gamble wrote:
>>> On Wed, 2005-01-19 at 22:57 +0000, Tom Dawes-Gamble wrote:
>>>> Why does foo perform so much better than bar or baz?
>>
>> In this case, I'd suggest that foo is stored in a faster or more-dense zone
>> of the disc. Is /mnt/tmp on a logical volume?
>
> Yes it is.

What does 'lvdisplay' say about the LV?

Note also, that conceivably, all bets are off as to which part of the disc
is used for which files once you use LVM. Modern discs have a significantly
higher data rate at the rim than the hub, due to there being a greater
number of physical blocks per track in the hubward cylinders and the disc
spinning at a constant angular velocity:

# hdparm -tT /dev/hde

/dev/hde:
  Timing cached reads:   1756 MB in  2.00 seconds = 877.26 MB/sec
  Timing buffered disk reads:  148 MB in  3.03 seconds =  48.92 MB/sec
# hdparm -tT /dev/hde9

/dev/hde9:
  Timing cached reads:   1788 MB in  2.00 seconds = 894.14 MB/sec
  Timing buffered disk reads:   68 MB in  3.02 seconds =  22.51 MB/sec
# fdisk -l /dev/hde

Disk /dev/hde: 200.0 GB, 200049647616 bytes
255 heads, 63 sectors/track, 24321 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes

    Device Boot      Start         End      Blocks   Id  System
/dev/hde1               1         499     4008186    c  W95 FAT32 (LBA)
/dev/hde2   *         500         761     2104515   83  Linux
/dev/hde3             762        1023     2104515   83  Linux
/dev/hde4            1024       24321   187141185    f  W95 Ext'd (LBA)
/dev/hde5            1024        3016    16008741    c  W95 FAT32 (LBA)
/dev/hde6            3017        5009    16008741   83  Linux
/dev/hde7            5010        8994    32009481   fd  Linux raid autodetect
/dev/hde8            8995        9238     1959898+  82  Linux swap
/dev/hde9            9239       24321   121154166   fd  Linux raid autodetect

I'm pretty sure this was the conclusion we came to the last time you raised
this issue and that you were surprised modern discs used zoned recording
techniques.

Something else I neglected to mention was ext3's mount options, including
the 'data=' option to set what is journalled, and the cache policy. It's
also possible to set the interval at which the journal is committed to disc
using the 'commit=' option. The VM 'Laptop mode' can achieve a similar
effect, but globally.

> Best regards,
> Tom.

Best Regards,
Alex.
-- 
Alex Butcher      Brainbench MVP for Internet Security: www.brainbench.com
Bristol, UK                      Need reliable and secure network systems?
PGP/GnuPG ID:0x271fd950                         <http://www.assursys.com/>


More information about the Sclug mailing list