Commit 8fb2da5
committed
tests: system-traffic: Fix flaky floating IP test.
The last ACK from the 3-WAY handshake in this test goes to userspace
(miss upcall) after going through conntrack because +est traffic is
handled differently from +new in this set of OpenFlow rules.
The sender though proceeds with sending the data that may end up
re-ordered with the aforementioned ACK. Since connection is very
short, it is possible that this one ACK will be delivered even after
the connection is already closed, i.e., after all the data is sent
and the connection termination sequence (FIN-ACK-FIN-ACK) is done.
Delivery in this case triggers an RST reply. And RST transitions
TIME_WAIT into CLOSE (CLOSING in OVS terms), causing the test failure.
It's not really possible to fully avoid the packet re-ordering as it
is part of the upcall mechanism. But there is a couple ways to avoid
it in this particular case, e.g., if we predict how the +est packet
will look like and install the datapath flow for +est while processing
the original +new, or by storing the upcall PID in the kernel for the
whole time of action execution and not only for one packet we're
executing actions for (TCP handshake replies are happening in the
context of the initiator, which is OVS handler thread in our case).
But these are large changes that will not help with test failures
on older branches / older kernels. For now, fixing the test instead.
The intention in the test was to check that the state is terminal at
the end of the connection, i.e., that our actions do not leave
established or incomplete conntrack entries. So it should be fine to
check for both TIME_WAIT and CLOSING, as both of these are terminal
states.
Fixes: 8d48d5f ("system-traffic: Add conntrack floating IP test")
Acked-by: Eelco Chaudron <echaudro@redhat.com>
Signed-off-by: Ilya Maximets <i.maximets@ovn.org>1 parent 3567eb4 commit 8fb2da5
1 file changed
+31
-12
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
8844 | 8844 | | |
8845 | 8845 | | |
8846 | 8846 | | |
8847 | | - | |
| 8847 | + | |
| 8848 | + | |
| 8849 | + | |
| 8850 | + | |
| 8851 | + | |
| 8852 | + | |
| 8853 | + | |
| 8854 | + | |
| 8855 | + | |
| 8856 | + | |
8848 | 8857 | | |
8849 | | - | |
8850 | | - | |
8851 | | - | |
8852 | | - | |
8853 | | - | |
8854 | | - | |
8855 | | - | |
8856 | | - | |
| 8858 | + | |
| 8859 | + | |
| 8860 | + | |
| 8861 | + | |
| 8862 | + | |
| 8863 | + | |
| 8864 | + | |
| 8865 | + | |
| 8866 | + | |
| 8867 | + | |
| 8868 | + | |
| 8869 | + | |
| 8870 | + | |
| 8871 | + | |
| 8872 | + | |
8857 | 8873 | | |
8858 | | - | |
8859 | | - | |
8860 | | - | |
| 8874 | + | |
| 8875 | + | |
| 8876 | + | |
| 8877 | + | |
| 8878 | + | |
| 8879 | + | |
8861 | 8880 | | |
8862 | 8881 | | |
8863 | 8882 | | |
| |||
0 commit comments