Skip to content

Commit 8d08703

Browse files
authored
Merge pull request #40 from sureshmarikkannu/dpdk_bp_prereq
Update pre-requisite for SRIOV/DPDK blueprint
2 parents 31cefb7 + 20773e4 commit 8d08703

File tree

2 files changed

+65
-2
lines changed

2 files changed

+65
-2
lines changed

dict.txt

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -166,6 +166,9 @@ hostname
166166
hss
167167
hssdb
168168
https
169+
hugepage
170+
hugepages
171+
hugepagesz
169172
iOS
170173
iPXE
171174
iPhones
@@ -174,6 +177,7 @@ imei
174177
incrementing
175178
inotify
176179
instantiation
180+
iommu
177181
ip
178182
isn't
179183
iteratively
@@ -234,6 +238,7 @@ patchsets
234238
pcap
235239
pcaps
236240
pcf
241+
pci
237242
pcrf
238243
pcrfdb
239244
pfcp
@@ -317,6 +322,7 @@ upf
317322
uplink
318323
uptime
319324
url
325+
vfio
320326
virtualenv
321327
vpn
322328
webhooks

onramp/blueprints.rst

Lines changed: 59 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -422,9 +422,66 @@ UPF is used in both cases.
422422

423423
Enable SR-IOV and DPDK
424424
~~~~~~~~~~~~~~~~~~~~~~~~~~
425+
UPF performance can be improved by enabling SR-IOV and DPDK.
425426

426-
UPF performance can be improved by enabling SR-IOV and DPDK. This
427-
blueprint supports both optimizations, where the former depends on the
427+
Pre-requisite:
428+
* make sure virtualization and VT-d parameters are enabled in BIOS.
429+
430+
* make sure enough hugepage memory allocated, iommu enabled. These changes
431+
can be made by updating
432+
GRUB_CMDLINE_LINUX="intel_iommu=on iommu=pt default_hugepagesz=1G hugepagesz=1G hugepages=32 transparent_hugepage=never"
433+
in /etc/default/grub
434+
435+
Note: Number of hugepages = 2 X No of UPF Instances
436+
437+
Once it is updated apply the changes by running below command,
438+
439+
.. code-block::
440+
441+
$sudo update-grub
442+
$sudo reboot
443+
444+
You can verify the allocated hugepages using below command,
445+
446+
.. code-block::
447+
448+
$cat /proc/meminfo | grep HugePages
449+
AnonHugePages: 0 kB
450+
ShmemHugePages: 0 kB
451+
FileHugePages: 0 kB
452+
HugePages_Total: 32
453+
HugePages_Free: 32
454+
HugePages_Rsvd: 0
455+
HugePages_Surp: 0
456+
457+
* Create required VF devices(minimum 2 required per UPF) as follows,
458+
(In this example the PF interface used is "ens801f0")
459+
460+
.. code-block::
461+
462+
echo 2 > /sys/class/net/ens801f0/device/sriov_numvfs
463+
464+
Now retrieve the PCI address for the newly created VF devices using below command,
465+
466+
.. code-block::
467+
468+
ls -l /sys/class/net/ens801f0/device/virtfn*
469+
470+
* Clone the DPDK repo to use the binding tools,
471+
472+
.. code-block::
473+
474+
git clone https://github.com/DPDK/dpdk.git
475+
cd dpdk
476+
477+
* Bind the VF devices to the vfio-pci driver as follows,
478+
479+
.. code-block::
480+
481+
./usertools/dpdk-devbind.py -b vfio-pci 0000:b1:01.0
482+
./usertools/dpdk-devbind.py -b vfio-pci 0000:b1:01.1
483+
484+
This blueprint supports both optimizations, where the former depends on the
428485
server NIC(s) being SR-IOV capable. The blueprint includes the
429486
following:
430487

0 commit comments

Comments
 (0)