Skip to content

Commit

Permalink
Apply suggestions from code review
Browse files Browse the repository at this point in the history
Co-authored-by: Derek G Foster <[email protected]>
Signed-off-by: Naveen Ashok <[email protected]>
  • Loading branch information
naveenashok211 and ffoulkes committed Sep 11, 2024
1 parent 4371639 commit ad5ea46
Showing 1 changed file with 20 additions and 20 deletions.
40 changes: 20 additions & 20 deletions ovs_offload/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
- The ovs_offload_lnw.py script can be used on an host server connected with Intel® Infrastructure Processing Unit via PCIe.
- It creates the configuration to run the Linux Networking Recipe with OVS Offload on the ACC.
- It can be used to start infrap4d on the ACC and use the script generated p4rt-ctl rules to configure ACC Port representors for the Host IDPF interfaces and IPU Physical Ports.
- It can setup OVS bridges on the ACC using the port representors and configure VMs on the IDPF interfaces on the Host.
- It can set up OVS bridges on the ACC using the port representors and configure VMs on the IDPF interfaces on the Host.

## Test Environment Setup

Expand All @@ -18,10 +18,10 @@ Check file /etc/ssh/sshd_config and change PermitRootLogin yes
40:PermitRootLogin yes
```

### Pre-requisites
### Prerequisites

- The host package ``intel-ipu-host-components-<version>.<build number>.tar.gz`` contains the example IPU P4 source code, the compiled P4 package and artifacts that can be used to setup the workload on the IMC and ACC.
- The compiled artifacts for P4 ``fxp-net_linux-networking`` can be found in below location after extracting the tar package.
- The host package `intel-ipu-host-components-<version>.<build number>.tar.gz` contains the example IPU P4 source code, the compiled P4 package, and artifacts that can be used to set up the workload on the IMC and ACC.
- The compiled artifacts for P4 `fxp-net_linux-networking` can be found in the location below after you extract the tar package.

```bash
cd intel-ipu-host-components/P4Tools/P4Programs/artifacts/fxp-net_linux-networking
Expand Down Expand Up @@ -68,9 +68,9 @@ usage: tmux [-2CDlNuvV] [-c shell-command] [-f file] [-L socket-name]
[-S socket-path] [-T features] [command [flags]]
```
### Test Configuration config.yaml
### Test Configuration (config.yaml)
- Update yaml file config.yaml for the specific test setup, change the management IP, username and password for imc and acc if it is different.
- Update yaml file config.yaml for the specific test setup. Change the management IP, username, and password for imc and acc if they are different.
- Update the test_params section as required for the setup with the correct host, imc and acc script paths.
- Update the idpf_interface, vf_interfaces, acc_pr_interfaces and ip_list as required to scale up or scale down on the number of interface configuration generated by the script. More information on the fields in the comments below.
Expand Down Expand Up @@ -206,7 +206,7 @@ source venv/bin/activate
-rwxr-xr-x. 1 admin12 admin12 2.8K Aug 28 13:37 7_host_vm.sh
```
3. copy_script: This will create the configuration scripts in the script directory (can be changes in **host_path** in **config.yaml**) at **ovs_offload/ovs_offload_lnw_scripts** and also copy it to the ACC to the acc_path field provided in the **config file:config.yaml**
3. copy_script: This will create the configuration scripts in the script directory (can be changed in **host_path** in **config.yaml**) at **ovs_offload/ovs_offload_lnw_scripts** and also copy it to the ACC to the acc_path field provided in the **config file:config.yaml**
```bash
> python ovs_offload_lnw.py copy_script
Expand Down Expand Up @@ -250,8 +250,8 @@ source venv/bin/activate
> python ovs_offload_lnw.py teardown
```
- This will teardown the complete OVS offload recipe.
- Pre-Requisite: run copy_script option once for scripts to be available in ACC
- This will tear down the complete OVS offload recipe.
- Prerequisite: run copy_script option once for scripts to be available in ACC
- Configure TMUX session - test3_host delete the VMs on Host and remove the link partner configuration.
- Configure TMUX session - test2_p4rt delete the p4rt-ctl rules and delete the OVS bridges
- Configure TMUX session - test1_infrap4d, login to ACC and stop infrap4d,
Expand Down Expand Up @@ -331,8 +331,8 @@ source venv/bin/activate
### 3. Start Infrap4d
- Use the ovs_offload_lnw_scripts in the ACC to setup infrap4d, p4rt and OVS bridge:
- ACC Terminal 1 : Setup environment and start Infrap4d
- Use the ovs_offload_lnw_scripts in the ACC to set up infrap4d, p4rt and OVS bridge:
- ACC Terminal 1 : Set up environment and start Infrap4d
```bash
[root@ipu-acc ~]# cd /opt/p4/p4sde/p4_test/ovs_offload_lnw_scripts
Expand Down Expand Up @@ -364,9 +364,9 @@ E20240414 00:03:48.469659 293611 es2k_hal.cc:276] [secure mode] Stratum external
```
### 3. Setup p4rt-ctl pipe and add the ACC PR rules
### 3. Configure P4 pipeline and add the ACC PR rules
- ACC Terminal 2 : Setup p4rt-ctl pipeline and setup the runtime rules.
- ACC Terminal 2 : Configure pipeline and set up runtime rules.
```bash
[root@ipu-acc ovs_offload_lnw_scripts]# pwd
Expand All @@ -384,9 +384,9 @@ E20240414 00:03:48.469659 293611 es2k_hal.cc:276] [secure mode] Stratum external
[root@ipu-acc ovs_offload_lnw_scripts]# ./4_acc_p4rt_dump.sh
```
### 4. Setup ACC environment for OVS
### 4. Set up ACC environment for OVS
- ACC Terminal 2 : Setup the OVS Environment.
- ACC Terminal 2 : Set up the OVS Environment.
```bash
[root@ipu-acc ovs_offload_lnw_scripts]# pwd
Expand All @@ -395,9 +395,9 @@ E20240414 00:03:48.469659 293611 es2k_hal.cc:276] [secure mode] Stratum external
[root@ipu-acc ovs_offload_lnw_scripts]# ./5_acc_setup_ovs.sh
```
### 5. Setup OVS Bridge Configuration
### 5. Set up OVS Bridge Configuration
- ACC Terminal 2 : Setup the OVS Bridge Config
- ACC Terminal 2 : Set up the OVS Bridge Config
```bash
[root@ipu-acc ovs_offload_lnw_scripts]# pwd
Expand All @@ -406,7 +406,7 @@ E20240414 00:03:48.469659 293611 es2k_hal.cc:276] [secure mode] Stratum external
[root@ipu-acc ovs_offload_lnw_scripts]# ./6_acc_ovs_bridge.sh
```
### 6. Setup VMs on the IPU Host and configure link partner interface
### 6. Set up VMs on the IPU Host and configure link partner interface
- IPU HOST Terminal 1 : Configure the VMs on the IPU Host the script below uses **ip netns**
Expand Down Expand Up @@ -436,7 +436,7 @@ ip netns exec VM4 ping 20.0.0.30
```
### 7. Optional: Setup OVS Bridge for VXLAN
### 7. Optional: Set up OVS Bridge for VXLAN
- This configuration script will setup OVS VXLAN Bridges.
Expand Down Expand Up @@ -533,7 +533,7 @@ rtt min/avg/max/mdev = 0.040/0.048/0.058/0.007 ms
```
### OVS Offload VXLAN on 2 IPU Peers Connected back to back
### OVS Offload VXLAN on Two IPU Peers Connected back-to-back
- Ideally OVS Offload with VXLAN can be run with 2 IPU Peer Setups connected back to back.
- Run python script **ovs_offload_lnw.py** as a root user on the 2 peer IPU Hosts to generate the configuration.
Expand Down

0 comments on commit ad5ea46

Please sign in to comment.