Jump to content

HDD speed very slow


MichaGue

Recommended Posts

Hi all,

 

I run a BPi with Armbian 4.2 - kernel 4.2.2. A WD Red 3TB is connected via sata. I have tested hdd performance which seems to be very slow (for my opinion).

Auto Mode
        Using Minimum Record Size 512 KB
        Using Maximum Record Size 8192 KB
        File size set to 2048000 KB
        Using maximum file size of 2048000 kilobytes.
        Command line used: iozone -a -y 512k -q 1024K -s 2000m -g 2000m -i 0 -i1
        Output is in Kbytes/sec
        Time Resolution = 0.000001 seconds.
        Processor cache size set to 1024 Kbytes.
        Processor cache line size set to 32 bytes.
        File stride size set to 17 * record size.
      
              KB  reclen   write rewrite    read    reread    
         2048000     512   10097   10482    20809    21397
         2048000    1024   10570    9597    20533    20977

What could be the problem?

 

Best regards,

Michael

 

 

Link to comment
Share on other sites

What have you used to test the performance?

 

Hm, I do not understand your question because I think the answer is written in my question:

 

- Armbian 4.2.2 wheezy

- BananaPi

- iozone -a -y 512k -q 1024K -s 2000m -g 2000m -i 0 -i1

- WD Red 3TB, connected to SATA on BananaPi

- HDD format is EXT4

 

Which information do you miss? Thanks a lot.

Link to comment
Share on other sites

I was connect via putty to the banana pi and started iozone through putty (connection 1Gig Ethernet). But this should not matter, because the iozone test runs internally on the banana pi, no transfer to the connected system.

Link to comment
Share on other sites

Sorry. I didn't read it carefully.

 

I've got a 1 TB WD Red connected to SATA on Olimex Lime 2 board. I also power the hard drive by the board, and I have these performances.

        Auto Mode
        Using Minimum Record Size 512 kB
        Using Maximum Record Size 1024 kB
        File size set to 2048000 kB
        Using maximum file size of 2048000 kilobytes.
        Command line used: iozone -a -y 512k -q 1024K -s 2000m -g 2000m -i 0 -i1
        Output is in kBytes/sec
        Time Resolution = 0.000001 seconds.
        Processor cache size set to 1024 kBytes.
        Processor cache line size set to 32 bytes.
        File stride size set to 17 * record size.

              kB  reclen    write  rewrite    read    reread
         2048000     512    42515    42898   102635   102532
         2048000    1024    41915    41868   102489   102507
Link to comment
Share on other sites

Hi PaceyIV,

 

thank you for your reply. So yout get 4x the write and 5x the reading speed of my measurement. I think there must be something wrong in my system. Does anyone has an idea what the problem could be?

 

Thanks a lot and best regards,

Michael

Link to comment
Share on other sites

One thing to mention: iozone does its tests in the current working directory (should be obvious but while troubleshooting sometimes the most basic steps are easy to miss). So ensure you change into a dir that is on your disk before otherwise you might end up testing the SD card.

 

