What's new

384.7 IPV6 Stateful Generates Logged Errors, Stateless Does Not

  • SNBForums Code of Conduct

    SNBForums is a community for everyone, no matter what their level of experience.

    Please be tolerant and patient of others, especially newcomers. We are all here to share and learn!

    The rules are simple: Be patient, be nice, be helpful or be gone!

I'd also guess that stateful config isn't the primary used config.

I was trying to use it (and would prefer to), but I could not get static assignments to stick. I went back to stateless, because at least I could have one "static" Ipv6 address for each device (via SLAAC). I did not see similar errors, but I am on different hardware (RT-AC3200).
 
Yes...should be run without any of the other things we've tried.
The only one that should survive a restart is the post config, so I'll rename it. restart, load the test firmware.
Back in a few
 
Ok, removed the other changes. Restarted. Applied the test load, restarted in stateless mode.
In stateless mode, I do not get the constant restart of dnsmasq, but still get the no upstream servers configured error, but as my DHCP clients can pull an address, it is working.
Code:
May  5 01:05:07 nat: apply redirect rules
May  5 01:05:09 dnsmasq[752]: warning: no upstream servers configured
May  5 01:05:11 lldpd[925]: cannot get ethtool link information with GLINKSETTINGS (requires 4.9+): Operation not permitted
May  5 01:05:12 WAN_Connection: ISP's DHCP did not function properly.

May  5 01:05:14 odhcp6c[1008]: Failed to send DHCPV6 message to ff02::1:2 (Cannot assign requested address)

In stateful mode, same errors as before and DHCP clients of course can't pull an address.
Code:
Aug 20 13:26:51 dhcp6_client: bound address 2001:558:6017:1a4:34a7:8c78:d117:ee12/128, prefix 2601:19b:4800:2121::/64
Aug 20 13:27:07 kernel: Unhandled fault: alignment fault (0x92000021) at 0x0000000000869f56
Aug 20 13:27:23 rc_service: watchdog 769:notify_rc start_dnsmasq
Aug 20 13:27:23 dnsmasq[2255]: warning: no upstream servers configured
Aug 20 13:27:24 kernel: Unhandled fault: alignment fault (0x92000021) at 0x00000000007708c6
 
@GHammer - OK....let me try this. Let me do a build that backlevels dnsmasq to the previous release and we'll see what happens.

Also, had an idea of one other thing to try.
Go back to Merlin's official release....and on the WAN page disable DNS rebind protection
 
@GHammer - OK....let me try this. Let me do a build that backlevels dnsmasq to the previous release and we'll see what happens.

Also, had an idea of one other thing to try.
Go back to Merlin's official release....and on the WAN page disable DNS rebind protection

DNS rebind protection on the LAN-DHCP page is (and has been) disabled.
I'll wait on your new build, unless there is something else the swap will do.
 
@john9527 With 384.6 loaded
Stateless
Code:
May  5 01:05:09 dnsmasq[752]: warning: no upstream servers configured
Stateful
Code:
Aug 20 13:30:23 rc_service: watchdog 769:notify_rc start_dnsmasq
Aug 20 13:30:23 dnsmasq[2381]: warning: no upstream servers configured
Aug 20 13:30:23 kernel: Unhandled fault: alignment fault (0x92000021) at 0x000000000019d8c6
 
Interesting....so not related to the new dnsmasq (although may still be something inherent in the base code).

Best thing to do now is to follow @Sean B. 's suggestion and install Entware and strace to see what system call is creating the error.
 
Interesting....so not related to the new dnsmasq (although may still be something inherent in the base code).

Best thing to do now is to follow @Sean B. 's suggestion and install Entware and strace to see what system call is creating the error.
@john9527 @Sean B. @RMerlin

Here's an interesting post from June that seems to deal with the same thing.
https://www.snbforums.com/threads/ipv6-and-stateless-configuration.47401/


I'll get Entware installed and continue again tomorrow.
If you can think of something you'd like to see or for me to try, line them up.
 
