|
Description
|
Metasync drops core if argument is not a metadevice name. E.g.
metasync db30
Produces this:
# metasync db30
Assertion failed: sp->setno == MD_MIN2SET(meta_getminor(np->dev)), file ../common/meta_resync.c, line 31
metasync: Abort
Abort - core dumped
Whereas the correct name:
# metasync d30
#
Causes no trouble. It seems any argument starting with "d" is accepted, decoded,
and if invalid causes this assertion failure and corefile.
It seems a correctly formed but non-existing metadevice name
or a name starting other than "d" elicits an error but
no corefile:
# metasync d0
metasync: coslab131: d0: No such file or directory
A single argument starting with a numeric gets a SIGSEGV:
# metasync 0
metasync: Segmentation Fault
Segmentation Fault - core dumped
I suspect we need more robust argument checking here. This may be made more difficult
by "friendly names" and perhaps was introduced with that feature.
|