Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
Re: [wakaama-dev] LWM2M client registration failure

Hi Achim, Vyacheslav,

Thanks, I came across the same solution once Achim mentioned the migration to IPv6. Especially this line when the client receives the ACK:

13 bytes received from [::ffff:127.0.0.1]:5683
                        ^^^^^^^^^^^^^^^^

This gave me a clue that a v4 mapped v6 address was being used instead of IPv6 localhost.

So then I tried:

$ ./lwm2mclient -h ::1 -p 5683

and that worked fine.

So at least in my configuration, IPv6 is enabled by default, but as the box is behind a NAT, it is not globally routable.

A simple fix seems to be to change this line in lwm2mlient.c:

const char * server = "localhost";

to

const char * server = "::1";


but I suppose that for clients that do not have v6 at all, perhaps a "-4" commandline option in optargs or a -DIPv6_DISABLED flag can be used to substitute "::1" with "localhost"?

Regards,
Bill



Back to the top