@john9527 @Sean B. @RMerlin

Here's an interesting post from June that seems to deal with the same thing.
https://www.snbforums.com/threads/ipv6-and-stateless-configuration.47401/


I'll get Entware installed and continue again tomorrow.
If you can think of something you'd like to see or for me to try, line them up.
I'm not sure about the nomenclature used for the options in Merlins firmware, so this is a craps shoot, but try setting the DHCP-PD option to disabled, enable stateful, reboot router and check the logs.

Reasoning: In Tomato firmware, the equivalent "type" option that works for Comcast is "DHCPv6 with prefix delegation" . There are additional checkbox options, one of which is "Request DHCPv6 PD only". That option causes failure of Comcast connections. As Merlins firmware doesn't state prefix delegation in the type, the DHCP-PD option may likely be appropriate to have enabled. However if it is referencing a PD "only" option, then things go south.
 
@john9527 , would you consider this correct?

Code:
if (inet_ntop(AF_INET6, &addr, buf, sizeof(buf))) {
        strlcat(buf, "/64", sizeof(buf));
        eval("ip", "-6", "addr", "add", buf, "dev", (char *) ifname, "scope", "link");
    }

A change to IPv6 code, committed here . It adds the /64 prefix designation into a buffer of same size. But what happens when dhcpv6 prefix delegation hands off to the LAN interface and the WAN interface receives a /128 prefix? Would that not overrun the sized buffer?
 
Hi there, inet6_addrstrlen is 46, maximum size of ipv4-mapped addresses. at the same time that func is used to reciver link-local addresses which can never be mapped, so max size is 40, remaining 6 bytes are more than enough for /nnn.
So, not beautiful (especially that static buf), but should be no harm.
Dnsmasq is crashing, it can’t be solved by config, instead more likely running 32bit userspace on 64bit kernel is the issue root.
Could you please provide exact /etc/dnsmasq.conf, /tmp/resolv.* files content, ip -6 a, ip -6 r output, it’ll help to reproduce. For privacy reasons you could send me that via mail themiron at mail.ru
 
I have sent the requested info to @theMIROn and will wait until we have some word from him.
 
Hi there, inet6_addrstrlen is 46, maximum size of ipv4-mapped addresses. at the same time that func is used to reciver link-local addresses which can never be mapped, so max size is 40, remaining 6 bytes are more than enough for /nnn.
So, not beautiful (especially that static buf), but should be no harm.
Dnsmasq is crashing, it can’t be solved by config, instead more likely running 32bit userspace on 64bit kernel is the issue root.
Could you please provide exact /etc/dnsmasq.conf, /tmp/resolv.* files content, ip -6 a, ip -6 r output, it’ll help to reproduce. For privacy reasons you could send me that via mail themiron at mail.ru
I completely agree with your assessment of the issue. I mentioned on the previous page of this thread that the alignment fault is likely the cause, dnsmasq crashing being a symptom. I've been hunting through the github fishing for changes that include both IPv6 code and things like buffers, copying from userland, and pointer alignment etc. But I'm not the best at skimming code, things start blending together in short order for me hehe.
 
I have sent the requested info to @theMIROn and will wait until we have some word from him.
It appears Merlin firmware may have strace compiled in with it. This would be some great log output to obtain on the issue:

With stateful enabled, simply:

Code:
killall dnsmasq & strace -fivyo /tmp/trace.log dnsmasq --conf-file=/etc/dnsmasq.conf

When done, results will be in /tmp/trace.log . If you get a "not found" error when trying to run strace then it's not included in your build. If it's there but gives you errors about any of the -fivyo flags, then it's a different version from what I have and you can omit any flags that aren't valid for yours, the only one considered required is the "-o /tmp/trace.log".
 

Similar threads

Latest threads

Support SNBForums w/ Amazon

If you'd like to support SNBForums, just use this link and buy anything on Amazon. Thanks!

Sign Up For SNBForums Daily Digest

Get an update of what's new every day delivered to your mailbox. Sign up here!
Top