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

feat(pipelined): QFI support in Pipelined and Sessiond #12529

Merged
merged 1 commit into from Aug 8, 2022

Conversation

prabinakpattnaik
Copy link
Contributor

Signed-off-by: prabina pattnaik prabinak@wavelabs.ai

Summary

AMBR Based QFI support in pipelined and sessiond for 5G SA.
QFI value Set per PDU session.
The QFI that identifies the flow is carried in an extension header on N3 in the GTP-U protocol, using DL and UL PDU session information frames.
The DL and UL PDU session information frame includes a QoS Flow Identifier (QFI) field for each packet.

Test Plan

Please find UT logs:

(python) vagrant@magma-dev-focal:~/magma/lte/gateway/python/scripts$ python smf_upf_integration_cli.py amf_context set_amf_session_tc1
=========TEST CASE-1 PDU SESSION ESTABLISHMENT===========
common_context {
  sid {
    id: "IMSI12345"
  }
  ue_ipv4: "192.168.128.11"
  apn: "BLR"
  rat_type: TGPP_NR
}
rat_specific_context {
  m5gsm_session_context {
    pdu_session_id: 1
    ssc_mode: SSC_MODE_3
    gnode_endpoint {
      teid: 10000
      end_ipv4_addr: "192.168.60.16"
    }
    subscribed_qos {
      apn_ambr_dl: 1000000
      apn_ambr_ul: 750000
      priority_level: 1
      preemption_capability: MAY_TRIGGER_PRE_EMPTION
      preemption_vulnerability: PRE_EMPTABLE
      qos_class_id: QCI_9
      br_unit: KBPS
    }
  }
}
================================================================
Apr 22 05:52:53 magma-dev-focal pipelined[164137]: INFO:root:Got RPC payload:
Apr 22 05:52:53 magma-dev-focal pipelined[164137]:   SessionSet {
Apr 22 05:52:53 magma-dev-focal pipelined[164137]:     subscriber_id: "IMSI12345"
Apr 22 05:52:53 magma-dev-focal pipelined[164137]:     local_f_teid: 2147483648
Apr 22 05:52:53 magma-dev-focal pipelined[164137]:     session_version: 1
Apr 22 05:52:53 magma-dev-focal pipelined[164137]:     node_id {
Apr 22 05:52:53 magma-dev-focal pipelined[164137]:       node_id: "192.168.200.1"
Apr 22 05:52:53 magma-dev-focal pipelined[164137]:     }
Apr 22 05:52:53 magma-dev-focal pipelined[164137]:     state {
Apr 22 05:52:53 magma-dev-focal pipelined[164137]:       state: CREATED
Apr 22 05:52:53 magma-dev-focal pipelined[164137]:     }
Apr 22 05:52:53 magma-dev-focal pipelined[164137]:     set_gr_pdr {
Apr 22 05:52:53 magma-dev-focal pipelined[164137]:       pdr_id: 1
Apr 22 05:52:53 magma-dev-focal pipelined[164137]:       pdr_version: 1
Apr 22 05:52:53 magma-dev-focal pipelined[164137]:       precedence: 32
Apr 22 05:52:53 magma-dev-focal pipelined[164137]:       pdi {
Apr 22 05:52:53 magma-dev-focal pipelined[164137]:         local_f_teid: 2147483648
Apr 22 05:52:53 magma-dev-focal pipelined[164137]:         net_instance: "uplink"
Apr 22 05:52:53 magma-dev-focal pipelined[164137]:         ue_ipv4: "192.168.128.11"
Apr 22 05:52:53 magma-dev-focal pipelined[164137]:       }
Apr 22 05:52:53 magma-dev-focal pipelined[164137]:       set_gr_far {
Apr 22 05:52:53 magma-dev-focal pipelined[164137]:         far_action_to_apply: FORW
Apr 22 05:52:53 magma-dev-focal pipelined[164137]:       }
Apr 22 05:52:53 magma-dev-focal pipelined[164137]:       deactivate_flow_req {
Apr 22 05:52:53 magma-dev-focal pipelined[164137]:         sid {
Apr 22 05:52:53 magma-dev-focal pipelined[164137]:           id: "IMSI12345"
Apr 22 05:52:53 magma-dev-focal pipelined[164137]:         }
Apr 22 05:52:53 magma-dev-focal pipelined[164137]:         ip_addr: "192.168.128.11"
Apr 22 05:52:53 magma-dev-focal pipelined[164137]:         uplink_tunnel: 2147483648
Apr 22 05:52:53 magma-dev-focal pipelined[164137]:       }
Apr 22 05:52:53 magma-dev-focal pipelined[164137]:       activate_flow_req {
Apr 22 05:52:53 magma-dev-focal pipelined[164137]:         sid {
Apr 22 05:52:53 magma-dev-focal pipelined[164137]:           id: "IMSI12345"
Apr 22 05:52:53 magma-dev-focal pipelined[164137]:         }
Apr 22 05:52:53 magma-dev-focal pipelined[164137]:         ip_addr: "192.168.128.11"
Apr 22 05:52:53 magma-dev-focal pipelined[164137]:         request_origin {
Apr 22 05:52:53 magma-dev-focal pipelined[164137]:           type: N4
Apr 22 05:52:53 magma-dev-focal pipelined[164137]:         }
Apr 22 05:52:53 magma-dev-focal pipelined[164137]:         apn_ambr {
Apr 22 05:52:53 magma-dev-focal pipelined[164137]:           max_bandwidth_ul: 750000
Apr 22 05:52:53 magma-dev-focal pipelined[164137]:           max_bandwidth_dl: 1000000
Apr 22 05:52:53 magma-dev-focal pipelined[164137]:         }
Apr 22 05:52:53 magma-dev-focal pipelined[164137]:         uplink_tunnel: 2147483648
Apr 22 05:52:53 magma-dev-focal pipelined[164137]:         policies {
Apr 22 05:52:53 magma-dev-focal pipelined[164137]:           rule {
Apr 22 05:52:53 magma-dev-focal pipelined[164137]:             id: "allowlist_sid-IMSI12345-BLR"
Apr 22 05:52:53 magma-dev-focal pipelined[164137]:             priority: 2
Apr 22 05:52:53 magma-dev-focal pipelined[164137]:             flow_list {
Apr 22 05:52:53 magma-dev-focal pipelined[164137]:               match {
Apr 22 05:52:53 magma-dev-focal pipelined[164137]:               }
Apr 22 05:52:53 magma-dev-focal pipelined[164137]:             }
Apr 22 05:52:53 magma-dev-focal pipelined[164137]:             qos {
Apr 22 05:52:53 magma-dev-focal pipelined[164137]:             }
Apr 22 05:52:53 magma-dev-focal pipelined[164137]:             tracking_type: NO_TRACKING
Apr 22 05:52:53 magma-dev-focal pipelined[164137]:           }
Apr 22 05:52:53 magma-dev-focal pipelined[164137]:           version: 1
Apr 22 05:52:53 magma-dev-focal pipelined[164137]:         }
Apr 22 05:52:53 magma-dev-focal pipelined[164137]:       }
Apr 22 05:52:53 magma-dev-focal pipelined[164137]:       session_qfi: QCI_9
Apr 22 05:52:53 magma-dev-focal pipelined[164137]:     }
Apr 22 05:52:53 magma-dev-focal pipelined[164137]:     set_gr_pdr {
Apr 22 05:52:53 magma-dev-focal pipelined[164137]:       pdr_id: 2
Apr 22 05:52:53 magma-dev-focal pipelined[164137]:       pdr_version: 1
Apr 22 05:52:53 magma-dev-focal pipelined[164137]:       precedence: 32
Apr 22 05:52:53 magma-dev-focal pipelined[164137]:       pdi {
Apr 22 05:52:53 magma-dev-focal pipelined[164137]:         src_interface: 1
Apr 22 05:52:53 magma-dev-focal pipelined[164137]:         net_instance: "downlink"
Apr 22 05:52:53 magma-dev-focal pipelined[164137]:         ue_ipv4: "192.168.128.11"
Apr 22 05:52:53 magma-dev-focal pipelined[164137]:       }
Apr 22 05:52:53 magma-dev-focal pipelined[164137]:       set_gr_far {
Apr 22 05:52:53 magma-dev-focal pipelined[164137]:         far_action_to_apply: FORW
Apr 22 05:52:53 magma-dev-focal pipelined[164137]:         fwd_parm {
Apr 22 05:52:53 magma-dev-focal pipelined[164137]:           outr_head_cr {
Apr 22 05:52:53 magma-dev-focal pipelined[164137]:             o_teid: 10000
Apr 22 05:52:53 magma-dev-focal pipelined[164137]:             gnb_ipv4_adr: "192.168.60.16"
Apr 22 05:52:53 magma-dev-focal pipelined[164137]:           }
Apr 22 05:52:53 magma-dev-focal pipelined[164137]:         }
Apr 22 05:52:53 magma-dev-focal pipelined[164137]:       }
Apr 22 05:52:53 magma-dev-focal pipelined[164137]:       deactivate_flow_req {
Apr 22 05:52:53 magma-dev-focal pipelined[164137]:         sid {
Apr 22 05:52:53 magma-dev-focal pipelined[164137]:           id: "IMSI12345"
Apr 22 05:52:53 magma-dev-focal pipelined[164137]:         }
Apr 22 05:52:53 magma-dev-focal pipelined[164137]:         ip_addr: "192.168.128.11"
Apr 22 05:52:53 magma-dev-focal pipelined[164137]:         request_origin {
Apr 22 05:52:53 magma-dev-focal pipelined[164137]:           type: N4
Apr 22 05:52:53 magma-dev-focal pipelined[164137]:         }
Apr 22 05:52:53 magma-dev-focal pipelined[164137]:         apn_ambr {
Apr 22 05:52:53 magma-dev-focal pipelined[164137]:           max_bandwidth_ul: 750000
Apr 22 05:52:53 magma-dev-focal pipelined[164137]:           max_bandwidth_dl: 1000000
Apr 22 05:52:53 magma-dev-focal pipelined[164137]:         }
Apr 22 05:52:53 magma-dev-focal pipelined[164137]:         downlink_tunnel: 10000
Apr 22 05:52:53 magma-dev-focal pipelined[164137]:         policies {
Apr 22 05:52:53 magma-dev-focal pipelined[164137]:           rule {
Apr 22 05:52:53 magma-dev-focal pipelined[164137]:             id: "allowlist_sid-IMSI12345-BLR"
Apr 22 05:52:53 magma-dev-focal pipelined[164137]:             priority: 2
Apr 22 05:52:53 magma-dev-focal pipelined[164137]:             flow_list {
Apr 22 05:52:53 magma-dev-focal pipelined[164137]:               match {
Apr 22 05:52:53 magma-dev-focal pipelined[164137]:                 direction: DOWNLINK
Apr 22 05:52:53 magma-dev-focal pipelined[164137]:               }
Apr 22 05:52:53 magma-dev-focal pipelined[164137]:             }
Apr 22 05:52:53 magma-dev-focal pipelined[164137]:             qos {
Apr 22 05:52:53 magma-dev-focal pipelined[164137]:             }
Apr 22 05:52:53 magma-dev-focal pipelined[164137]:             tracking_type: NO_TRACKING
Apr 22 05:52:53 magma-dev-focal pipelined[164137]:           }
Apr 22 05:52:53 magma-dev-focal pipelined[164137]:           version: 1
Apr 22 05:52:53 magma-dev-focal pipelined[164137]:         }
Apr 22 05:52:53 magma-dev-focal pipelined[164137]:       }
Apr 22 05:52:53 magma-dev-focal pipelined[164137]:       session_qfi: QCI_9
Apr 22 05:52:53 magma-dev-focal pipelined[164137]:     }
Apr 22 05:52:53 magma-dev-focal pipelined[164137]:   }

