openvswitch-dpdk starting with DPDK_OPTS parameter
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
openvswitch-dpdk (Ubuntu) |
Expired
|
Undecided
|
Unassigned |
Bug Description
To start OpenvSwitch in DPDK mode,
Users can use parameter DPDK_OPTS in /etc/default/
However, OpenvSwitch-dpdk doesn't start although DPDK_OPTS parameter is uncomment.
For example,
# DPDK options - see /usr/share/
DPDK_OPTS='--dpdk -c 0x1 -n 4'
What I did was,
#install openvswitch-dpdk package
$sudo apt-get install openvswitch-
#enable hugepage
on /etc/default/grub
GRUB_CMDLINE_
$sudo update-grub
$sudo reboot
#mount hugepage
$sudo mount -t hugetlbfs -o pagesize=1G none /dev/hugepages
# DPDK setup
$sudo modprobe uio_pci_generic
$sudo dpdk_nic_bind --bind=
#uncomment DPDK_OPTS on /etc/default/
DPDK_OPTS='--dpdk -c 0x1 -n 4'
# update alternatives ovs-vswitchd and start openvswitch
$sudo update-alternatives --set ovs-vswitchd /usr/lib/
$sudo start openvswitch-switch
# check if openvswitch-dpdk enabled
ps -ef doesn't show ovs-vswitchd process running with --dpdk option.
Also, /var/log/
Package version :
ubuntu@ubuntu:~$ dpkg -l | grep openvswitch
ii openvswitch-common 2.4.0-0ubuntu4~
ii openvswitch-switch 2.4.0-0ubuntu4~
ii openvswitch-
This issue happens since DPDK_OPTS parameter is not forwarded to ovs-ctl.
To make it working, openvswitch- switch. conf should be modified like the following so that DPDK_OPTS parameter can be forwarded to ovs-ctl
/etc/init/
if test X"$FORCE_COREFILES" != X; then corefiles= "$FORCE_ COREFILES"
set "$@" --force-
fi
set "$@" $OVS_CTL_OPTS
# To enable openvswitch-dpdk opts="$ DPDK_OPTS"
if test X"$DPDK_OPTS" != X; then
set "$@" --dpdk-
fi
This patch works fine on my machine.