Improve error message when wrong --update option is given.
This commit is contained in:
parent
1746711680
commit
cbfbcb0b50
|
@ -14,6 +14,7 @@ Changes Prior to this release
|
|||
- When --assemble --scan is run, if all arrays that could be found
|
||||
have already been started, don't report an error.
|
||||
- Fix a couple of bugs related to raid10 and the new 'offset' layout.
|
||||
- Improve error message when a wrong '--update' option is given.
|
||||
|
||||
Changes Prior to 2.5.4 release
|
||||
- When creating devices in /dev/md/ create matching symlinks
|
||||
|
|
4
ReadMe.c
4
ReadMe.c
|
@ -272,7 +272,7 @@ char OptionHelp[] =
|
|||
" --config= -c : config file\n"
|
||||
" --scan -s : scan config file for missing information\n"
|
||||
" --force -f : Assemble the array even if some superblocks appear out-of-date\n"
|
||||
" --update= -U : Update superblock: one of sparc2.2, super-minor or summaries\n"
|
||||
" --update= -U : Update superblock: try '-A --update=?' for list of options.\n"
|
||||
" --auto(=p) -a : Automatically allocate new (partitioned) md array if needed.\n"
|
||||
" --no-degraded : Do not start any degraded arrays - default unless --scan.\n"
|
||||
"\n"
|
||||
|
@ -414,7 +414,7 @@ char Help_assemble[] =
|
|||
" for a full array are present\n"
|
||||
" --force -f : Assemble the array even if some superblocks appear\n"
|
||||
" : out-of-date. This involves modifying the superblocks.\n"
|
||||
" --update= -U : Update superblock: one of sparc2.2, super-minor or summaries\n"
|
||||
" --update= -U : Update superblock: try '-A --update=?' for option list.\n"
|
||||
" --no-degraded : Assemble but do not start degraded arrays.\n"
|
||||
;
|
||||
|
||||
|
|
8
mdadm.c
8
mdadm.c
|
@ -596,7 +596,13 @@ int main(int argc, char *argv[])
|
|||
|
||||
continue;
|
||||
}
|
||||
fprintf(stderr, Name ": '--update %s' invalid. Only 'sparc2.2', 'super-minor', 'uuid', 'resync' or 'summaries' supported\n",update);
|
||||
if (strcmp(update,"?") == 0 || strcmp(update, "help") == 0)
|
||||
fprintf(stderr, Name ": ");
|
||||
else
|
||||
fprintf(stderr, Name ": '--update=%s' is invalid. ", update);
|
||||
fprintf(stderr, "Valid --update options are:\n"
|
||||
" 'sparc2.2', 'super-minor', 'uuid', 'name', 'resync',\n"
|
||||
" 'summaries', 'homehost', 'byteorder'.\n");
|
||||
exit(2);
|
||||
|
||||
case O(ASSEMBLE,NoDegraded): /* --no-degraded */
|
||||
|
|
Loading…
Reference in New Issue