kernel: udp6_output: IPV6_V6ONLY option was set for a connected socket

Hi,

I am trying to implement IPv6 step by step and since I started I have this log entry filling my logfiles:

kernel: udp6_output: IPV6_V6ONLY option was set for a connected socket

How can I find out what's causing this? [CMD="sockstat -6"][/CMD] only tells me that Varnish is listening on a IPv6 address, besides nothing.

Can anybody help me out?
 
I think this is caused by something that's compiled with IPv6 support only. When it tries to contact an IPv4 address it needs to use an IPv4 mapped IPv6 address. This is turned off by default.

Code:
ipv6_ipv4mapping="NO"           # Set to "YES" to enable IPv4 mapped IPv6 addr
                                # communication. (like ::ffff:a.b.c.d)

Unless you are planning on an IPv6 only network I suggest enabling both IPv4 and IPv6 (IPv6 will take precedence).
 
Ok, so I need to set this to YES, right, in order to support both.

Thanks.

UPDATE: I set [CMD="sysctl net.inet6.ip6.v6only=0"][/CMD] and will check what happens now. Thanks!
 
No, you don't really need it. I have both IPv4 and IPv6 enabled but have this turned off. As long as both stacks are available it'll use the IPv4 stack for IPv4. It should only be needed to access IPv4 addresses if you are on IPv6 only.
 
Strange. I am using both at the same time, even I use ::ffff:127.0.0.0 for internal addresses.

I will keep an eye on it.
 
Ben said:
Strange. I am using both at the same time, even I use ::ffff:127.0.0.0 for internal addresses.
That's an IPv4 mapped IPv6 address, use ::1.
 
I have jails using 127.0.0.10-15 for example. I also assigned ::ffff:127.0.0.10-15. This is not ok?

I thought this way I can access the jails via IPv6 easily and keeping it simple.
 
Just use your global addresses for it. I'm guessing you received a /64 or even a /48, so you'll have plenty of IP addresses to spare.
 
Yes I have a /64 but I was hoping to keep it clean and "easy to handle".
 
Those ::ffff:a.b.c.d addresses are for accessing IPv4 addresses from IPv6. If you're going to use IPv6 you might as well assign them a proper IPv6 address. Since there's no need for something like NAT this is in fact the easiest to handle. Jails can have both an IPv4 address and an IPv6 address.
 
Ben said:
Yes I have a /64 but I was hoping to keep it clean and "easy to handle".

Forget about IPv4 addresses if you are using IPv6. The global range you received should be 2001::/64 or similar. Keep in mind no need for nat so be sure to know what you'r doing.
 
Back
Top