Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

TUN-1.3 Interface based IPv4 GRE Encapsulation #2005

Open
wants to merge 86 commits into
base: main
Choose a base branch
from

Conversation

charantejag504
Copy link
Contributor

TUN-1.3 Interface based IPv4 GRE Encapsulation

Validate the GRE configuration
Configure GRE Tunnel interfaces configuration options - Tunnel source, Tunnel Destination on Tunnel interface
Configure static route with IPv4 NH pointing to Tunnel interfaces
Validate the applied config did not report any errors
Enable the packet capture on ATE ingress port to verify the GRE header of uncapped traffic
Verify the tunnel interfaces counters to confirm the traffic encapsulation
After encapsulation, traffic should be load balanced/hash to all available L3 ECMP or LAG or combination of both features

This resolves 1600

@OpenConfigBot
Copy link

OpenConfigBot commented Aug 11, 2023

Pull Request Functional Test Report for #2005 / 6b2125e

Virtual Devices

Device Test Test Documentation Job Raw Log
Arista cEOS status
TUN-1.3: Interface based IPv4 GRE Encapsulation
Cisco 8000E status
TUN-1.3: Interface based IPv4 GRE Encapsulation
Cisco XRd status
TUN-1.3: Interface based IPv4 GRE Encapsulation
Juniper ncPTX status
TUN-1.3: Interface based IPv4 GRE Encapsulation
Nokia SR Linux status
TUN-1.3: Interface based IPv4 GRE Encapsulation
Openconfig Lemming status
TUN-1.3: Interface based IPv4 GRE Encapsulation

Hardware Devices

Device Test Test Documentation Raw Log
Arista 7808 status
TUN-1.3: Interface based IPv4 GRE Encapsulation
Cisco 8808 status
TUN-1.3: Interface based IPv4 GRE Encapsulation
Juniper PTX10008 status
TUN-1.3: Interface based IPv4 GRE Encapsulation
Nokia 7250 IXR-10e status
TUN-1.3: Interface based IPv4 GRE Encapsulation

Help

@coveralls
Copy link

coveralls commented Aug 17, 2023

Pull Request Test Coverage Report for Build 9555195923

Details

  • 0 of 0 changed or added relevant lines in 0 files are covered.
  • No unchanged relevant lines lost coverage.
  • Overall coverage remained the same at 55.5%

Totals Coverage Status
Change from base Build 9544016298: 0.0%
Covered Lines: 1983
Relevant Lines: 3573

💛 - Coveralls

@r4huluk r4huluk added the new-requirement-pr The PR introduces a new test scenario/requirement. label Nov 9, 2023
@@ -0,0 +1,482 @@
// Copyright 2023 Google LLC
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Change 2023 to 2024

t.Logf("Flow: %s received packets: %d !", flowName, rxPackets)
lostPackets := txPackets - rxPackets
t.Logf("Flow: %s lost packets: %d !", flowName, lostPackets)
lossPct := lostPackets * 100 / txPackets
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Replace lossPct with got and set want := 100.0

initialTunnelOutPkts := make([]uint64, tunnelCount)
tunnelLoadblanceDiff := tunnelCount * 3
interfaceLoadblanceDiff := tolerance
t.Run("Configure dut with 32 tunnel interface with one ingress and 2 egress interface", func(t *testing.T) {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

t.Run() will create sub-testcase. There should be no dependency requirement between sub-testcases as you can run any sub-testcase independently. But, your sub-testcases are required to run one by one in fixed order.

f1v4.Src().Increment().SetStart(peer.IPv4).SetCount(200)
// V4 destination
f1v4.Dst().Increment().SetStart(encapInnerDesIpv4Network).SetCount(200)
// Add L4 protocol
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please remove all comments as traffic flow APIs are self-explanatory and commonly used.

addr := net.ParseIP(address)
var network net.IP

// This mask corresponds to a /24 subnet for IPv4.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

mask is a variable here. /24 is one case. Another call passes 19 as mask value


networkWithMask := network.String() + "/" + strconv.Itoa(mask)
networkAlone := network.String()
//t.Logf("Network address : %s", networkWithMask)
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Remove it if not needed.

hardware_model: "PTX10001-36MR"
hardware_model: "cptx"
}
deviations: {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please mention the bug ID here for new deviations.

We need bugs to track new deviations.

t.Logf("Push the CLI config:\n%s", config)

default:
t.Errorf("Invalid Tunnel endpoint configuration")
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Make error msg more specific. Something like:

Tunnel endpoint configuration is not defined for dut.Vendor().

@sezhang2 sezhang2 self-assigned this Jan 3, 2024
sezhang2
sezhang2 previously approved these changes Jan 3, 2024
Copy link
Contributor

@sezhang2 sezhang2 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please address all the comments in the next PR.

- Tunnel source should be able to configure with unnumbered interface address
- Tunnel Destination
- Directly on Tunnel interface or Tunnel Group
- Configure such 32 tunnel interfaces
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can you please update this to 2k tunnel endpoints to match w/ the HLD requirements?

@sezhang2
Copy link
Contributor

Please fix README

@Swetha-haridasula
Copy link
Contributor

Also kindly update the brach

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
anCX juniper-pr new-requirement-pr The PR introduces a new test scenario/requirement.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

TUN-1.3: GRE IPv4 traffic Encapsulation on IPv4 GRE tunnel