- Fix Monitor mode sometimes crashes when a resync completes - Fix missing symlink for mdadm container device when incremental creates the array - Make sure when creating a second array in a container that the second array uses all available space since leaving space for a third array is invalid - Validate the number of imsm volumes per controller - Fix issues with imsm arrays and disks larger than 2TB - Add support for expanding imsm arrays/containers - The support for expanding imsm arrays/containers was accepted upstream, update to the official patches from there - Fix for the issue of --add not being very smart - Fix an issue causing rebuilds to fail to restart on reboot (data corrupter level problem) - Reset the bad flag on map file updates - Correctly fix failure when trying to add internal bitmap to 1.0 arrays - Resolves: bz817023 (f17) bz817024 (f17) bz817026 (f17) bz817028 (f17) - Resolves: bz817029 (f17) bz817032 (f17) bz817038 (f17) bz808774 (f17) - Resolves: bz817039 (f17) bz817042 (f17) Signed-off-by: Jes Sorensen <Jes.Sorensen@redhat.com>
		
			
				
	
	
		
			86 lines
		
	
	
		
			2.9 KiB
		
	
	
	
		
			Diff
		
	
	
	
	
	
			
		
		
	
	
			86 lines
		
	
	
		
			2.9 KiB
		
	
	
	
		
			Diff
		
	
	
	
	
	
| From 4aecb54a211a77aa0589aa2abb8acd992ae8795a Mon Sep 17 00:00:00 2001
 | |
| From: Adam Kwolek <adam.kwolek@intel.com>
 | |
| Date: Fri, 13 Apr 2012 16:52:08 +0200
 | |
| Subject: [PATCH 14/14] FIX: Assembled second array is in read only state
 | |
|  during reshape
 | |
| 
 | |
| When arrays using external metadata are assembled, and one of array
 | |
| in container is under reshape, second array will remain in read only
 | |
| state (not auto read only). It is caused by array fact that array
 | |
| is frozen and mdmon doesn't has opportunity to switch array in r/w mode.
 | |
| 
 | |
| Freezing not reshaped array just after it is being assembled allows mdmon
 | |
| to enable it for writing.
 | |
| 
 | |
| Signed-off-by: Adam Kwolek <adam.kwolek@intel.com>
 | |
| Signed-off-by: NeilBrown <neilb@suse.de>
 | |
| ---
 | |
|  Assemble.c |   29 +++++++++++++++++++++--------
 | |
|  1 files changed, 21 insertions(+), 8 deletions(-)
 | |
| 
 | |
| diff --git a/Assemble.c b/Assemble.c
 | |
| index 23695e7..080993d 100644
 | |
| --- a/Assemble.c
 | |
| +++ b/Assemble.c
 | |
| @@ -1558,6 +1558,7 @@ int assemble_container_content(struct supertype *st, int mdfd,
 | |
|  	int expansion = 0;
 | |
|  	struct map_ent *map = NULL;
 | |
|  	int old_raid_disks;
 | |
| +	int start_reshape;
 | |
|  
 | |
|  	sysfs_init(content, mdfd, 0);
 | |
|  
 | |
| @@ -1569,7 +1570,17 @@ int assemble_container_content(struct supertype *st, int mdfd,
 | |
|  			return 1;
 | |
|  		}
 | |
|  
 | |
| -	if (st->ss->external && content->recovery_blocked)
 | |
| +	/* There are two types of reshape: container wide or sub-array specific
 | |
| +	 * Check if metadata requests blocking container wide reshapes
 | |
| +	 */
 | |
| +	start_reshape = (content->reshape_active &&
 | |
| +		!((content->reshape_active == CONTAINER_RESHAPE) &&
 | |
| +		(content->array.state & (1<<MD_SB_BLOCK_CONTAINER_RESHAPE))));
 | |
| +
 | |
| +	/* Block subarray here if it is under reshape now
 | |
| +	 * Do not allow for any changes in this array
 | |
| +	 */
 | |
| +	if (st->ss->external && content->recovery_blocked && start_reshape)
 | |
|  		block_subarray(content);
 | |
|  
 | |
|  	if (sra)
 | |
| @@ -1595,14 +1606,7 @@ int assemble_container_content(struct supertype *st, int mdfd,
 | |
|  		 (working + preexist + expansion) >=
 | |
|  			content->array.working_disks) {
 | |
|  		int err;
 | |
| -		int start_reshape;
 | |
|  
 | |
| -		/* There are two types of reshape: container wide or sub-array specific
 | |
| -		 * Check if metadata requests blocking container wide reshapes
 | |
| -		 */
 | |
| -		start_reshape = (content->reshape_active &&
 | |
| -				 !((content->reshape_active == CONTAINER_RESHAPE) &&
 | |
| -				   (content->array.state & (1<<MD_SB_BLOCK_CONTAINER_RESHAPE))));
 | |
|  		if (start_reshape) {
 | |
|  			int spare = content->array.raid_disks + expansion;
 | |
|  			if (restore_backup(st, content,
 | |
| @@ -1646,6 +1650,15 @@ int assemble_container_content(struct supertype *st, int mdfd,
 | |
|  		}
 | |
|  		if (!err)
 | |
|  			sysfs_set_safemode(content, content->safe_mode_delay);
 | |
| +
 | |
| +		/* Block subarray here if it is not reshaped now
 | |
| +		 * It has be blocked a little later to allow mdmon to switch in
 | |
| +		 * in to R/W state
 | |
| +		 */
 | |
| +		if (st->ss->external && content->recovery_blocked &&
 | |
| +		    !start_reshape)
 | |
| +			block_subarray(content);
 | |
| +
 | |
|  		if (verbose >= 0) {
 | |
|  			if (err)
 | |
|  				fprintf(stderr, Name
 | |
| -- 
 | |
| 1.7.7.6
 | |
| 
 |