test_http_l7policies_and_l7rules randomly fails
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
octavia |
Fix Released
|
Medium
|
Gregory Thiemonge |
Bug Description
Reported at https:/
Description of problem:
octavia_
How reproducible:
randomly ~10%
Backtrace:
octavia_
-------
Captured traceback:
~~~~~~~~~~~~~~~~~~~
Traceback (most recent call last):
File "/usr/lib/
File "<string>", line 3, in raise_from
File "/usr/lib/
File "/usr/lib64/
File "/usr/lib64/
version, status, reason = self._read_status()
File "/usr/lib64/
line = str(self.
File "/usr/lib64/
return self._sock.
socket.timeout: timed out
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "/usr/lib/
resp = conn.urlopen(
File "/usr/lib/
retries = retries.increment(
File "/usr/lib/
raise six.reraise(
File "/usr/lib/
raise value
File "/usr/lib/
File "/usr/lib/
File "/usr/lib/
raise ReadTimeoutError(
urllib3.
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "/usr/lib/
File "/usr/lib/
req = session.
File "/usr/lib/
resp = self.send(prep, **send_kwargs)
File "/usr/lib/
r = adapter.
File "/usr/lib/
raise ReadTimeout(e, request=request)
requests.
tpcdump outputs from another run (not the same VIP address)
undercloud:
12:53:48.039779 IP 10.0.0.54.52864 > 10.0.0.159.84: Flags [S], seq 692056855, win 64240, options [mss 1460,sackOK,TS val 176487310 ecr 0,nop,wscale 7], length 0
12:53:48.041801 IP 10.0.0.159.84 > 10.0.0.54.52864: Flags [S.], seq 79995390, ack 692056856, win 43090, options [mss 1402,sackOK,TS val 3299079005 ecr 176487310,
12:53:48.041852 IP 10.0.0.54.52864 > 10.0.0.159.84: Flags [.], ack 1, win 502, options [nop,nop,TS val 176487312 ecr 3299079005], length 0
12:53:48.041909 IP 10.0.0.54.52864 > 10.0.0.159.84: Flags [P.], seq 1:145, ack 1, win 502, options [nop,nop,TS val 176487312 ecr 3299079005], length 144
12:53:48.083807 IP 10.0.0.159.84 > 10.0.0.54.52864: Flags [.], ack 145, win 21, options [nop,nop,TS val 3299079048 ecr 176487312], length 0
12:53:50.044449 IP 10.0.0.54.52864 > 10.0.0.159.84: Flags [F.], seq 145, ack 1, win 502, options [nop,nop,TS val 176489315 ecr 3299079048], length 0
12:53:50.085643 IP 10.0.0.159.84 > 10.0.0.54.52864: Flags [.], ack 146, win 21, options [nop,nop,TS val 3299081050 ecr 176489315], length 0
12:53:56.107623 IP 10.0.0.159.84 > 10.0.0.54.52864: Flags [P.], seq 1:163, ack 146, win 21, options [nop,nop,TS val 3299087072 ecr 176489315], length 162
12:53:56.107668 IP 10.0.0.54.52864 > 10.0.0.159.84: Flags [R], seq 692057001, win 0, length 0
12:53:56.107741 IP 10.0.0.159.84 > 10.0.0.54.52864: Flags [F.], seq 163, ack 146, win 21, options [nop,nop,TS val 3299087072 ecr 176489315], length 0
12:53:56.107758 IP 10.0.0.54.52864 > 10.0.0.159.84: Flags [R], seq 692057001, win 0, length 0
The FIN packet sent from the client at 12:53:50.044449 is the termination of the tcp connection after a 2 sec timeout (default value in octavia-
compute-0 (LB, vip port):
tap7f5d8569-04.pcap
16:53:48.041495 IP 10.0.0.54.52864 > 10.1.1.178.84: Flags [S], seq 692056855, win 64240, options [mss 1460,sackOK,TS val 176487310 ecr 0,nop,wscale 7], length 0
16:53:48.041844 IP 10.1.1.178.84 > 10.0.0.54.52864: Flags [S.], seq 79995390, ack 692056856, win 43090, options [mss 1402,sackOK,TS val 3299079005 ecr 176487310,
16:53:48.042940 IP 10.0.0.54.52864 > 10.1.1.178.84: Flags [.], ack 1, win 502, options [nop,nop,TS val 176487312 ecr 3299079005], length 0
16:53:48.042971 IP 10.0.0.54.52864 > 10.1.1.178.84: Flags [P.], seq 1:145, ack 1, win 502, options [nop,nop,TS val 176487312 ecr 3299079005], length 144
16:53:48.084218 IP 10.1.1.178.84 > 10.0.0.54.52864: Flags [.], ack 145, win 21, options [nop,nop,TS val 3299079048 ecr 176487312], length 0
16:53:50.045287 IP 10.0.0.54.52864 > 10.1.1.178.84: Flags [F.], seq 145, ack 1, win 502, options [nop,nop,TS val 176489315 ecr 3299079048], length 0
16:53:50.086054 IP 10.1.1.178.84 > 10.0.0.54.52864: Flags [.], ack 146, win 21, options [nop,nop,TS val 3299081050 ecr 176489315], length 0
16:53:56.108080 IP 10.1.1.178.84 > 10.0.0.54.52864: Flags [P.], seq 1:163, ack 146, win 21, options [nop,nop,TS val 3299087072 ecr 176489315], length 162
16:53:56.108279 IP 10.1.1.178.84 > 10.0.0.54.52864: Flags [F.], seq 163, ack 146, win 21, options [nop,nop,TS val 3299087072 ecr 176489315], length 0
16:53:56.108412 IP 10.0.0.54.52864 > 10.1.1.178.84: Flags [R], seq 692057001, win 0, length 0
16:53:56.108457 IP 10.0.0.54.52864 > 10.1.1.178.84: Flags [R], seq 692057001, win 0, length 0
compute-0 (LB, member port):
tapd9ee04bd-6c.pcap
16:53:48.043569 fa:16:3e:4a:e3:cd > ff:ff:ff:ff:ff:ff, ethertype ARP (0x0806), length 42: Request who-has 10.2.1.201 tell 10.2.1.220, length 28
16:53:48.043774 fa:16:3e:e5:06:68 > fa:16:3e:4a:e3:cd, ethertype ARP (0x0806), length 42: Reply 10.2.1.201 is-at fa:16:3e:e5:06:68, length 28
16:53:48.043902 fa:16:3e:4a:e3:cd > fa:16:3e:e5:06:68, ethertype IPv4 (0x0800), length 74: 10.2.1.220.45847 > 10.2.1.201.80: Flags [S], seq 479897052, win 43462, options [mss 1402,sackOK,TS val 4071114320 ecr 0,nop,wscale 11], length 0
16:53:49.045169 fa:16:3e:4a:e3:cd > fa:16:3e:e5:06:68, ethertype IPv4 (0x0800), length 74: 10.2.1.220.45847 > 10.2.1.201.80: Flags [S], seq 479897052, win 43462, options [mss 1402,sackOK,TS val 4071115322 ecr 0,nop,wscale 11], length 0
16:53:51.093070 fa:16:3e:4a:e3:cd > fa:16:3e:e5:06:68, ethertype IPv4 (0x0800), length 74: 10.2.1.220.45847 > 10.2.1.201.80: Flags [S], seq 479897052, win 43462, options [mss 1402,sackOK,TS val 4071117370 ecr 0,nop,wscale 11], length 0
16:53:53.050223 fa:16:3e:4a:e3:cd > fa:16:3e:e5:06:68, ethertype IPv4 (0x0800), length 74: 10.2.1.220.45851 > 10.2.1.201.80: Flags [S], seq 1703562389, win 43462, options [mss 1402,sackOK,TS val 4071119327 ecr 0,nop,wscale 11], length 0
16:53:54.101034 fa:16:3e:4a:e3:cd > fa:16:3e:e5:06:68, ethertype IPv4 (0x0800), length 74: 10.2.1.220.45851 > 10.2.1.201.80: Flags [S], seq 1703562389, win 43462, options [mss 1402,sackOK,TS val 4071120378 ecr 0,nop,wscale 11], length 0
16:53:56.105191 fa:16:3e:e5:06:68 > fa:16:3e:4a:e3:cd, ethertype IPv4 (0x0800), length 74: 10.2.1.201.80 > 10.2.1.220.45851: Flags [S.], seq 2546563750, ack 1703562390, win 65330, options [mss 1402,sackOK,TS val 593222582 ecr 4071119327,
16:53:56.105778 fa:16:3e:4a:e3:cd > fa:16:3e:e5:06:68, ethertype IPv4 (0x0800), length 66: 10.2.1.220.45851 > 10.2.1.201.80: Flags [.], ack 1, win 22, options [nop,nop,TS val 4071122382 ecr 593222582], length 0
16:53:56.106345 fa:16:3e:4a:e3:cd > fa:16:3e:e5:06:68, ethertype IPv4 (0x0800), length 205: 10.2.1.220.45851 > 10.2.1.201.80: Flags [P.], seq 1:140, ack 1, win 22, options [nop,nop,TS val 4071122383 ecr 593222582], length 139: HTTP: GET / HTTP/1.1
16:53:56.106704 fa:16:3e:e5:06:68 > fa:16:3e:4a:e3:cd, ethertype IPv4 (0x0800), length 66: 10.2.1.201.80 > 10.2.1.220.45851: Flags [.], ack 140, win 4075, options [nop,nop,TS val 593222585 ecr 4071122383], length 0
16:53:56.107530 fa:16:3e:e5:06:68 > fa:16:3e:4a:e3:cd, ethertype IPv4 (0x0800), length 228: 10.2.1.201.80 > 10.2.1.220.45851: Flags [P.], seq 1:163, ack 140, win 4075, options [nop,nop,TS val 593222586 ecr 4071122383], length 162: HTTP: HTTP/1.1 200 OK
16:53:56.107649 fa:16:3e:e5:06:68 > fa:16:3e:4a:e3:cd, ethertype IPv4 (0x0800), length 66: 10.2.1.201.80 > 10.2.1.220.45851: Flags [F.], seq 163, ack 140, win 4075, options [nop,nop,TS val 593222586 ecr 4071122383], length 0
16:53:56.107688 fa:16:3e:4a:e3:cd > fa:16:3e:e5:06:68, ethertype IPv4 (0x0800), length 66: 10.2.1.220.45851 > 10.2.1.201.80: Flags [.], ack 163, win 22, options [nop,nop,TS val 4071122384 ecr 593222586], length 0
16:53:56.108630 fa:16:3e:4a:e3:cd > fa:16:3e:e5:06:68, ethertype IPv4 (0x0800), length 66: 10.2.1.220.45851 > 10.2.1.201.80: Flags [F.], seq 140, ack 164, win 22, options [nop,nop,TS val 4071122385 ecr 593222586], length 0
16:53:56.109034 fa:16:3e:e5:06:68 > fa:16:3e:4a:e3:cd, ethertype IPv4 (0x0800), length 66: 10.2.1.201.80 > 10.2.1.220.45851: Flags [.], ack 141, win 4075, options [nop,nop,TS val 593222587 ecr 4071122385], length 0
16:53:57.256115 fa:16:3e:e5:06:68 > fa:16:3e:4a:e3:cd, ethertype IPv4 (0x0800), length 74: 10.2.1.201.80 > 10.2.1.220.45847: Flags [S.], seq 1063921752, ack 479897053, win 65330, options [mss 1402,sackOK,TS
Many unreplied-SYN packets sent by the load balancer
compute-1 (backend server):
tap71ade383-18.pcap
16:53:48.044206 fa:16:3e:4a:e3:cd > fa:16:3e:e5:06:68, ethertype IPv4 (0x0800), length 74: 10.2.1.220.45847 > 10.2.1.201.80: Flags [S], seq 479897052, win 43462, options [mss 1402,sackOK,TS val 4071114320 ecr 0,nop,wscale 11], length 0
16:53:48.044545 fa:16:3e:e5:06:68 > fa:16:3e:88:cd:6d, ethertype IPv4 (0x0800), length 74: 10.2.1.201.80 > 10.2.1.220.45847: Flags [S.], seq 1063921752, ack 479897053, win 65330, options [mss 1402,sackOK,TS val 593214523 ecr 4071114320,
16:53:49.045318 fa:16:3e:4a:e3:cd > fa:16:3e:e5:06:68, ethertype IPv4 (0x0800), length 74: 10.2.1.220.45847 > 10.2.1.201.80: Flags [S], seq 479897052, win 43462, options [mss 1402,sackOK,TS val 4071115322 ecr 0,nop,wscale 11], length 0
16:53:49.045541 fa:16:3e:e5:06:68 > fa:16:3e:88:cd:6d, ethertype IPv4 (0x0800), length 74: 10.2.1.201.80 > 10.2.1.220.45847: Flags [S.], seq 1063921752, ack 479897053, win 65330, options [mss 1402,sackOK,TS val 593215524 ecr 4071114320,
16:53:50.055051 fa:16:3e:e5:06:68 > fa:16:3e:88:cd:6d, ethertype IPv4 (0x0800), length 74: 10.2.1.201.80 > 10.2.1.220.45847: Flags [S.], seq 1063921752, ack 479897053, win 65330, options [mss 1402,sackOK,TS val 593216534 ecr 4071114320,
16:53:51.092783 fa:16:3e:4a:e3:cd > fa:16:3e:e5:06:68, ethertype IPv4 (0x0800), length 74: 10.2.1.220.45847 > 10.2.1.201.80: Flags [S], seq 479897052, win 43462, options [mss 1402,sackOK,TS val 4071117370 ecr 0,nop,wscale 11], length 0
16:53:51.093071 fa:16:3e:e5:06:68 > fa:16:3e:88:cd:6d, ethertype IPv4 (0x0800), length 74: 10.2.1.201.80 > 10.2.1.220.45847: Flags [S.], seq 1063921752, ack 479897053, win 65330, options [mss 1402,sackOK,TS val 593217572 ecr 4071114320,
16:53:53.050092 fa:16:3e:4a:e3:cd > fa:16:3e:e5:06:68, ethertype IPv4 (0x0800), length 74: 10.2.1.220.45851 > 10.2.1.201.80: Flags [S], seq 1703562389, win 43462, options [mss 1402,sackOK,TS val 4071119327 ecr 0,nop,wscale 11], length 0
16:53:53.050590 fa:16:3e:e5:06:68 > fa:16:3e:88:cd:6d, ethertype IPv4 (0x0800), length 74: 10.2.1.201.80 > 10.2.1.220.45851: Flags [S.], seq 2546563750, ack 1703562390, win 65330, options [mss 1402,sackOK,TS val 593219529 ecr 4071119327,
16:53:53.094983 fa:16:3e:e5:06:68 > fa:16:3e:88:cd:6d, ethertype IPv4 (0x0800), length 74: 10.2.1.201.80 > 10.2.1.220.45847: Flags [S.], seq 1063921752, ack 479897053, win 65330, options [mss 1402,sackOK,TS val 593219574 ecr 4071114320,
16:53:53.159033 fa:16:3e:e5:06:68 > fa:16:3e:88:cd:6d, ethertype ARP (0x0806), length 42: Request who-has 10.2.1.220 tell 10.2.1.201, length 28
16:53:53.159674 fa:16:3e:4a:e3:cd > fa:16:3e:e5:06:68, ethertype ARP (0x0806), length 42: Reply 10.2.1.220 is-at fa:16:3e:4a:e3:cd, length 28
16:53:54.055053 fa:16:3e:e5:06:68 > fa:16:3e:88:cd:6d, ethertype IPv4 (0x0800), length 74: 10.2.1.201.80 > 10.2.1.220.45851: Flags [S.], seq 2546563750, ack 1703562390, win 65330, options [mss 1402,sackOK,TS val 593220534 ecr 4071119327,
16:53:54.100741 fa:16:3e:4a:e3:cd > fa:16:3e:e5:06:68, ethertype IPv4 (0x0800), length 74: 10.2.1.220.45851 > 10.2.1.201.80: Flags [S], seq 1703562389, win 43462, options [mss 1402,sackOK,TS val 4071120378 ecr 0,nop,wscale 11], length 0
16:53:54.101008 fa:16:3e:e5:06:68 > fa:16:3e:88:cd:6d, ethertype IPv4 (0x0800), length 74: 10.2.1.201.80 > 10.2.1.220.45851: Flags [S.], seq 2546563750, ack 1703562390, win 65330, options [mss 1402,sackOK,TS val 593220580 ecr 4071119327,
16:53:54.183218 fa:16:3e:e5:06:68 > fa:16:3e:88:cd:6d, ethertype ARP (0x0806), length 42: Request who-has 10.2.1.220 tell 10.2.1.201, length 28
16:53:54.183645 fa:16:3e:4a:e3:cd > fa:16:3e:e5:06:68, ethertype ARP (0x0806), length 42: Reply 10.2.1.220 is-at fa:16:3e:4a:e3:cd, length 28
16:53:56.103047 fa:16:3e:e5:06:68 > fa:16:3e:4a:e3:cd, ethertype IPv4 (0x0800), length 74: 10.2.1.201.80 > 10.2.1.220.45851: Flags [S.], seq 2546563750, ack 1703562390, win 65330, options [mss 1402,sackOK,TS val 593222582 ecr 4071119327,
16:53:56.105709 fa:16:3e:4a:e3:cd > fa:16:3e:e5:06:68, ethertype IPv4 (0x0800), length 66: 10.2.1.220.45851 > 10.2.1.201.80: Flags [.], ack 1, win 22, options [nop,nop,TS val 4071122382 ecr 593222582], length 0
16:53:56.105911 fa:16:3e:4a:e3:cd > fa:16:3e:e5:06:68, ethertype IPv4 (0x0800), length 205: 10.2.1.220.45851 > 10.2.1.201.80: Flags [P.], seq 1:140, ack 1, win 22, options [nop,nop,TS val 4071122383 ecr 593222582], length 139: HTTP: GET / HTTP/1.1
16:53:56.106018 fa:16:3e:e5:06:68 > fa:16:3e:4a:e3:cd, ethertype IPv4 (0x0800), length 66: 10.2.1.201.80 > 10.2.1.220.45851: Flags [.], ack 140, win 4075, options [nop,nop,TS val 593222585 ecr 4071122383], length 0
16:53:56.106828 fa:16:3e:e5:06:68 > fa:16:3e:4a:e3:cd, ethertype IPv4 (0x0800), length 228: 10.2.1.201.80 > 10.2.1.220.45851: Flags [P.], seq 1:163, ack 140, win 4075, options [nop,nop,TS val 593222586 ecr 4071122383], length 162: HTTP: HTTP/1.1 200 OK
16:53:56.107020 fa:16:3e:e5:06:68 > fa:16:3e:4a:e3:cd, ethertype IPv4 (0x0800), length 66: 10.2.1.201.80 > 10.2.1.220.45851: Flags [F.], seq 163, ack 140, win 4075, options [nop,nop,TS val 593222586 ecr 4071122383], length 0
16:53:56.107256 fa:16:3e:4a:e3:cd > fa:16:3e:e5:06:68, ethertype IPv4 (0x0800), length 66: 10.2.1.220.45851 > 10.2.1.201.80: Flags [.], ack 163, win 22, options [nop,nop,TS val 4071122384 ecr 593222586], length 0
16:53:56.108160 fa:16:3e:4a:e3:cd > fa:16:3e:e5:06:68, ethertype IPv4 (0x0800), length 66: 10.2.1.220.45851 > 10.2.1.201.80: Flags [F.], seq 140, ack 164, win 22, options [nop,nop,TS val 4071122385 ecr 593222586], length 0
16:53:56.108381 fa:16:3e:e5:06:68 > fa:16:3e:4a:e3:cd, ethertype IPv4 (0x0800), length 66: 10.2.1.201.80 > 10.2.1.220.45851: Flags [.], ack 141, win 4075, options [nop,nop,TS val 593222587 ecr 4071122385], length 0
16:53:57.255104 fa:16:3e:e5:06:68 > fa:16:3e:4a:e3:cd, ethertype IPv4 (0x0800), length 74: 10.2.1.201.80 > 10.2.1.220.45847: Flags [S.], seq 1063921752, ack 479897053, win 65330, options [mss 1402,sackOK,TS val 593223734 ecr 4071114320,
16:53:57.256286 fa:16:3e:4a:e3:cd > fa:16:3e:e5:06:68, ethertype IPv4 (0x0800), length 54: 10.2.1.220.45847 > 10.2.1.201.80: Flags [R], seq 479897053, win 0, length 0
The backend server sent the SYN-ACK packets to an incorrect mac address.
This was fixed at 16:53:56.103047 after it sent an ARP request
The actual response of the load balancer was sent 8 sec after the first SYN (while the timeout in octavia-
Searching for the ip address of the member port in the logs:
controller-0
/var/log/
controller-1
/var/log/
controller-2
/var/log/
/var/log/
/var/log/
At 16:39:24, a port 3cca7c41-
At 16:40:08, this port was deleted
At 16:52:38, a port d9ee04bd-
It seems that the cirros VM didn't update the ARP table when it received a packet from the newly created port and replied using the mac address of the old port.
This issue was mitigated automatically after 8 sec but it triggered an error in the test.
Another way to mitigate it would be to send a GARP from the load balancer when a new port is plugged into the amphora.
Changed in octavia: | |
importance: | Undecided → Medium |
status: | New → Confirmed |
assignee: | nobody → Gregory Thiemonge (gthiemonge) |
Changed in octavia: | |
status: | Confirmed → In Progress |
Reviewed: https:/ /review. opendev. org/c/openstack /octavia/ +/879898 /opendev. org/openstack/ octavia/ commit/ 18cd1f34c8a918a b6f969a3271ac74 132c4ac736
Committed: https:/
Submitter: "Zuul (22348)"
Branch: master
commit 18cd1f34c8a918a b6f969a3271ac74 132c4ac736
Author: Gregory Thiemonge <email address hidden>
Date: Fri Apr 7 08:04:45 2023 -0400
Send IP advertisements when plugging a new member subnet
When plugging a new subnet, the amphora sends a packet advertising the
IP address of the port. In case previously deallocated IP addresses are
re-used, it helps the other resources on the same L2 network to flush
the old ARP entries.
Closes-Bug: #2015572
Change-Id: Iecedb9e9c8f293 cd4c067900e1696 f5050769ee8