Then I would always run in another terminal "iostat 5" while testing (since it prints both I/O stuff -- per device so you know you're testing the right one -- as well as CPU utilisation and on Linux also %iowait percentage). And with mainline kernel and the right cpufreq settings (always use performance for tests) the A20 is able to exceed 40/200 MB/s (SATA write/read).

Link to comment
Share on other sites

One thing to mention: iozone does its tests in the current working directory ...

 

Shame on me - using the right working directory results in ...

              KB  reclen   write rewrite    read    reread
           32768     512  160596  297245   480645   482294
           32768    1024  161545  298827   494379   492901
           65536     512  160969  297935   499969   501899
           65536    1024  159870  290379   490795   492425
          131072     512   86015  103228   499439   502047
          131072    1024   91007  104062   495939   497062
          262144     512   54405   56703   498674   500277
          262144    1024   54576   57630   494419   498526
          524288     512   46027   45875   496817   498723
          524288    1024   45277   46087   497868   499793
         1048576     512   41372   42090   138739   140698
         1048576    1024   41677   42307   138568   142234
         2048000     512   39911   40169   138249   140220
         2048000    1024   39789   39804   135877   137287

That looks much better.

Link to comment
Share on other sites

Shame on me - using the right working directory results in ...

              KB  reclen   write rewrite    read    reread
           32768     512  160596  297245   480645   482294
           32768    1024  161545  298827   494379   492901
...
         2048000     512   39911   40169   138249   140220
         2048000    1024   39789   39804   135877   137287

That looks much better.

 

And it shows clearly why testing with files smaller than the system's amount of available RAM is useless: Since then mostly buffers/caches were tested.  :)

 

I would test with the 3 settings mentioned here http://linux-sunxi.org/USB/UAS#Testing_3_different_external_enclosuresagain and see how the SATA disk behaves.

Link to comment
Share on other sites

I would test with the 3 settings mentioned here http://linux-sunxi.org/USB/UAS#Testing_3_different_external_enclosuresagain and see how the SATA disk behaves.

 

So, I did the tests mentioned in the above link. First part is always the result from iozone, the second part is a snapshot of iostat for each iozone test.

-----------------------------------------------
1.) iozone -a -g 4000m -s 4000m -i 0 -i 1 -r 4K
-----------------------------------------------

        Auto Mode
        Using maximum file size of 4096000 kilobytes.
        File size set to 4096000 KB
        Record Size 4 KB
        Command line used: iozone -a -g 4000m -s 4000m -i 0 -i 1 -r 4K
        Output is in Kbytes/sec
        Time Resolution = 0.000001 seconds.
        Processor cache size set to 1024 Kbytes.
        Processor cache line size set to 32 bytes.
        File stride size set to 17 * record size.
                                                            random  random    bkwd   record   stride
              KB  reclen   write rewrite    read    reread    read   write    read  rewrite     read   fwrite frewrite   fread  freread
         4096000       4   38842   38897   140696   140965

================

avg-cpu:  %user   %nice %system %iowait  %steal   %idle
           0,24    0,00    3,17   49,12    0,00   47,47

Device:         rrqm/s   wrqm/s     r/s     w/s    rMB/s    wMB/s avgrq-sz avgqu-sz   await r_await w_await  svctm  %util
mmcblk0           0,00     0,00    0,00    0,40     0,00     0,00     8,00     0,00    5,00    0,00    5,00   5,00   0,20
sda               0,00    57,80    0,00    4,80     0,00    38,20 16300,33     6,49 1352,08    0,00 1352,08 208,33 100,00

avg-cpu:  %user   %nice %system %iowait  %steal   %idle
           1,11    0,00   35,22   21,82    0,00   41,86

Device:         rrqm/s   wrqm/s     r/s     w/s    rMB/s    wMB/s avgrq-sz avgqu-sz   await r_await w_await  svctm  %util
mmcblk0           0,00     0,00    0,00    0,00     0,00     0,00     0,00     0,00    0,00    0,00    0,00   0,00   0,00
sda               0,00     0,00 1125,20    0,00   140,65     0,00   256,00     1,51    1,35    1,35    0,00   0,89  99,80

--------------------------------------------------
2.) iozone -a -g 4000m -s 4000m -i 0 -i 1 -r 1024K
--------------------------------------------------

        Auto Mode
        Using maximum file size of 4096000 kilobytes.
        File size set to 4096000 KB
        Record Size 1024 KB
        Command line used: iozone -a -g 4000m -s 4000m -i 0 -i 1 -r 1024K
        Output is in Kbytes/sec
        Time Resolution = 0.000001 seconds.
        Processor cache size set to 1024 Kbytes.
        Processor cache line size set to 32 bytes.
        File stride size set to 17 * record size.
                                                            random  random    bkwd   record   stride
              KB  reclen   write rewrite    read    reread    read   write    read  rewrite     read   fwrite frewrite   fread  freread
         4096000    1024   38224   38411   135551   141479

===============

avg-cpu:  %user   %nice %system %iowait  %steal   %idle
           0,47    0,00    4,44   43,22    0,00   51,87

Device:         rrqm/s   wrqm/s     r/s     w/s    rMB/s    wMB/s avgrq-sz avgqu-sz   await r_await w_await  svctm  %util
mmcblk0           0,00     0,00    0,00    0,20     0,00     0,00     8,00     0,00   20,00    0,00   20,00  20,00   0,40
sda               0,00    99,20    0,00    4,60     0,00    37,16 16542,61     7,34 1468,70    0,00 1468,70 217,39 100,00

