Date: Thu, 18 Jul 2024 17:48:22 +0200 From: Santiago Martinez <sm@codenetworks.net> To: freebsd-net@freebsd.org Subject: Re: Multiple Fibs and INET6 Message-ID: <D34B5A01-9770-4BCF-B427-796F443303E0@codenetworks.net> In-Reply-To: <da781b66-4ab3-426f-bf56-f453030c6e61@codenetworks.net> References: <da781b66-4ab3-426f-bf56-f453030c6e61@codenetworks.net>
next in thread | previous in thread | raw e-mail | index | archive | help
[-- Attachment #1 --]
Hi everyone,
Did anyone had the chance to take a look?
For me it’s a bug but before filling the PR want to know what’s your view or if it’s a limitation or bug by design.
Br
Santi
> On 12 Jul 2024, at 19:06, Santiago Martinez <sm@codenetworks.net> wrote:
>
>
> Hi Everyone.
>
> While adding -F ( fib as used in netstat ) to ping and ping6 I have found something that from my understanding is not correct.
> Please can you advise?
> I have the following setup :
>
> -- two fibs (0 and 1)
> -- two loop-backs (lo0 and lo1).
> -- Lo1 has been assigned to fib1
> -- net.add_addr_allfibs = 0
> My interface output looks like this:
>
> ifconfig lo0 | grep inet6
> inet6 ::1 prefixlen 128
> inet6 fe80::1%lo0 prefixlen 64 scopeid 0x2
>
> ifconfig lo1 | grep inet6
> inet6 fe80::1%lo1 prefixlen 64 scopeid 0x3
>
>
> If I do a netstat -rn -6 -F0 I get the following which is was i expected.
>
> Internet6:
> Destination Gateway Flags Netif Expire
> ::/96 link#2 URS lo0
> ::1 link#2 UHS lo0
> ::ffff:0.0.0.0/96 link#2 URS lo0
> fe80::%lo0/10 link#2 URS lo0
> fe80::%lo0/64 link#2 U lo0
> fe80::1%lo0 link#2 UHS lo0
> ff02::/16 link#2 URS lo0
>
>
> Now, netstat -rn -6 -F1 shows "fe80::1%lo0" which should not be there and "fe80::1%lo1" is missing which should be there.
> Internet6:
> Destination Gateway Flags Netif Expire
> fe80::%lo1/64 link#3 U lo1
> fe80::1%lo0 link#2 UHS lo0
>
>
> What output I was expecting was:
> Internet6:
> Destination Gateway Flags Netif Expire
> fe80::%lo1/64 link#3 U lo1
> fe80::1%lo1 link#3 UHS lo1
>
>
>
> This makes the ping -6 -F0 fe80::1%lo0 to work but ping -6 -F1 fe80::1%l01 to fail which I wanted to use as test case.
>
> Thanks in advance.
>
> Santiago
>
[-- Attachment #2 --]
<html><head><meta http-equiv="content-type" content="text/html; charset=utf-8"></head><body dir="auto"><div dir="ltr"></div><div dir="ltr">Hi everyone,</div><div dir="ltr">Did anyone had the chance to take a look?</div><div dir="ltr">For me it’s a bug but before filling the PR want to know what’s your view or if it’s a limitation or bug by design.</div><div dir="ltr">Br</div><div dir="ltr">Santi</div><div dir="ltr"><br></div><div dir="ltr"><br><blockquote type="cite">On 12 Jul 2024, at 19:06, Santiago Martinez <sm@codenetworks.net> wrote:<br><br></blockquote></div><blockquote type="cite"><div dir="ltr">
<meta http-equiv="content-type" content="text/html; charset=UTF-8">
<p>Hi Everyone.</p>
While adding -F ( fib as used in netstat ) to ping and ping6 I have
found something that from my understanding is not correct.<br>
Please can you advise?<br>
<p>I have the following setup :</p>
-- two fibs (0 and 1) <br>
-- two loop-backs (lo0 and lo1).<br>
-- Lo1 has been assigned to fib1<br>
--<span style="color:#000000;background-color:#ffffff;">
net.add_addr_allfibs = 0</span>
<p><span style="color:#000000;background-color:#ffffff;">My
interface output looks like this:<br>
</span><span style="font-family:monospace"></span></p>
<p><span style="font-family:monospace"></span></p>
<p><span style="font-family:monospace"><span style="color:#000000;background-color:#ffffff;">ifconfig lo0 |
grep inet6
</span><br>
inet6 ::1 prefixlen 128
<br>
inet6 fe80::1%lo0 prefixlen 64 scopeid 0x2
<br>
</span></p>
<p><span style="font-family:monospace">ifconfig lo1 | grep inet6
<br>
inet6 fe80::1%lo1 prefixlen 64 scopeid 0x3<br>
<br>
</span></p>
<p>If I do a netstat -rn -6 -F0 I get the following which is was i
expected.<br>
</p>
<p><span style="font-family:monospace"><span style="color:#000000;background-color:#ffffff;">Internet6:
</span><br>
Destination Gateway
Flags Netif Expire
<br>
::/96 link#2
URS lo0
<br>
::1 link#2
UHS lo0
<br>
::ffff:0.0.0.0/96 link#2
URS lo0
<br>
fe80::%lo0/10 link#2
URS lo0
<br>
fe80::%lo0/64 link#2
U lo0
<br>
fe80::1%lo0 link#2
UHS lo0
<br>
ff02::/16 link#2
URS lo0<br>
<br>
</span></p>
Now, netstat -rn -6 -F1 shows "fe80::1%lo0" which should not be
there and "fe80::1%lo1" is missing which should be there.
<p></p>
<p><span style="font-family:monospace"><span style="color:#000000;background-color:#ffffff;">Internet6:
</span><br>
Destination Gateway
Flags Netif Expire
<br>
fe80::%lo1/64 link#3
U lo1
<br>
<b>fe80::1%lo0 link#2
UHS lo0</b><br>
<br>
</span></p>
What output I was expecting was:
<p><span style="font-family:monospace"><span style="color:#000000;background-color:#ffffff;">Internet6:
</span><br>
Destination Gateway
Flags Netif Expire
<br>
fe80::%lo1/64 link#3
U lo1
<br>
<b>fe80::1%lo1 link#3
UHS lo1</b></span></p>
<p><br>
</p>
<p>This makes the ping -6 -F0 fe80::1%lo0 to work but ping -6 -F1
fe80::1%l01 to fail which I wanted to use as test case.<span style="font-family:monospace"><br>
</span></p>
<p>Thanks in advance.</p>
Santiago
<p><span style="font-family:monospace"><br>
</span></p>
</div></blockquote></body></html>
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?D34B5A01-9770-4BCF-B427-796F443303E0>
