Skip to content

Commit

Permalink
Merge pull request ovn-kubernetes#4887 from dceara/bump-ovn24.09.1-10
Browse files Browse the repository at this point in the history
Dockerfile.fedora: Bump OVN to ovn24.09-24.09.1-10.fc41
  • Loading branch information
trozet authored Jan 20, 2025
2 parents df55ae6 + 73492d9 commit bc9c081
Show file tree
Hide file tree
Showing 2 changed files with 16 additions and 10 deletions.
2 changes: 1 addition & 1 deletion dist/images/Dockerfile.fedora
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ USER root

ENV PYTHONDONTWRITEBYTECODE yes

ARG ovnver=ovn-24.09.0-33.fc41
ARG ovnver=ovn-24.09.1-10.fc41
# Automatically populated when using docker buildx
ARG TARGETPLATFORM
ARG BUILDPLATFORM
Expand Down
24 changes: 15 additions & 9 deletions test/e2e/external_gateways.go
Original file line number Diff line number Diff line change
Expand Up @@ -1465,6 +1465,13 @@ var _ = ginkgo.Describe("External Gateway", func() {

ginkgo.DescribeTable("Should validate TCP/UDP connectivity even after MAC change (gateway migration) for egress",
func(protocol string, addresses *gatewayTestIPs, destPort, destPortOnPod int) {
ncCmd := func(sourcePort int, target string) []string {
if protocol == "tcp" {
return []string {"exec", srcPingPodName, "--", "bash", "-c", fmt.Sprintf("echo | nc -p %d -s %s -w 1 %s %d", sourcePort, addresses.srcPodIP, target, destPort)}
} else {
return []string {"exec", srcPingPodName, "--", "bash", "-c", fmt.Sprintf("echo | nc -p %d -s %s -w 1 -u %s %d", sourcePort, addresses.srcPodIP, target, destPort)}
}
}
if addresses.srcPodIP == "" || addresses.nodeIP == "" {
skipper.Skipf("Skipping as pod ip / node ip are not set pod ip %s node ip %s", addresses.srcPodIP, addresses.nodeIP)
}
Expand Down Expand Up @@ -1504,13 +1511,8 @@ var _ = ginkgo.Describe("External Gateway", func() {
ginkgo.By("Checking if one of the external gateways are reachable via Egress")
target := addresses.targetIPs[0]
sourcePort := 50000
args := []string{"exec", srcPingPodName, "--"}
if protocol == "tcp" {
args = append(args, "bash", "-c", fmt.Sprintf("echo | nc -p %d -s %s -w 1 %s %d", sourcePort, addresses.srcPodIP, target, destPort))
} else {
args = append(args, "bash", "-c", fmt.Sprintf("echo | nc -p %d -s %s -w 1 -u %s %d", sourcePort, addresses.srcPodIP, target, destPort))
}
res, err := e2ekubectl.RunKubectl(f.Namespace.Name, args...)

res, err := e2ekubectl.RunKubectl(f.Namespace.Name, ncCmd(sourcePort, target)...)
framework.ExpectNoError(err, "failed to reach %s (%s)", target, protocol)
hostname := strings.TrimSuffix(res, "\n")
var gateway string
Expand All @@ -1528,7 +1530,7 @@ var _ = ginkgo.Describe("External Gateway", func() {
tcpDumpSync := sync.WaitGroup{}
tcpDumpSync.Add(1)
go checkReceivedPacketsOnContainer(gateway, srcPingPodName, anyLink, []string{protocol, "and", "port", strconv.Itoa(sourcePort)}, &tcpDumpSync)
res, err = e2ekubectl.RunKubectl(f.Namespace.Name, args...)
res, err = e2ekubectl.RunKubectl(f.Namespace.Name, ncCmd(sourcePort, target)...)
framework.ExpectNoError(err, "failed to reach %s (%s)", target, protocol)
hostname2 := strings.TrimSuffix(res, "\n")
gomega.Expect(hostname).To(gomega.Equal(hostname2))
Expand Down Expand Up @@ -1561,14 +1563,18 @@ var _ = ginkgo.Describe("External Gateway", func() {
time.Sleep(1 * time.Second)

ginkgo.By("Post-Migration: Sending Egress traffic and verify it is received")
// We don't want traffic to hit the already existing conntrack entry (created for source port 50000)
// so we use a fresh source port.
sourcePort = 50001

tcpDumpSync = sync.WaitGroup{}
tcpDumpSync.Add(1)
go checkReceivedPacketsOnContainer(gateway, srcPingPodName, gwLink, []string{protocol, "and", "ether", "host", newDummyMac, "and", "port", strconv.Itoa(sourcePort)}, &tcpDumpSync)
// Sometimes the external gateway will fail to respond to the request with
// SKB_DROP_REASON_NEIGH_FAILED after changing the MAC address. Something breaks with ARP
// on the gateway container. Therefore, ignore the reply from gateway, as we only care about the egress
// packet arriving with correct MAC address.
_, _ = e2ekubectl.RunKubectl(f.Namespace.Name, args...)
_, _ = e2ekubectl.RunKubectl(f.Namespace.Name, ncCmd(sourcePort, target)...)
tcpDumpSync.Wait()

checkAPBExternalRouteStatus(defaultPolicyName)
Expand Down

0 comments on commit bc9c081

Please sign in to comment.