Table 0 flow entries:

(python) vagrant@magma-dev-focal:~/magma/lte/gateway/python/scripts$ sudo ovs-ofctl -O OpenFlow13 dump-flows gtp_br0 table=0
 cookie=0x0, duration=24.707s, table=0, n_packets=0, n_bytes=0, priority=65503,tun_id=0x80000000,qfi=9,in_port=gtp0 actions=set_field:02:00:00:00:00:01->eth_src,set_field:ff:ff:ff:ff:ff:ff->eth_dst,set_field:0->reg9,set_field:0x181c9->metadata,resubmit(,1)
 cookie=0x0, duration=24.680s, table=0, n_packets=0, n_bytes=0, priority=65503,ip,in_port=LOCAL,nw_dst=192.168.128.11 actions=set_field:0x2710->tun_id,set_field:192.168.60.16->tun_dst,set_field:0x8000->reg8,set_field:oam->tun_flags,set_field:0x9->qfi,set_field:0x181c9->metadata,resubmit(,1)
 cookie=0x0, duration=24.680s, table=0, n_packets=0, n_bytes=0, priority=65503,ip,in_port=mtr0,nw_dst=192.168.128.11 actions=set_field:0x2710->tun_id,set_field:192.168.60.16->tun_dst,set_field:0x8000->reg8,set_field:oam->tun_flags,set_field:0x9->qfi,set_field:0x181c9->metadata,resubmit(,1)
 cookie=0x0, duration=24.680s, table=0, n_packets=0, n_bytes=0, priority=65503,arp,in_port=LOCAL,arp_tpa=192.168.128.11 actions=set_field:0x181c9->metadata,resubmit(,1)
 cookie=0x0, duration=24.680s, table=0, n_packets=0, n_bytes=0, priority=65503,arp,in_port=mtr0,arp_tpa=192.168.128.11 actions=set_field:0x181c9->metadata,resubmit(,1)
 cookie=0x0, duration=64981.449s, table=0, n_packets=27, n_bytes=1890, priority=10,in_port=ipfix0 actions=goto_table:201
 cookie=0x0, duration=64976.292s, table=0, n_packets=0, n_bytes=0, priority=0,in_port=ipfix0 actions=resubmit(,201)
 cookie=0x0, duration=64976.292s, table=0, n_packets=23, n_bytes=1610, priority=0,in_port="li_port" actions=resubmit(,202)
 cookie=0x0, duration=64976.292s, table=0, n_packets=206, n_bytes=15712, priority=0 actions=resubmit(,1)

