Skip site navigation (1)Skip section navigation (2)
Date:      Mon, 20 Dec 2021 00:55:19 +0300
From:      KOT MATPOCKuH <matpockuh@gmail.com>
To:        koobs@freebsd.org
Cc:        freebsd-stable List <freebsd-stable@freebsd.org>, Alan Somers <asomers@freebsd.org>
Subject:   Re: ping -6 ignores -e parameter
Message-ID:  <CALmdT0Vmu3_n_BVXkAr-izEmK_MDhuPezV3DXzNf8%2BE9ML8C7w@mail.gmail.com>
In-Reply-To: <5140f4e1-df13-ebaa-341e-5274ead366ce@FreeBSD.org>
References:  <CALmdT0WvtUdteHKEw35tkgZyVzKW2ZT1LKmm1W62vQ_ev2QyPg@mail.gmail.com> <CAOtMX2jUey0qA8MTmRzjVmdQJp5-JOBEeLwGtoNvrucdvwcTWQ@mail.gmail.com> <22748b81-2ae8-babd-d07e-752ed15dce58@GMail.Com> <5140f4e1-df13-ebaa-341e-5274ead366ce@FreeBSD.org>

next in thread | previous in thread | raw e-mail | index | archive | help
--00000000000053af0a05d386d56c
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable

Hello!

I downloaded a daily snapshot VM from:
https://download.freebsd.org/ftp/snapshots/VM-IMAGES/13.0-STABLE/amd64/2021=
1216/FreeBSD-13.0-STABLE-amd64-20211216-defb7da9772-248589.raw.xz

root@freebsd:~ # uname -a
FreeBSD freebsd 13.0-STABLE FreeBSD 13.0-STABLE #0
stable/13-n248589-defb7da9772: Thu Dec 16 02:33:55 UTC 2021
root@releng3.nyi.freebsd.org:/usr/obj/usr/src/amd64.amd64/sys/GENERIC  amd6=
4

It's 3 days later than 13th Dec.
I checked on this VM and got the same behavior.
Also I registered a bug:
https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=3D260474

There You can find steps to reproduce this problem.

Also can You assign this report to a proper responsible?


=D1=81=D0=B1, 18 =D0=B4=D0=B5=D0=BA. 2021 =D0=B3. =D0=B2 04:16, Kubilay Koc=
ak <koobs@freebsd.org>:

> On 16/12/2021 9:30 pm, KOT MATPOCKuH wrote:
> > Hello, Alan!
> >
> > I'm sorry, I'm forget to add freebsd-stable@ to CC: list.
> >
> > Yes, I'm using FreeBSD 13:
> > 13.0-STABLE
> >
> > Today I have a native IPv6 access and my inet6 routing table is:
> > # netstat -rn6 | grep -v -e lo0
> > Routing tables
> >
> > Internet6:
> > Destination                       Gateway                       Flags
> > Netif Expire
> > default                           fe80::206:29ff:fee9:32a9%lan0 UG
> lan0
> > fd00:dead:beef:100::/64           link#5                        U    la=
n0
> > fe80::%lan0/64                    link#5                        U    la=
n0
> > fe80::%bridge0/64                 link#6                        U bridg=
e0
> >
> > This means my default gateway is reachable via lan0.
> > A node which link-local address fe80::2a0:98ff:fe1d:e270 is reachable
> > via bridge0:
> > # ping -c 1 fe80::2a0:98ff:fe1d:e270%bridge0
> > PING6(56=3D40+8+8 bytes) fe80::5a9c:fcff:fe10:ff9e%bridge0 -->
> > fe80::2a0:98ff:fe1d:e270%bridge0
> > 16 bytes from fe80::2a0:98ff:fe1d:e270%bridge0, icmp_seq=3D0 hlim=3D64
> > time=3D0.804 ms
> >
> > But ping anyway sends packets via lan0.
> > Also I tried to configure fd13:dead:beef::2 on bridge0, on correspondin=
g
> > node I configured fd13:dead:beef::1, and then run a command:
> > ping -6 -e fd13:dead:beef::1 google.com
> >
> > In this way ping uses source IP address from bridge0 interface, but
> > sends via lan0 and to next-hop fe80::206:29ff:fee9:32a9%lan0:
> > # tcpdump -epni lan0 icmp6
> > 12:33:23.308763 8c:ec:4b:e9:28:23 > 00:06:29:e9:32:a9, ethertype IPv6
> > (0x86dd), length 70: fd13:dead:beef::2 > 2a00:1450:4010:c1e::8a: ICMP6,
> > echo request, seq 52, length 16
> >
> > I'm wrote a simple script to check this problem. I checked this script
> > on image of VM from freebsd'site which FreeBSD-13.
> > Please see attached file.
> >
> > On 15/12/2021 21:32, Alan Somers wrote:
> >> On Wed, Dec 15, 2021 at 11:16 AM KOT MATPOCKuH <matpockuh@gmail.com>
> >> wrote:
> >>>
> >>> Hello!
> >>>
> >>> In a man page for ping(8) and in it's help output I found option "-e"=
:
> >>>       -e gateway
> >>>               Specifies to use gateway as the next hop to the
> >>> destination.  The
> >>>               gateway must be a neighbor of the sending node.
> >>>
> >>> I tried to use this argument, ping ignores this parameter and sends
> >>> the packet via default gateway.
> >>> For example I have a tun0 which has ipv6 default gw, and an
> >>> established bridge0 which has available some LL addresses:
> >>> Neighbor                             Linklayer Address  Netif
> >>> Expire    S Flags
> >>> fe80::2a0:98ff:fe1d:e270%bridge0     00:a0:98:1d:e2:70 bridge0
> >>> 23h56m34s S R
> >>>
> >>> I tried to run:
> >>> ping -6 -e FE80::2A0:98FF:FE1D:E270%bridge0 google.com
> >>> But the packet was sent via tun0 interface.
> >>>
> >>> What is wrong with it?
> >>>
> >>> --
> >>> MATPOCKuH
> >>
> >> What version of FreeBSD are you using?  There was a major change to
> >> ping's code in FreeBSD 13.  Please show the output of
> >> 'freebsd-version' and 'netstat -rn'.
> >> -Alan
> >>
> >
>
> Potentially relevant issue issue who's stable/13 merge landed 2021-12-13:
>
>    https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=3D258048
>
> Is your uname -a version prior to or after this date?
>
> If after, can you test reverting this revision?
>


