Skip to contentSkip to conversation

read-balancing not working in 2.6?

DISCUSSION Per Andreas Buer 4 participants 6 messages Nov 29, 2004 – Nov 30, 2004 MD RAID

lore
Share & tools
lore
#0 lore raw

Hi.

We have a busy mailserver with the mail-spool on MD (raid1, consisting of sda and sdb, ext3 w/data=journal noatime nodiratime, 2.6.6, Debian Woody). The read-balancing does not seem to work properly.

Output from "iostat -x /dev/sda /dev/sdb 1" (edited for readability) shows the following:

Device:    rrqm/s wrqm/s   r/s   w/s  rsec/s  wsec/s    rkB/s    wkB/s avgrq-sz avgqu-sz   await  svctm  %util
sda          4.00   1.00 217.00  8.00 2472.00   88.00  1236.00    44.00    11.38   147.22  706.14   4.45 100.10

sdb 0.00 0.00 0.00 11.00 0.00 88.00 0.00 44.00 8.00 0.03 2.27 1.73 1.90

sda          0.00   0.00 220.00  8.00 2792.00   80.00  1396.00    40.00    12.60   146.62  604.96   4.39 100.10
sdb          0.00   0.00  0.00  9.00    0.00   72.00     0.00    36.00     8.00     0.01    1.33   1.11   1.00
sda          1.98   0.00 236.63  0.00 2637.62    0.00  1318.81     0.00    11.15   146.99  571.04   4.19  99.11
sdb          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 248.00  0.00 2216.00    0.00  1108.00     0.00     8.94   112.44  582.19   4.04 100.20
sdb          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          2.97 186.14 223.76 10.89 2249.50 1702.97  1124.75   851.49    16.84    50.87  404.61   4.22  99.11
sdb          0.00 182.18  0.00 19.80    0.00 1710.89     0.00   855.45    86.40     1.77   33.80   5.65  11.19

sda 1.02 231.63 114.29 65.31 1869.39 2644.90 934.69 1322.45 25.14 52.77 197.21 5.69 102.14
sdb 0.00 231.63 0.00 81.63 16.33 2628.57 8.16 1314.29 32.40 17.96 137.01 4.75 38.78

sda          1.96   7.84 143.14 60.78 2368.63  172.55  1184.31    86.27    12.46    81.49  287.92   4.81  98.14
sdb          0.00   7.84  5.88 41.18   54.90  180.39    27.45    90.20     5.00     2.83  221.85   8.15  38.33

Why is sda getting all the IO?

Signature · 6 lines
Per Andreas Buer
Linpro AS / Ledende på Linux i Norge
-
To unsubscribe from this list: send the line "unsubscribe linux-raid" in
the body of a message to [email protected]
More majordomo info at  http://vger.kernel.org/majordomo-info.html
#1 lore raw
Quoted 6 lines · On Monday November 29, [email protected] wrote:

Hi.

We have a busy mailserver with the mail-spool on MD (raid1, consisting of sda and sdb, ext3 w/data=journal noatime nodiratime, 2.6.6, Debian Woody). The read-balancing does not seem to work properly.

The array wasn't resyncing at the time was it?
I ask partly because resyncing substantially reduces the opportunities for read-balance (it will only read balance parts of the array that are known to be in-sync) and partly because the amount of read traffic to sdb seems to start picking up at the end of your log.

If you can confirm that it wasn't resyncing, I will look into it.

Thanks,
NeilBrown

author
#2 lore raw
Quoted 1 line · Neil Brown

The array wasn't resyncing at the time was it?

I can confirm that the array was not resyncing. Running the same iostat as yesterday I now see that the reads are properly balanced. However, the IO load is a tenth of what it was yesterday. So it looks to me like the read-balancing somehow broke down yesterday - probably due to high pressure.

I've attached a graph of the IO activity in this period (taken from Munin). As writes (on top side) are written to both sda and sdb only the latter shows. On the bottom side of the graph you can see that reads from sda totally dominate.

