blob: c29434b3b640542028c821208b2b4e7c58e4e85b [file] [log] [blame]
Hyunsun Moond12f32b2021-07-30 12:55:00 -07001..
2 SPDX-FileCopyrightText: © 2021 Open Networking Foundation <support@opennetworking.org>
3 SPDX-License-Identifier: Apache-2.0
4
5BESS UPF Deployment
6===================
7
Hyunsun Moonb9c7dde2021-08-01 06:11:08 -07008This section describes how to configure and deploy BESS UPF.
Hyunsun Moond12f32b2021-07-30 12:55:00 -07009
Hyunsun Moon015eb212021-08-24 18:06:24 -070010Network Configuration
11---------------------
Hyunsun Moond12f32b2021-07-30 12:55:00 -070012
Hyunsun Moon015eb212021-08-24 18:06:24 -070013BESS UPF enabled edge setup requires three additional user plane subnets
14apart from the default K8S subnets.
Hyunsun Moond12f32b2021-07-30 12:55:00 -070015
Hyunsun Moon015eb212021-08-24 18:06:24 -070016* **enb**: Used to provide eNBs with connectivity to SD-Core and UPF.
17* **access**: Used to provide UPF with connectivity to eNBs.
18* **core**: Used to provide UPF with edge services as well as the Internet access.
19
20To help your understanding, the following example ACE environment will be used in the rest of the guide.
Hyunsun Moond12f32b2021-07-30 12:55:00 -070021
Zack Williams1ae109e2021-07-27 11:17:04 -070022.. image:: images/bess-upf-example-network.svg
Hyunsun Moond12f32b2021-07-30 12:55:00 -070023
Hyunsun Moond12f32b2021-07-30 12:55:00 -070024.. note::
25
Hyunsun Moon015eb212021-08-24 18:06:24 -070026 Admin and out-of-band networks are not depicted in the diagram.
Hyunsun Moond12f32b2021-07-30 12:55:00 -070027
Hyunsun Moon015eb212021-08-24 18:06:24 -070028+-----------+-----------+------------------------------------+-------------------+---------------+
29| Network | VLAN ID | Subnet | Interface | IP address |
30+-----------+-----------+------------------------------------+-------------------+---------------+
31| k8smgmt | 1 | 192.168.1.0/24 (gw: 192.168.1.1) | management server | 192.168.1.254 |
32| | | +-------------------+---------------+
33| | | | compute1 | 192.168.1.3 |
34| | | +-------------------+---------------+
35| | | | compute2 | 192.168.1.4 |
36| | | +-------------------+---------------+
37| | | | compute3 | 192.168.1.5 |
38+-----------+-----------+------------------------------------+-------------------+---------------+
39| enb | 2 | 192.168.2.0/24 (gw: 192.168.2.1) | enb1 | 192.168.2.10 |
40+-----------+-----------+------------------------------------+-------------------+---------------+
41| access | 3 | 192.168.3.0/24 (gw: 192.168.3.1) | upf1 access | 192.168.3.10 |
42+-----------+-----------+------------------------------------+-------------------+---------------+
43| core | 4 | 192.168.4.0/24 (gw: 192.168.4.1) | management server | 192.168.4.254 |
44| | | +-------------------+---------------+
45| | | | upf1 core | 192.168.4.10 |
46+-----------+-----------+------------------------------------+-------------------+---------------+
Hyunsun Moond12f32b2021-07-30 12:55:00 -070047
Hyunsun Moon015eb212021-08-24 18:06:24 -070048It is assumed that the management server has the only external routable address and acts
49as a router connecting the Aether pod to the outside.
50This means that all uplink packets leaving the Aether pod needs to be masqueraded with the
51external address of the management server or the k8smgmt address if the destination
52is Aether central.
53Also, in order for downlink traffic to UE to be delivered to its destination,
54it must be forwarded to the UPF's core interface.
55This adds additional routes to the management server and L3 switch.
Hyunsun Moond12f32b2021-07-30 12:55:00 -070056
57
58Check Cluster Resources
59-----------------------
60
Hyunsun Moon015eb212021-08-24 18:06:24 -070061Before proceeding with the deployment, make sure the cluster has enough resources
62to run BESS UPF by running the command below.
Hyunsun Moond12f32b2021-07-30 12:55:00 -070063
64.. code-block:: shell
65
Hyunsun Moon53a18a72021-08-10 16:57:32 -070066 $ kubectl get nodes -o json | jq '.items[].status.allocatable'
Hyunsun Moond12f32b2021-07-30 12:55:00 -070067 {
68 "cpu": "95",
69 "ephemeral-storage": "1770223432846",
70 "hugepages-1Gi": "32Gi",
71 "intel.com/intel_sriov_netdevice": "32",
72 "intel.com/intel_sriov_vfio": "32",
73 "memory": "360749956Ki",
74 "pods": "110"
75 }
76
Hyunsun Moon015eb212021-08-24 18:06:24 -070077For best performance, BESS UPF requires the following resources:
78
79* 2 dedicated cores (``"cpu"``)
80* 2 1GiB HugePages (``"hugepages-1Gi"``)
81* 2 SRIOV Virtual Functions bound to **vfio-pci** driver (``"intel.com/intel_sriov_vfio"``)
82
83For environments where these resources are not available, contact Ops team for
84advanced configuration.
Hyunsun Moond12f32b2021-07-30 12:55:00 -070085
Hyunsun Moonb9c7dde2021-08-01 06:11:08 -070086Configure and Deploy
87--------------------
Hyunsun Moond12f32b2021-07-30 12:55:00 -070088
89Download ``aether-app-configs`` if you don't have it already in your development machine.
90
91.. code-block:: shell
92
93 $ cd $WORKDIR
94 $ git clone "ssh://[username]@gerrit.opencord.org:29418/aether-app-configs"
95
Hyunsun Moonb9c7dde2021-08-01 06:11:08 -070096Move the directory to ``apps/bess-upf/upf1`` and create a Helm values file for the new cluster as shown below.
Hyunsun Moond12f32b2021-07-30 12:55:00 -070097Don't forget to replace the IP addresses in the example configuration with the addresses of the actual cluster.
98
Hyunsun Moon2b2bf9a2021-08-01 05:29:48 -070099.. code-block:: yaml
Hyunsun Moond12f32b2021-07-30 12:55:00 -0700100
101 $ cd $WORKDIR/aether-app-configs/apps/bess-upf/upf1
102 $ mkdir overlays/prd-ace-test
103 $ vi overlays/prd-ace-test/values.yaml
Hyunsun Moon015eb212021-08-24 18:06:24 -0700104 # SPDX-FileCopyrightText: 2021-present Open Networking Foundation <info@opennetworking.org>
Hyunsun Moond12f32b2021-07-30 12:55:00 -0700105
106 config:
107 upf:
108 enb:
109 subnet: "192.168.2.0/24"
110 access:
Hyunsun Moon015eb212021-08-24 18:06:24 -0700111 ip: "192.168.3.10/24"
112 gateway: "192.168.3.1"
Hyunsun Moon6001f942021-08-01 10:35:04 -0700113 vlan: 3
Hyunsun Moond12f32b2021-07-30 12:55:00 -0700114 core:
Hyunsun Moon015eb212021-08-24 18:06:24 -0700115 ip: "192.168.4.10/24"
116 gateway: "192.168.4.1"
Hyunsun Moon6001f942021-08-01 10:35:04 -0700117 vlan: 4
Hyunsun Moonba65df22021-08-10 20:01:06 -0700118 # Add below when connecting to 5G core
119 #cfgFiles:
120 # upf.json:
121 # cpiface:
122 # dnn: "8internet"
123 # hostname: "upf"
Hyunsun Moond12f32b2021-07-30 12:55:00 -0700124
125
Hyunsun Moonb9c7dde2021-08-01 06:11:08 -0700126Update ``fleet.yaml`` in the same directory to let Fleet use the custom configuration when deploying
127BESS UPF to the new cluster.
Hyunsun Moond12f32b2021-07-30 12:55:00 -0700128
Hyunsun Moon2b2bf9a2021-08-01 05:29:48 -0700129.. code-block:: yaml
Hyunsun Moond12f32b2021-07-30 12:55:00 -0700130
131 $ vi fleet.yaml
132 # add following block at the end
133 - name: prd-ace-test
134 clusterSelector:
135 matchLabels:
136 management.cattle.io/cluster-display-name: ace-test
137 helm:
138 valuesFiles:
139 - overlays/prd-ace-test/values.yaml
140
141
Hyunsun Moon2b2bf9a2021-08-01 05:29:48 -0700142Submit your changes.
Hyunsun Moond12f32b2021-07-30 12:55:00 -0700143
144.. code-block:: shell
145
146 $ cd $WORKDIR/aether-app-configs
147 $ git status
148 $ git add .
149 $ git commit -m "Add BESS UPF configs for test ACE"
150 $ git review
151
152
153Go to Fleet dashboard and wait until the cluster status becomes **Active**.
Hyunsun Moonb9c7dde2021-08-01 06:11:08 -0700154It can take up to 1 min for Fleet to fetch the configuration updates.