Le jeudi 07 décembre 2006 à 15:03 +0100, Volker Sameske a écrit : > On IBM System z we often have the problem that we have attached > several hundred devices. In case we want to use only a few of them > with mp-tools, we have to blacklist all others. For that reason I have > introduced a blacklist_exception keyword for the multipath.conf which > fills an internal exception list. > > Additionally this patch adds two commands to the multipathd cli to > display blacklist rules and blacklisted devices. > > ------------------- snip -------------------- > blacklist { > devnode "^(ram|raw|loop|fd|md|dm-|sr|scd|st)[0-9]*" > devnode "^hd[a-z][[0-9]*]" > devnode "^cciss!c[0-9]d[0-9]*[p[0-9]*]" > devnode "^dasd[a-z]+[0-9]*" > } > blacklist_exceptions { > devnode "^dasd[c-d]+[0-9]*" > } ... > multipathd> show blacklist > device node rules: > - blacklist: > (config file rule) ^(ram|raw|loop|fd|md|dm-|sr|scd|st)[0-9]* > (config file rule) ^hd[a-z][[0-9]*] > (config file rule) ^cciss!c[0-9]d[0-9]*[p[0-9]*] > (config file rule) ^dasd[a-z]+[0-9]* > (default rule) ^(ram|raw|loop|fd|md|dm-|sr|scd|st)[0-9]* > (default rule) ^hd[a-z] > (default rule) ^cciss!c[0-9]d[0-9]* > - exceptions: > (config file rule) ^dasd[c-d]+[0-9]* > wwid rules: > - blacklist: > <empty> > - exceptions: > <empty> > device rules: > - blacklist: > (default rule) DGC:LUNZ > multipathd> > > multipathd> show devices > available block devices: > dasda (blacklisted) > dasdb (blacklisted) > dasdc > dasdd > dm-0 (blacklisted) ... > > ------------------- snap -------------------- > Hello, I merged the latest version of your patch. Minor mangling : I had to rename your snprint_blacklist() rewrite to snprint_blacklist_report() because the "show config" CLI command purpose is to dump a config file in sync with the daemon actual configuration. Your stealing the snprint_blacklist() fn name made for your blacklist "report" to be included in this dump in place of the correct "blacklist {}" block. I also implemented the missing snprint_blacklist_exceptions() for config dump completeness. Please verify everything is still working for you. Thanks for this nicely crafted work. Regards, cvaroqui -- dm-devel mailing list dm-devel@xxxxxxxxxx https://www.redhat.com/mailman/listinfo/dm-devel