Signature · 1 line
Per Andreas Buer
#3 lore raw
In reply to Neil Brown
Quoted 8 lines · Neil Brown
Quoted 6 lines · On Monday November 29, [email protected] wrote:

Hi.

We have a busy mailserver with the mail-spool on MD (raid1, consisting of sda and sdb, ext3 w/data=journal noatime nodiratime, 2.6.6, Debian Woody). The read-balancing does not seem to work properly.

Quoted 7 lines

The array wasn't resyncing at the time was it?
I ask partly because resyncing substantially reduces the opportunities for read-balance (it will only read balance parts of the array that are known to be in-sync) and partly because the amount of read traffic to sdb seems to start picking up at the end of your log.

If you can confirm that it wasn't resyncing, I will look into it.

You already did that in June :) It's a known bug in 2.6.6

http://marc.theaimsgroup.com/?t=108686719100002&r=1&w=2
http://marc.theaimsgroup.com/?l=linux-raid&m=108725741411235&w=2

Mike.

#4 lore raw
Quoted 9 lines · On Tuesday November 30, [email protected] wrote:
Quoted 2 lines

If you can confirm that it wasn't resyncing, I will look into it.

You already did that in June :) It's a known bug in 2.6.6

http://marc.theaimsgroup.com/?t=108686719100002&r=1&w=2
http://marc.theaimsgroup.com/?l=linux-raid&m=108725741411235&w=2

Mike.

Oh yes, so I did.. Thanks for the reminder. I hadn't noticed that it was such an old kernel...

I love it when a problem turns out already to be fixed :-)

thanks again
NeilBrown

#5 lore raw
In reply to Per Andreas Buer
Quoted 7 lines · Per Andreas Buer

Hi.

We have a busy mailserver with the mail-spool on MD (raid1, consisting of sda and sdb, ext3 w/data=journal noatime nodiratime, 2.6.6, Debian Woody). The read-balancing does not seem to work properly.

I had a quick look on one of my systemes, it does work there:

avg-cpu:  %user   %nice    %sys %iowait   %idle
           1.45    0.00    8.65   14.25   75.65
Device:    rrqm/s wrqm/s   r/s   w/s  rsec/s  wsec/s    rkB/s    wkB/s avgrq-sz avgqu-sz   await  svctm  %util
sda          0.00 1010.18 41.92 14.97  335.33 8207.58   167.66  4103.79   150.18     1.93   33.94   3.10  17.62
sdd          0.00 1006.39 42.91 18.96  343.31 8207.58   171.66  4103.79   138.19     2.46   39.73   2.92  18.04
avg-cpu:  %user   %nice    %sys %iowait   %idle
           0.90    0.00    4.45   23.86   70.79
Device:    rrqm/s wrqm/s   r/s   w/s  rsec/s  wsec/s    rkB/s    wkB/s avgrq-sz avgqu-sz   await  svctm  %util
sda          0.00 554.09 94.21 11.58  753.69 4526.95   376.85  2263.47    49.92     1.29   12.18   1.80  19.02
sdd          0.00 547.50 96.01 18.16  768.06 4526.95   384.03  2263.47    46.38     2.11   18.46   1.79  20.48
avg-cpu:  %user   %nice    %sys %iowait   %idle
           0.85    0.00    3.45    4.25   91.45
Device:    rrqm/s wrqm/s   r/s   w/s  rsec/s  wsec/s    rkB/s    wkB/s avgrq-sz avgqu-sz   await  svctm  %util
sda          0.00  34.80 15.40  2.60  123.20  299.20    61.60   149.60    23.47     0.04    2.06   1.91   3.44
sdd          0.00  34.60 16.20  2.80  129.60  299.20    64.80   149.60    22.57     0.05    2.56   1.98   3.76

This is with 2.6.10-rc2-bk12.

Holger