[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <532f9e8f-5e48-9e2e-c346-e2522f788a40@gmail.com>
Date: Fri, 27 Aug 2021 09:50:33 -0700
From: David Ahern <dsahern@...il.com>
To: David Laight <David.Laight@...LAB.COM>,
"netdev@...r.kernel.org" <netdev@...r.kernel.org>
Subject: Re: IP routing sending local packet to gateway.
On 8/27/21 9:39 AM, David Laight wrote:
> From: David Laight
>> Sent: 27 August 2021 15:12
>>
>> I've an odd IP routing issue.
>> A packet that should be sent on the local subnet (to an ARPed address)
>> is being send to the default gateway instead.
>
> I've done some tests on a different network where it all appears to work.
>
> But running 'tcpdump -pen' shows that all the outbound packets for the
> TCP connections are being sent to the default gateway.
>
> 5.10.30, 5.10.61 and 5.14.0-rc7 all behave the same way.
>
> If do a ping (in either direction) I get an ARP table entry.
> But TCP connections (in or out) always use the default gateway.
>
> I'm now getting more confused.
> I noticed that the 'default route' was missing the 'metric 100' bit.
> That might give the behaviour I'm seeing if the netmask width is ignored.
>
> But if I delete the default route (neither netstat -r or ip route show
> it) then packets are still being sent to the deleted gateway.
> If I delete the arp/neigh entry for the deleted default gateway an
> outward connection recreates the entry - leaving the one for the actual
> address 'STALE'.
>
> Something very odd is going on.
perf record -e fib:* -a -g -- <run tests>
ctrl-c
perf script
It should tell you code paths and route lookup results. Should shed some
light on why the gw vs local.
Powered by blists - more mailing lists