ANNOUNCE: mdadm 2.6.2 - A tool for managing Soft RAID under Linux
I am pleased to announce the availability of
mdadm version 2.6.2
It is available at the usual places:
http://www.cse.unsw.edu.au/~neilb/source/mdadm/
and
countrycode=xx.
http://www.${countrycode}kernel.org/pub/linux/utils/raid/mdadm/
and via git at
git://neil.brown.name/mdadm
http://neil.brown.name/git?p=mdadm
mdadm is a tool for creating, managing and monitoring device arrays using the "md" driver in Linux, also known as Software RAID arrays.
Release 2.6.2 adds a few minor bug fixes to 2.6.1
Changelog Entries:
- --fail detached and --remove faulty can be used to fail and
remove devices that are no longer physically present.
- --export option for --detail or present information in a format
that can be processed by udev.
- fix internal bitmap allocation problems with v1.1, v1.2 metadata.
- --help now goes to stdout so you can direct it to a pager.
- Various manpage updates.
- Make "--grow --add" for linear arrays really work.
- --auto-detect to trigger in-kernel autodetect.
- Make return code for "--detail --test" more reliable. Missing
devices as well as failed devices cause an error.
Development of mdadm is sponsored by
SUSE Labs, Novell Inc.
NeilBrown 21st May 2007
Hello Neil,
Quoted 2 lines · you
I am pleased to announce the availability of
mdadm version 2.6.2
Thanks for releasing mdadm 2.6.2. It contains a fix for "--test" I was looking for right at the moment :-)
mdadm fails to compile if you enable "-O2" using gcc 4.1.1 because of -Werror:
cc1: warnings being treated as errorssysfs.c: In function 'sysfs_read':
sysfs.c:97: warning: value computed is not used
sysfs.c:119: warning: value computed is not used
sysfs.c:127: warning: value computed is not used
sysfs.c:133: warning: value computed is not used
sysfs.c:139: warning: value computed is not used
sysfs.c:178: warning: value computed is not used
Cheers,
Thomas
Quoted 11 lines · On Tuesday May 29, [email protected] wrote:
Hello Neil,
Quoted 2 lines · you
I am pleased to announce the availability of
mdadm version 2.6.2Thanks for releasing mdadm 2.6.2. It contains a fix for "--test" I was looking for right at the moment :-)
mdadm fails to compile if you enable "-O2" using gcc 4.1.1 because of -Werror:
Quoted 8 lines
cc1: warnings being treated as errors
sysfs.c: In function 'sysfs_read':
sysfs.c:97: warning: value computed is not used
sysfs.c:119: warning: value computed is not used
sysfs.c:127: warning: value computed is not used
sysfs.c:133: warning: value computed is not used
sysfs.c:139: warning: value computed is not used
sysfs.c:178: warning: value computed is not used
Those are bogus warnings. Each is
strcpy(base, "xxxxx");
and base most certainly is used., though I can see how gcc might not notice if it is being too clever. Maybe you need to get gcc-4.1.2? or
make CWFLAGS=-Wall
Thanks for the report.
NeilBrown
Quoted 21 lines · Neil Brown
Quoted 11 lines · On Tuesday May 29, [email protected] wrote:
Hello Neil,
Quoted 2 lines · you
I am pleased to announce the availability of
mdadm version 2.6.2Thanks for releasing mdadm 2.6.2. It contains a fix for "--test" I was looking for right at the moment :-)
mdadm fails to compile if you enable "-O2" using gcc 4.1.1 because of -Werror:
Quoted 8 lines
cc1: warnings being treated as errors
sysfs.c: In function 'sysfs_read':
sysfs.c:97: warning: value computed is not used
sysfs.c:119: warning: value computed is not used
sysfs.c:127: warning: value computed is not used
sysfs.c:133: warning: value computed is not used
sysfs.c:139: warning: value computed is not used
sysfs.c:178: warning: value computed is not used
Quoted 7 lines
Those are bogus warnings. Each is
strcpy(base, "xxxxx");and base most certainly is used., though I can see how gcc might not notice if it is being too clever. Maybe you need to get gcc-4.1.2? or
make CWFLAGS=-Wall
Maybe the compiler warns about the return of strcpy() not being used. The correct fix would then be:
(void)strcpy(base, "xxxxx");
Holger
Neil,
Quoted 9 lines · you
Quoted 8 lines
cc1: warnings being treated as errors
sysfs.c: In function 'sysfs_read':
sysfs.c:97: warning: value computed is not used sysfs.c:119: warning: value computed is not used sysfs.c:127: warning: value computed is not used sysfs.c:133: warning: value computed is not used sysfs.c:139: warning: value computed is not used sysfs.c:178: warning: value computed is not used
Quoted 6 lines
Those are bogus warnings. Each is
strcpy(base, "xxxxx");and base most certainly is used., though I can see how gcc might not notice if it is being too clever. Maybe you need to get gcc-4.1.2? or
make CWFLAGS=-Wall
Holger Kiehl was right, it complained about the unused return value. Please see the attached patch.
Thomas
Detail.c +1 -1
@@ -59,7 +59,7 @@ int Detail(char *dev, int brief, int expvoid *super =NULL ;int rv = test ?4 :1 ;int avail_disks =0 ; -char *avail; +char *avail =NULL ;if (fd <0 ) { fprintf(stderr, Name ": cannot open %s: %s\n",
sysfs.c +8 -8
@@ -94,7 +94,7 @@ struct sysarray *sysfs_read(int fd, int sra->devs =NULL ;if (options &GET_VERSION ) { -strcpy (base,"metadata_version" ); + (void )strcpy (base,"metadata_version" );if (load_sys (fname, buf)) goto abort;if (strncmp (buf,"none" ,4 ) ==0 )
@@ -104,19 +104,19 @@ struct sysarray *sysfs_read(int fd, int &sra->major_version, &sra->minor_version); }if (options &GET_LEVEL ) { -strcpy (base,"level" ); + (void )strcpy (base,"level" );if (load_sys (fname, buf)) goto abort; sra->level =map_name (pers, buf); }if (options &GET_LAYOUT ) { -strcpy (base,"layout" ); + (void )strcpy (base,"layout" );if (load_sys (fname, buf)) goto abort; sra->layout =strtoul (buf,NULL ,0 ); }if (options &GET_COMPONENT ) { -strcpy (base,"component_size" ); + (void )strcpy (base,"component_size" );if (load_sys (fname, buf)) goto abort; sra->component_size =strtoull (buf,NULL ,0 );
@@ -124,19 +124,19 @@ struct sysarray *sysfs_read(int fd, int sra->component_size *=2 ; }if (options &GET_CHUNK ) { -strcpy (base,"chunk_size" ); + (void )strcpy (base,"chunk_size" );if (load_sys (fname, buf)) goto abort; sra->chunk =strtoul (buf,NULL ,0 ); }if (options &GET_CACHE ) { -strcpy (base,"stripe_cache_size" ); + (void )strcpy (base,"stripe_cache_size" );if (load_sys (fname, buf)) goto abort; sra->cache_size =strtoul (buf,NULL ,0 ); }if (options &GET_MISMATCH ) { -strcpy (base,"mismatch_cnt" ); + (void )strcpy (base,"mismatch_cnt" );if (load_sys (fname, buf)) goto abort; sra->mismatch_cnt =strtoul (buf,NULL ,0 );
@@ -175,7 +175,7 @@ struct sysarray *sysfs_read(int fd, int dev->role =strtoul (buf, &ep,10 );if (*ep) dev->role =-1 ; -strcpy (dbase,"block/dev" ); + (void )strcpy (dbase,"block/dev" );if (load_sys (fname, buf)) goto abort;sscanf (buf,"%d:%d" , &dev->major, &dev->minor);