bitmap questions
Hi,
I have a question on how bitmap works and what's shown in /proc/mdstat, for example:
md2 : active raid10 sdc3[0] sdd3[3] sdb3[2] sda3[1]
60002560 blocks 64K chunks 2 near-copies [4/4] [UUUU]
bitmap: 1/1 pages [4KB], 65536KB chunk- 1 bitmap for 4096 chunks
- if it shows 0/1 pages [0KB] what does it actually mean? Does that mean that in case of resync it will resync _all_ 4096 chunks in that page or only chunks that require that (for example 7 chunks) ?
- if it will resync all 4096 chunks what's the point of even allowing 1 page setup (via mdadm)?
Thanks!
Signature · 10 lines
Arkadiusz Miśkiewicz PLD/Linux Team arekm / maven.pl http://ftp.pld-linux.org/ -- Arkadiusz Miśkiewicz PLD/Linux Team arekm / maven.pl http://ftp.pld-linux.org/ -- 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
Quoted 10 lines · Arkadiusz Miskiewicz
I have a question on how bitmap works and what's shown in
/proc/mdstat, for example:md2 : active raid10 sdc3[0] sdd3[3] sdb3[2] sda3[1] 60002560 blocks 64K chunks 2 near-copies [4/4] [UUUU]
bitmap: 1/1 pages [4KB], 65536KB chunk- 1 bitmap for 4096 chunks
- if it shows 0/1 pages [0KB] what does it actually mean?
If it's 0 pages then no resync.
I assume you mean 1/1 ?
Quoted 3 lines
Does that mean that
in case of resync it will resync _all_ 4096 chunks in that page or only chunks that require that (for example 7 chunks) ?
It only resyncs what is dirty. A page dirty in the in-memory bitmap does not mean ALL bits are dirty, just that the page is allocated.
--
Paul
--
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
Quoted 10 lines · Paul Clements
On Wed, Oct 13, 2010 at 12:24 PM, Arkadiusz Miskiewicz
Quoted 7 lines · <[email protected]> wrote:
I have a question on how bitmap works and what's shown in
/proc/mdstat, for example:md2 : active raid10 sdc3[0] sdd3[3] sdb3[2] sda3[1]
60002560 blocks 64K chunks 2 near-copies [4/4] [UUUU] bitmap: 1/1 pages [4KB], 65536KB chunk
Quoted 6 lines
Quoted 3 lines
- 1 bitmap for 4096 chunks
- if it shows 0/1 pages [0KB] what does it actually mean?
If it's 0 pages then no resync.
I assume you mean 1/1 ?
Ok, I thought differently since it's bitmap->pages - bitmap->missing_pages (thought that missing_pages == dirty one).
Quoted 6 lines
Quoted 3 lines
Does that mean that
in case of resync it will resync _all_ 4096 chunks in that page or only chunks that require that (for example 7 chunks) ?It only resyncs what is dirty. A page dirty in the in-memory bitmap does not mean ALL bits are dirty, just that the page is allocated.
So there is no way to know in advance how much is going to be resynced when sudden reset would happen in that moment?
Anyway good to know that 1 page setup also makes sense :)
Quoted 2 lines
--
Paul
Signature · 6 lines
Arkadiusz Miśkiewicz PLD/Linux Team arekm / maven.pl http://ftp.pld-linux.org/ -- 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
On 14/10/2010 07:00, Arkadiusz Miskiewicz wrote:
[...]
Quoted 2 lines
So there is no way to know in advance how much is going to be resynced when sudden reset would happen in that moment?
Only in the general sense that there's a limit to how many chunks could have been dirtied in whatever period your kernel will hang on to stuff before insisting on flushing it. I think that defaults to 5 seconds, so you'd have to have a pathological workload to dirty so many chunks the resync might take more than a minute.
Cheers,
John.
Quoted 2 lines · Arkadiusz Miskiewicz
So there is no way to know in advance how much is going to be resynced when sudden reset would happen in that moment?
mdadm -X /dev/component-device
regards
Mario
Signature · 1 line
To err is human. To really foul things up requires a computer.