On Wed, 25 Jan 2006, Andrew Beekhof wrote: > On 1/25/06, David Lee <[EMAIL PROTECTED]> wrote: > > BasicSanityCheck has never worked under Solaris: the sum of several issues > > each of which needs tackling one by one. I've done a few of those in > > recent weeks. But yet others remain. > > > > My next target is "findif". This works OK(-ish) in typical production > > mode, for which the address is typically on the local networks(s). But > > BSC's particular use of it is with a _remote_ address (10.253.252.251) > > which typically would be over a "default" route. > > > > For remote/default addresses the command "route -n get 10.253.252.251" > > on Solaris returns: > > destination: default > > mask: default > > (i.e. value is literally the string "default"). > > > > I propose the attached patch which, on seeing a mask "default", assumes > > "0.0.0.0" and takes it from there. (See comment in patch.) > > > > (Oh! If only there were a decent API to read the routing table...) > > > > Any comments, anyone? (I'm not entirely happy with the patch. But given > > that this whole area is in practice sub-ideal anyway, is it at least "good > > enough"?) > > If its Solaris specific, I say do what you gotta do (but perhaps > #ifdef it out for everyone else).
Thanks. Good point. I'm adding a "#if ..." bit at the top to do a "#define ..." to disable this processing. I'm suggesting that the default is to enable it. (Why?) Linux is unaffected (it uses "/proc/..." rather than "route get" (and anyway its "route" doesn't "get"!)) For the remaining OSes, and their subset which use "route get", a text "default" will be bad anyway. Thanks again. Best wishes. -- : David Lee I.T. Service : : Senior Systems Programmer Computer Centre : : Durham University : : http://www.dur.ac.uk/t.d.lee/ South Road : : Durham DH1 3LE : : Phone: +44 191 334 2752 U.K. : _______________________________________________________ Linux-HA-Dev: [email protected] http://lists.linux-ha.org/mailman/listinfo/linux-ha-dev Home Page: http://linux-ha.org/