avg-cpu:  %user   %nice %system %iowait  %steal   %idle
           0,75    0,00   45,52    5,54    0,00   48,19

Device:         rrqm/s   wrqm/s     r/s     w/s    rMB/s    wMB/s avgrq-sz avgqu-sz   await r_await w_await  svctm  %util
mmcblk0           0,00     0,00    0,00    0,00     0,00     0,00     0,00     0,00    0,00    0,00    0,00   0,00   0,00
sda               0,00     0,00 1113,00    0,00   139,12     0,00   256,00     1,23    1,14    1,14    0,00   0,88  98,40
--------------------------------------------------
3.) iozone -O -i 0 -i 1 -i 2 -e -+n -r 4K -s 2000m
--------------------------------------------------

        OPS Mode. Output is in operations per second.
        Include fsync in write timing
        No retest option selected
        Record Size 4 KB
        File size set to 2048000 KB
        Command line used: iozone -O -i 0 -i 1 -i 2 -e -+n -r 4K -s 2000m
        Time Resolution = 0.000001 seconds.
        Processor cache size set to 1024 Kbytes.
        Processor cache line size set to 32 bytes.
        File stride size set to 17 * record size.
                                                            random  random    bkwd   record   stride
              KB  reclen   write rewrite    read    reread    read   write    read  rewrite     read   fwrite frewrite   fread  freread
         2048000       4    9442       0    34933        0     134    1652

==============

avg-cpu:  %user   %nice %system %iowait  %steal   %idle
           0,12    0,00    4,22   45,78    0,00   49,88

Device:         rrqm/s   wrqm/s     r/s     w/s    rMB/s    wMB/s avgrq-sz avgqu-sz   await r_await w_await  svctm  %util
mmcblk0           0,00     0,00    0,00    0,00     0,00     0,00     0,00     0,00    0,00    0,00    0,00   0,00   0,00
sda               0,00    96,20    0,00    4,80     0,00    37,55 16023,00     7,69 1568,33    0,00 1568,33 208,33 100,00

avg-cpu:  %user   %nice %system %iowait  %steal   %idle
           1,42    0,00   34,39   22,34    0,00   41,84

Device:         rrqm/s   wrqm/s     r/s     w/s    rMB/s    wMB/s avgrq-sz avgqu-sz   await r_await w_await  svctm  %util
mmcblk0           0,00     0,00    0,00    0,00     0,00     0,00     0,00     0,00    0,00    0,00    0,00   0,00   0,00
sda               0,00     0,00 1102,60    0,00   137,80     0,00   255,95     1,51    1,38    1,38    0,00   0,91 100,00

avg-cpu:  %user   %nice %system %iowait  %steal   %idle
           0,20    0,00    0,70   48,04    0,00   51,06

Device:         rrqm/s   wrqm/s     r/s     w/s    rMB/s    wMB/s avgrq-sz avgqu-sz   await r_await w_await  svctm  %util
mmcblk0           0,00     0,00    0,00    0,20     0,00     0,00     8,00     0,00    0,00    0,00    0,00   0,00   0,00
sda               0,00     0,00  144,60    0,00     0,56     0,00     8,00     1,00    6,89    6,89    0,00   6,89  99,60

avg-cpu:  %user   %nice %system %iowait  %steal   %idle
           0,00    0,00    2,23   83,42    0,00   14,35

Device:         rrqm/s   wrqm/s     r/s     w/s    rMB/s    wMB/s avgrq-sz avgqu-sz   await r_await w_await  svctm  %util
mmcblk0           0,00     0,00    0,00    0,20     0,00     0,00     8,00     0,00    0,00    0,00    0,00   0,00   0,00
sda               0,00     0,40    0,00 1644,00     0,00     7,28     9,07   143,48   87,66    0,00   87,66   0,61 100,00

For the third test I wonder why the random read is so slow. Much slower than random write. Any ideas?

 

Thanks a lot.

Michael

Link to comment
Share on other sites

Guest
This topic is now closed to further replies.
×
×
  • Create New...

Important Information

Terms of Use - Privacy Policy - Guidelines