Additional Information

@prabinakpattnaik prabinakpattnaik requested review from a team April 22, 2022 06:08
@prabinakpattnaik prabinakpattnaik requested a review from a team as a code owner April 22, 2022 06:08
@pull-request-size pull-request-size bot added the size/XL Denotes a Pull Request that changes 500-999 lines. label Apr 22, 2022
@github-actions
Copy link
Contributor

Thanks for opening a PR! 💯

A couple initial guidelines

Howto

  • Reviews. The "Reviewers" listed for this PR are the Magma maintainers who will shepherd it.
  • Checks. All required CI checks must pass before merge.
  • Merge. Once approved and passing CI checks, use the ready2merge label to indicate the maintainers can merge your PR.

More info

Please take a moment to read through the Magma project's

If this is your first Magma PR, also consider reading

@github-actions github-actions bot added component: agw Access gateway-related issue component: orc8r Orchestrator-related issue labels Apr 22, 2022
@github-actions
Copy link
Contributor

github-actions bot commented Apr 22, 2022

Oops! Looks like you failed the Python Format Check.

Howto

♻️ Updated: ✅ The check is passing the Python Format Check after the last commit.

@github-actions
Copy link
Contributor

github-actions bot commented Apr 22, 2022

feg-workflow

    2 files  203 suites   39s ⏱️