--=20
MATPOCKuH

--00000000000053af0a05d386d56c
Content-Type: text/html; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable

<div dir=3D"ltr"><div>Hello!</div><div><br></div><div>I downloaded a daily =
snapshot VM from:<br></div><div><a href=3D"https://download.freebsd.org/ftp=
/snapshots/VM-IMAGES/13.0-STABLE/amd64/20211216/FreeBSD-13.0-STABLE-amd64-2=
0211216-defb7da9772-248589.raw.xz">https://download.freebsd.org/ftp/snapsho=
ts/VM-IMAGES/13.0-STABLE/amd64/20211216/FreeBSD-13.0-STABLE-amd64-20211216-=
defb7da9772-248589.raw.xz</a></div><div><br></div><div>root@freebsd:~ # una=
me -a<br>FreeBSD freebsd 13.0-STABLE FreeBSD 13.0-STABLE #0 stable/13-n2485=
89-defb7da9772: Thu Dec 16 02:33:55 UTC 2021 =C2=A0 =C2=A0 root@releng3.nyi=
.freebsd.org:/usr/obj/usr/src/amd64.amd64/sys/GENERIC =C2=A0amd64</div><div=
><br></div><div>It&#39;s 3 days later than 13th Dec.<br></div><div>I checke=
d on this VM and got the same behavior.</div><div>Also I registered a bug:<=
/div><div><a href=3D"https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=3D26=
0474">https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=3D260474</a></div><=
div><br></div><div>There You can find steps to reproduce this problem.</div=
><div><br></div><div>Also can You assign this report to a proper responsibl=
e?<br></div><div><br></div></div><br><div class=3D"gmail_quote"><div dir=3D=
"ltr" class=3D"gmail_attr">=D1=81=D0=B1, 18 =D0=B4=D0=B5=D0=BA. 2021 =D0=B3=
. =D0=B2 04:16, Kubilay Kocak &lt;<a href=3D"mailto:koobs@freebsd.org">koob=
s@freebsd.org</a>&gt;:<br></div><blockquote class=3D"gmail_quote" style=3D"=
margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-lef=
t:1ex">On 16/12/2021 9:30 pm, KOT MATPOCKuH wrote:<br>
&gt; Hello, Alan!<br>
&gt; <br>
&gt; I&#39;m sorry, I&#39;m forget to add freebsd-stable@ to CC: list.<br>
&gt; <br>
&gt; Yes, I&#39;m using FreeBSD 13:<br>
&gt; 13.0-STABLE<br>
&gt; <br>
&gt; Today I have a native IPv6 access and my inet6 routing table is:<br>
&gt; # netstat -rn6 | grep -v -e lo0<br>
&gt; Routing tables<br>
&gt; <br>
&gt; Internet6:<br>
&gt; Destination=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=
=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=
 Gateway=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=
=C2=A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C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=
=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 U bridge0<br>
&gt; <br>
&gt; This means my default gateway is reachable via lan0.<br>
&gt; A node which link-local address fe80::2a0:98ff:fe1d:e270 is reachable =
<br>
&gt; via bridge0:<br>
&gt; # ping -c 1 fe80::2a0:98ff:fe1d:e270%bridge0<br>
&gt; PING6(56=3D40+8+8 bytes) fe80::5a9c:fcff:fe10:ff9e%bridge0 --&gt; <br>
&gt; fe80::2a0:98ff:fe1d:e270%bridge0<br>
&gt; 16 bytes from fe80::2a0:98ff:fe1d:e270%bridge0, icmp_seq=3D0 hlim=3D64=
 <br>
