[support] Destination unreachable from HA on BU???

Arnaud Ebalard arno at natisbad.org
Thu Mar 26 20:37:14 JST 2009


Hi,

Mattias Blomqvist <mattias.blomqvist at gmail.com> writes:

> Hi
>
> I may revisit the kernel problem later. Right now I'm satisfied with
> having it running on 2.6.29.

ack.

> Regarding the segfault I think I found the source.
> Forget what I said about ulimit.

;-) done.

> It always seem to segfault on the first run regardless of what ulimit
> is. Why it doesn't segfault after the first run is unknown to me but
> my guess is that something is left behind that prevents further
> segfaults. 
> Anyhow, since the umip package from natisbad.org default seems to
> build with debug symbols it was pretty easy to find with the core file
> and some gdb...

thanks for having taken the time.

> What happens is the following:
> The segfault is in a memcpy in libnetlink and it is a result of the
> gateway variable pointing to non-accessible memory in the call to
> addattr_l() in route_mod() in rtnl.c
> This in turn is called from apply_update_tunnel_route() in movement.c
> where the actual error seems to be. This functions is only present in
> movement.c after applying the tunnel_support patch so the error is in
> the patch.
> Line 436 in tunnel_support.patch is:
> gateway = RTA_DATA(rta_tb[RTA_DST]);
> Shouldn't this be:
> gateway = RTA_DATA(rta_tb[RTA_GATEWAY]);
> ???

Yep, looks like a stupid typo. Considering the test done before that
line, rta_tb[RTA_SRC] is guaranteed to be NULL at that point and the
call to RTA_DATA(rta_tb[RTA_DST] that is done basically returns a small
offset (RTA_LENGTH(0) in fact, i.e. 4):

	   if present (for 6to4 mainly). We just skip other routes. */
	if (r->rtm_dst_len != 0 ||
	    r->rtm_src_len != 0 ||
	    r->rtm_table != RT_TABLE_MAIN ||
	    r->rtm_scope != RT_SCOPE_UNIVERSE ||
	    r->rtm_type != RTN_UNICAST ||
	    rta_tb[RTA_DST] != NULL ||
	    rta_tb[RTA_SRC] != NULL)
		return 0;

	if (rta_tb[RTA_GATEWAY]) {
		gateway = RTA_DATA(rta_tb[RTA_GATEWAY]);
	}

I have updated the patch, the associated mercurial repo and I have also
released a new version of the package (0.4-13). Can you try and do an
"apt-get update && apt-get install umip" to check it is ok on your side?

Thanks for the feedback.

Cheers,

a+


More information about the Support mailing list