374 tests 374 ✔️ 0 💤 0
388 runs  388 ✔️ 0 💤 0

Results for commit 56da628.

♻️ This comment has been updated with latest results.

@github-actions
Copy link
Contributor

github-actions bot commented Apr 22, 2022

cloud-workflow

755 tests   754 ✔️  2m 44s ⏱️
297 suites      0 💤
    4 files        1

For more details on these failures, see this check.

Results for commit f046195.

♻️ This comment has been updated with latest results.

@github-actions
Copy link
Contributor

github-actions bot commented Apr 22, 2022

agw-workflow

615 tests   611 ✔️  4m 0s ⏱️
    2 suites      4 💤
    2 files        0

Results for commit 56da628.

♻️ This comment has been updated with latest results.

@@ -866,6 +866,14 @@ bool SessionStateEnforcer::insert_pdr_from_core(
rule.mutable_activate_flow_req()->set_downlink_tunnel(teid);
rule.mutable_deactivate_flow_req()->set_downlink_tunnel(teid);

/*Set the AMBR QCI Value */
Copy link
Contributor

Choose a reason for hiding this comment

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

Same set of lines repeated in another function. Can we move these to a new function and call that function from two places wherever it needed.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Agreed. Moved to common place function.

Copy link
Contributor

@koolzz koolzz left a comment

Choose a reason for hiding this comment

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

pipelined changes look fine to me

Copy link
Contributor

@GANESH-WAVELABS GANESH-WAVELABS left a comment

Choose a reason for hiding this comment

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

Sessiond Changes LGTM!!

@prabinakpattnaik
Copy link
Contributor Author

This PR is dependency with RYU changes (#12514 ).
First RYU changes PR needs to be merged then this PR.

Copy link
Contributor

@pshelar pshelar left a comment

Choose a reason for hiding this comment

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

We need unit test that matches and sets QFI field in OVS flows.

@themarwhal themarwhal removed their request for review April 25, 2022 14:55
@prabinakpattnaik
Copy link
Contributor Author

@pshelar , right now RYU and OVS changes are not present in master. So UT for QFI set value will not work and will get python traceback.

My suggestion is that Will create new PR for UT once all three PRs (#10556 , #12514 and this PR) are getting merge into Master. Please provide any other solution or suggestion.

@pshelar
Copy link
Contributor

pshelar commented Apr 25, 2022

@pshelar , right now RYU and OVS changes are not present in master. So UT for QFI set value will not work and will get python traceback.

My suggestion is that Will create new PR for UT once all three PRs (#10556 , #12514 and this PR) are getting merge into Master. Please provide any other solution or suggestion.

can we wait for other PRs to merge ?

@prabinakpattnaik
Copy link
Contributor Author

Yes, We can wait for it and even we can not push this PR until unless RYU and OVS not merged

@@ -346,6 +346,7 @@ message SetGroupPDR {
SetGroupFAR set_gr_far = 8;
DeactivateFlowsRequest deactivate_flow_req = 9;
ActivateFlowsRequest activate_flow_req = 10;
QCI session_qfi = 11;
Copy link
Contributor

@nstng nstng May 10, 2022

Choose a reason for hiding this comment

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

Why is the QFI typed to QCI? My understanding is that the QFI is some dynamic identifier and the QCI classifies by a fixed value.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

The QFI may be dynamically assigned or may be equal to the 5QI. So here, QFI (5G) is used as QCI (4G).

@github-actions
Copy link
Contributor

github-actions bot commented May 16, 2022

dp-workflow

15 tests   15 ✔️  3m 50s ⏱️
  1 suites    0 💤
  1 files      0

Results for commit 56da628.

♻️ This comment has been updated with latest results.

@maxhbr
Copy link
Member

maxhbr commented Jun 13, 2022

This PR has merge conflicts: lte/gateway/python/magma/pipelined/app/classifier.py

@panyogesh panyogesh requested a review from pshelar July 21, 2022 11:47
@panyogesh
Copy link
Contributor

unit test that matches and sets QFI field in O

Unit testing add.

Copy link
Contributor

@panyogesh panyogesh left a comment

Choose a reason for hiding this comment

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

LGTM

@maxhbr
Copy link
Member

maxhbr commented Jul 25, 2022

The CI flaggs the following:

 The following files are not covered by a BUILD.bazel files:
./lte/gateway/python/magma/pipelined/tests/test_qfi_gtp.py

@prabinakpattnaik
Copy link
Contributor Author

@maxhbr , changes done. We have added the test_qfi_gtp.py in BUILD.bazel

Copy link
Contributor

@nstng nstng left a comment

Choose a reason for hiding this comment

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

Hi, executing the bazelified test on the magma VM fails - ./bazel/scripts/run_sudo_tests.sh lte/gateway/python/magma/pipelined/tests:test_qfi_gtp. I realize that the ryu patches from #12514 are missing for the bazel case. Do you want to add them here or should I raise a separate PR that needs to be merged first? Edit: I went ahead and created #13437 - this becomes hopefully merged fast.
After adding the patches, the test QfigtpTest::test_qfi_set_tunnel_flows still fails for me with a flow diff [1]. I will check if I can reproduce this with the make build and come back to you.

Edit: I have the same result when executing the test on the make build. Please have a look.

[1]

E   - cookie=0x0, table=classifier(main_table), n_packets=0, n_bytes=0, priority=10,tun_id=0x1,qfi=9,in_port=32768 actions=mod_dl_src:02:00:00:00:00:01,mod_dl_dst:ff:ff:ff:ff:ff:ff,set_field:0x186a0->reg9,load:0x1388->OXM_OF_METADATA[],resubmit(,ingress(main_table))
E   - cookie=0x0, table=classifier(main_table), n_packets=0, n_bytes=0, priority=10,ip,in_port=LOCAL,nw_dst=192.168.128.30 actions=load:0x186a0->NXM_NX_TUN_ID[],load:0xc0a83cb2->NXM_NX_TUN_IPV4_DST[],set_field:0x8000->reg8,load:0x1->NXM_NX_TUN_FLAGS[],load:0x9->NXM_NX_QFI[],set_field:0x1->reg9,load:0x1388->OXM_OF_METADATA[],resubmit(,ingress(main_table))
E   - cookie=0x0, table=classifier(main_table), n_packets=0, n_bytes=0, priority=10,ip,in_port=15577,nw_dst=192.168.128.30 actions=load:0x186a0->NXM_NX_TUN_ID[],load:0xc0a83cb2->NXM_NX_TUN_IPV4_DST[],set_field:0x8000->reg8,load:0x1->NXM_NX_TUN_FLAGS[],load:0x9->NXM_NX_QFI[],set_field:0x1->reg9,load:0x1388->OXM_OF_METADATA[],resubmit(,ingress(main_table))
E     cookie=0x0, table=classifier(main_table), n_packets=0, n_bytes=0, priority=10,arp,in_port=LOCAL,arp_tpa=192.168.128.30 actions=load:0x1388->OXM_OF_METADATA[],resubmit(,ingress(main_table))
E     cookie=0x0, table=classifier(main_table), n_packets=0, n_bytes=0, priority=10,arp,in_port=15577,arp_tpa=192.168.128.30 actions=load:0x1388->OXM_OF_METADATA[],resubmit(,ingress(main_table))
E   To fix the error, update "/home/vagrant/magma/lte/gateway/python/magma/pipelined/tests/snapshots/test_qfi_gtp.QfigtpTest.test_qfi_set_tunnel_flows.snapshot" to the current snapshot:
E    cookie=0x0, table=classifier(main_table), n_packets=0, n_bytes=0, priority=10,arp,in_port=LOCAL,arp_tpa=192.168.128.30 actions=load:0x1388->OXM_OF_METADATA[],resubmit(,ingress(main_table))
E    cookie=0x0, table=classifier(main_table), n_packets=0, n_bytes=0, priority=10,arp,in_port=15577,arp_tpa=192.168.128.30 actions=load:0x1388->OXM_OF_METADATA[],resubmit(,ingress(main_table))

@prabinakpattnaik
Copy link
Contributor Author

@nstng , after apply #13437 patch, it's working fine for Bazel. Please find the output:

lte/gateway/python/magma/pipelined/tests/test_qfi_gtp.py::QfigtpTest::test_qfi_delete_tunnel_flows PASSED                                             [ 50%]
lte/gateway/python/magma/pipelined/tests/test_qfi_gtp.py::QfigtpTest::test_qfi_set_tunnel_flows PASSED                                                [100%]

===================================================================== warnings summary ======================================================================
bazel-bin/lte/gateway/python/magma/pipelined/tests/test_qfi_gtp.runfiles/python_deps_pypi__prometheus_client/prometheus_client/decorator.py:81
  /home/vagrant/magma/bazel-bin/lte/gateway/python/magma/pipelined/tests/test_qfi_gtp.runfiles/python_deps_pypi__prometheus_client/prometheus_client/decorator.py:81: DeprecationWarning: invalid escape sequence \s
    DEF = re.compile('\s*def\s*([_\w][_\w\d]*)\s*\(')

bazel-bin/lte/gateway/python/magma/pipelined/tests/test_qfi_gtp.runfiles/python_deps_pypi__eventlet/eventlet/patcher.py:1
  /home/vagrant/magma/bazel-bin/lte/gateway/python/magma/pipelined/tests/test_qfi_gtp.runfiles/python_deps_pypi__eventlet/eventlet/patcher.py:1: DeprecationWarning: the imp module is deprecated in favour of importlib; see the module's documentation for alternative uses
    import imp

bazel-bin/lte/gateway/python/magma/pipelined/tests/test_qfi_gtp.runfiles/python_deps_pypi__dnspython/dns/hash.py:23
  /home/vagrant/magma/bazel-bin/lte/gateway/python/magma/pipelined/tests/test_qfi_gtp.runfiles/python_deps_pypi__dnspython/dns/hash.py:23: DeprecationWarning: dns.hash module will be removed in future versions. Please use hashlib instead.
    warnings.warn(

bazel-bin/lte/gateway/python/magma/pipelined/tests/test_qfi_gtp.runfiles/python_deps_pypi__dnspython/dns/namedict.py:35
  /home/vagrant/magma/bazel-bin/lte/gateway/python/magma/pipelined/tests/test_qfi_gtp.runfiles/python_deps_pypi__dnspython/dns/namedict.py:35: DeprecationWarning: Using or importing the ABCs from 'collections' instead of from 'collections.abc' is deprecated since Python 3.3, and in 3.10 it will stop working
    class NameDict(collections.MutableMapping):

bazel-bin/lte/gateway/python/magma/pipelined/tests/test_qfi_gtp.runfiles/python_deps_pypi__dnspython/dns/zone.py:737
  /home/vagrant/magma/bazel-bin/lte/gateway/python/magma/pipelined/tests/test_qfi_gtp.runfiles/python_deps_pypi__dnspython/dns/zone.py:737: DeprecationWarning: invalid escape sequence \$
    is_generate1 = re.compile("^.*\$({(\+|-?)(\d+),(\d+),(.)}).*$")

bazel-bin/lte/gateway/python/magma/pipelined/tests/test_qfi_gtp.runfiles/python_deps_pypi__dnspython/dns/zone.py:738
  /home/vagrant/magma/bazel-bin/lte/gateway/python/magma/pipelined/tests/test_qfi_gtp.runfiles/python_deps_pypi__dnspython/dns/zone.py:738: DeprecationWarning: invalid escape sequence \$
    is_generate2 = re.compile("^.*\$({(\+|-?)(\d+)}).*$")

bazel-bin/lte/gateway/python/magma/pipelined/tests/test_qfi_gtp.runfiles/python_deps_pypi__dnspython/dns/zone.py:739
  /home/vagrant/magma/bazel-bin/lte/gateway/python/magma/pipelined/tests/test_qfi_gtp.runfiles/python_deps_pypi__dnspython/dns/zone.py:739: DeprecationWarning: invalid escape sequence \$
    is_generate3 = re.compile("^.*\$({(\+|-?)(\d+),(\d+)}).*$")

bazel-bin/lte/gateway/python/magma/pipelined/tests/test_qfi_gtp.runfiles/ryu_repo/ryu/lib/packet/cfm.py:271
  /home/vagrant/magma/bazel-bin/lte/gateway/python/magma/pipelined/tests/test_qfi_gtp.runfiles/ryu_repo/ryu/lib/packet/cfm.py:271: SyntaxWarning: "is not" with a literal. Did you mean "!="?
    assert interval is not 0

bazel-bin/lte/gateway/python/magma/pipelined/tests/test_qfi_gtp.runfiles/python_deps_pypi__pymemoize/memoize/options.py:2
  /home/vagrant/magma/bazel-bin/lte/gateway/python/magma/pipelined/tests/test_qfi_gtp.runfiles/python_deps_pypi__pymemoize/memoize/options.py:2: DeprecationWarning: Using or importing the ABCs from 'collections' instead of from 'collections.abc' is deprecated since Python 3.3, and in 3.10 it will stop working
    from collections import Callable

bazel-bin/lte/gateway/python/magma/pipelined/tests/test_qfi_gtp.runfiles/bcc_repo/bcc/__init__.py:745
  /home/vagrant/magma/bazel-bin/lte/gateway/python/magma/pipelined/tests/test_qfi_gtp.runfiles/bcc_repo/bcc/__init__.py:745: DeprecationWarning: invalid escape sequence \.
    elif re.match(b'^.*\.cold(\.\d+)?$', fn):

-- Docs: https://docs.pytest.org/en/stable/how-to/capture-warnings.html
============================================================== 2 passed, 10 warnings in 14.16s ==============================================================
SUMMARY: 1/1 tests were successful.
  lte/gateway/python/magma/pipelined/tests:test_qfi_gtp: PASSED
vagrant@magma-dev-focal:~/magma$

Looks like you need to upgrade the VM and latest OVS patch is not applied in your vm.

@nstng
Copy link
Contributor

nstng commented Jul 27, 2022

Looks like you need to upgrade the VM and latest OVS patch is not applied in your vm.

Hi @prabinakpattnaik thanks for checking. What VM upgrade/OVS patch do you mean? I built the VM from scratch based on this branch.

@prabinakpattnaik
Copy link
Contributor Author

@nstng , for this PR dependent on latest OVS packages like libopenvswitch-dev_2.15.4-9_amd64.deb .
Please make sure your VM should be installed on latest OVS packages.
By default new VM is taking OVS-2.14.3

Below is the steps for upgrade the packages:

sudo apt update
sudo apt list --upgradable
sudo apt upgrade

@nstng
Copy link
Contributor

nstng commented Jul 27, 2022

@prabinakpattnaik got it, I will set this up tomorrow and run the test again.

But this means, that merging this PR is blocked until a new magma VM base image is pre-burned, right?

Edit: tested with ovs 2.15.4-9 -> successful. I will leave my change request open so that this PR does not get accidentally merged before

@prabinakpattnaik
Copy link
Contributor Author

@nstng , Yes, this PR is blocked until a new magma VM base image is pre-burned.

@panyogesh panyogesh requested a review from nstng August 8, 2022 03:26
Copy link
Contributor

@nstng nstng left a comment

Choose a reason for hiding this comment

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

bazel changes lgtm

Signed-off-by: prabina pattnaik <prabinak@wavelabs.ai>
@prabinakpattnaik
Copy link
Contributor Author

Rebased with master. Verified the s1ap test cases for traffic and 5G traffic testing. It's working for all cases. Please find the attached logs as reference.
s1aplogs2.txt
uegnbgtp.zip

@maxhbr
Copy link
Member

maxhbr commented Aug 8, 2022

you run the following integtests:

1:vagrant@magma-test:~/magma/lte/gateway/python/integ_tests$ make integ_test TESTS=s1aptests/test_attach_ul_tcp_data.py
69:vagrant@magma-test:~/magma/lte/gateway/python/integ_tests$ make integ_test TESTS=s1aptests/test_attach_dl_udp_data.py
139:vagrant@magma-test:~/magma/lte/gateway/python/integ_tests$ make integ_test TESTS=s1aptests/test_attach_service_with_multi_pdns_and_bearers_mt_data.py
267:vagrant@magma-test:~/magma/lte/gateway/python/integ_tests$ make integ_test TESTS=s1aptests/test_attach_ul_udp_data.py
336:vagrant@magma-test:~/magma/lte/gateway/python/integ_tests$ make integ_test TESTS=s1aptests/test_attach_detach_setsessionrules_tcp_data.py
477:vagrant@magma-test:~/magma/lte/gateway/python/integ_tests$ make integ_test TESTS=s1aptests/test_paging_after_mme_restart.py
568:vagrant@magma-test:~/magma/lte/gateway/python/integ_tests$ make integ_test TESTS=s1aptests/test_attach_detach_attach_dl_tcp_data.py
648:vagrant@magma-test:~/magma/lte/gateway/python/integ_tests$ make integ_test TESTS=s1aptests/test_attach_detach_attach_ul_tcp_data.py
724:vagrant@magma-test:~/magma/lte/gateway/python/integ_tests$ make integ_test TESTS=s1aptests/test_attach_detach_multiple_rar_tcp_data.py
815:vagrant@magma-test:~/magma/lte/gateway/python/integ_tests$ make integ_test TESTS=s1aptests/test_attach_detach_rar_tcp_data.py

is that a complete list? why don't you just run all of them?

@prabinakpattnaik
Copy link
Contributor Author

Changes related to traffic flows in OVS.
So, for quick verification for we just ran the tcs which can impact with changes.

@koolzz
Copy link
Contributor

koolzz commented Aug 8, 2022

@pshelar can you approve as its blocked on your request for change

@pshelar pshelar merged commit 8f54687 into magma:master Aug 8, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
component: agw Access gateway-related issue component: orc8r Orchestrator-related issue size/XL Denotes a Pull Request that changes 500-999 lines.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

7 participants