&gt; time=3D0.804 ms<br>
&gt; <br>
&gt; But ping anyway sends packets via lan0.<br>
&gt; Also I tried to configure fd13:dead:beef::2 on bridge0, on correspondi=
ng <br>
&gt; node I configured fd13:dead:beef::1, and then run a command:<br>
&gt; ping -6 -e fd13:dead:beef::1 <a href=3D"http://google.com" rel=3D"nore=
ferrer" target=3D"_blank">google.com</a><br>
&gt; <br>
&gt; In this way ping uses source IP address from bridge0 interface, but <b=
r>
&gt; sends via lan0 and to next-hop fe80::206:29ff:fee9:32a9%lan0:<br>
&gt; # tcpdump -epni lan0 icmp6<br>
&gt; 12:33:23.308763 8c:ec:4b:e9:28:23 &gt; 00:06:29:e9:32:a9, ethertype IP=
v6 <br>
&gt; (0x86dd), length 70: fd13:dead:beef::2 &gt; 2a00:1450:4010:c1e::8a: IC=
MP6, <br>
&gt; echo request, seq 52, length 16<br>
&gt; <br>
&gt; I&#39;m wrote a simple script to check this problem. I checked this sc=
ript <br>
&gt; on image of VM from freebsd&#39;site which FreeBSD-13.<br>
&gt; Please see attached file.<br>
&gt; <br>
&gt; On 15/12/2021 21:32, Alan Somers wrote:<br>
&gt;&gt; On Wed, Dec 15, 2021 at 11:16 AM KOT MATPOCKuH &lt;<a href=3D"mail=
to:matpockuh@gmail.com" target=3D"_blank">matpockuh@gmail.com</a>&gt; <br>
&gt;&gt; wrote:<br>
&gt;&gt;&gt;<br>
&gt;&gt;&gt; Hello!<br>
&gt;&gt;&gt;<br>
&gt;&gt;&gt; In a man page for ping(8) and in it&#39;s help output I found =
option &quot;-e&quot;:<br>
&gt;&gt;&gt; =C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 -e gateway<br>
&gt;&gt;&gt; =C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=
=C2=A0=C2=A0=C2=A0 Specifies to use gateway as the next hop to the <br>
&gt;&gt;&gt; destination.=C2=A0 The<br>
&gt;&gt;&gt; =C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=
=C2=A0=C2=A0=C2=A0 gateway must be a neighbor of the sending node.<br>
&gt;&gt;&gt;<br>
&gt;&gt;&gt; I tried to use this argument, ping ignores this parameter and =
sends <br>
&gt;&gt;&gt; the packet via default gateway.<br>
&gt;&gt;&gt; For example I have a tun0 which has ipv6 default gw, and an <b=
r>
&gt;&gt;&gt; established bridge0 which has available some LL addresses:<br>
&gt;&gt;&gt; Neighbor=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=
=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=
=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 Linklayer Address=C2=A0 Netif <br>
&gt;&gt;&gt; Expire=C2=A0=C2=A0=C2=A0 S Flags<br>
&gt;&gt;&gt; fe80::2a0:98ff:fe1d:e270%bridge0=C2=A0=C2=A0=C2=A0=C2=A0 00:a0=
:98:1d:e2:70 bridge0 <br>
&gt;&gt;&gt; 23h56m34s S R<br>
&gt;&gt;&gt;<br>
&gt;&gt;&gt; I tried to run:<br>
&gt;&gt;&gt; ping -6 -e FE80::2A0:98FF:FE1D:E270%bridge0 <a href=3D"http://=
google.com" rel=3D"noreferrer" target=3D"_blank">google.com</a><br>
&gt;&gt;&gt; But the packet was sent via tun0 interface.<br>
&gt;&gt;&gt;<br>
&gt;&gt;&gt; What is wrong with it?<br>
&gt;&gt;&gt;<br>
&gt;&gt;&gt; -- <br>
&gt;&gt;&gt; MATPOCKuH<br>
&gt;&gt;<br>
&gt;&gt; What version of FreeBSD are you using?=C2=A0 There was a major cha=
nge to<br>
&gt;&gt; ping&#39;s code in FreeBSD 13.=C2=A0 Please show the output of<br>
&gt;&gt; &#39;freebsd-version&#39; and &#39;netstat -rn&#39;.<br>
&gt;&gt; -Alan<br>
&gt;&gt;<br>
&gt; <br>
<br>
Potentially relevant issue issue who&#39;s stable/13 merge landed 2021-12-1=
3:<br>
<br>
=C2=A0 =C2=A0<a href=3D"https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=
=3D258048" rel=3D"noreferrer" target=3D"_blank">https://bugs.freebsd.org/bu=
gzilla/show_bug.cgi?id=3D258048</a><br>
<br>
Is your uname -a version prior to or after this date?<br>
<br>
If after, can you test reverting this revision?<br>
</blockquote></div><br clear=3D"all"><br>-- <br><div dir=3D"ltr" class=3D"g=
mail_signature">MATPOCKuH</div>

--00000000000053af0a05d386d56c--



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?CALmdT0Vmu3_n_BVXkAr-izEmK_MDhuPezV3DXzNf8%2BE9ML8C7w>