Hi ☆ Field Commande A9,

How do you start OVS?


You might have missed some additional arguments!
When DPDK interfaces are properly set, /ovs-vsctl list o//pen_vswitch/
would have
/[dpdk, dpdkr, dpdkvhostuser, dpdkvhostuserclient...]
/in the iface_types "dictionary"!

I start OVS with 2 dpdk interfaces running on one core (hence
core_mask:4) as follows:

sudo $OVS_PATH/utilities/ovs-vsctl --no-wait set Open_vSwitch .
other_config:dpdk-init=true
echo "Setup dpdk params..."
sudo $OVS_PATH/utilities/ovs-vsctl --no-wait set Open_vSwitch .
other_config:dpdk-lcore-mask=4
sudo $OVS_PATH/utilities/ovs-vsctl --no-wait set Open_vSwitch .
other_config:dpdk-socket-mem="4096,0"
sudo $OVS_PATH/utilities/ovs-vsctl --no-wait set Open_vSwitch .
other_config:dpdk-hugepage-dir="/mnt/huge"
sudo $OVS_PATH/utilities/ovs-vsctl --no-wait set Open_vSwitch .
other_config:pmd-cpu-mask=4

Then add the interfaces:
echo "start vswitchd..."
sudo $OVS_PATH/vswitchd/ovs-vswitchd   unix:$DB_SOCK --pidfile --detach


sudo $OVS_PATH/utilities/ovs-vsctl add-br ovs_dpdk -- set bridge
ovs_dpdk datapath_type=netdev

echo "Add dpdk ports for ovs_dpdk"
sudo $OVS_PATH/utilities/ovs-vsctl add-port ovs_dpdk dpdk0 -- set
Interface dpdk0 type=dpdk options:dpdk-devargs=0000:0b:00.0
sudo $OVS_PATH/utilities/ovs-vsctl add-port ovs_dpdk dpdk1 -- set
Interface dpdk1 type=dpdk options:dpdk-devargs=0000:0b:00.1


For brevity, other unrelated initialization commands are not shown!




On 11/23/2017 03:47 AM, ☆ Field Commande A9 wrote:
>
> I have OVS with DPDK support installed, but cannot start OVS in DPDK mode.
>
>  
>
> I have uio driver already installed and device binded:
>
>  
>
> root@compute-0-1:/var/log# dpdk-devbind.py -s
>
>  
>
> Network devices using DPDK-compatible driver
>
> ============================================
>
> 0000:0c:00.0 '82574L Gigabit Network Connection' drv=uio_pci_generic
> unused=
>
>  
>
> I can set the dpdk-init parameter to true using ovs-vsctl:
>
>  
>
> root@compute-0-1:/var/log# ovs-vsctl list open_vswitch
>
> _uuid               : 8dd11fbd-74e1-4250-af04-e1c3511963e3
>
> bridges             : [065d253b-172e-4994-9a3b-5de5f625a2b0,
> 6dacb0b3-55bd-4bdc-93d8-b0d9a29b5bba,
> 777fd459-1678-4cd9-a7fd-277f5ce42dfb,
> 937029a2-7ec4-4932-bdad-b10c45981343,
> a5919efe-fcfe-4ba0-9471-e28c6f428192,
> a946af11-f291-4600-b72a-f0b83b7357a2]
>
> cur_cfg             : 38
>
> datapath_types      : [netdev, system]
>
> db_version          : "7.14.0"
>
> external_ids        : {hostname="", system-id=""}
>
> iface_types         : [geneve, gre, internal, ipsec_gre, "l3gre",
> lisp, patch, stt, system, tap, vxlan]
>
> manager_options     : []
>
> next_cfg            : 38
>
> other_config        : {default-mtu="2140", *dpdk-init="true",*
> dpdk-lcore-mask="0x2", dpdk-socket-mem="2048"}
>
> ovs_version         : "2.6.2.css4.R8B~d8f404f"
>
> ssl                 : []
>
> statistics          : {}
>
> system_type         : ubuntu
>
> system_version      : "14.04"
>
>  
>
> But every time OVS restarts (e.g. service openvswitch-switch restartor
> a system reboot), the dpdk-init parameter gets automatically set to
> false, which means I can’t use DPDK features.
>
>
>
> _______________________________________________
> discuss mailing list
> disc...@openvswitch.org
> https://mail.openvswitch.org/mailman/listinfo/ovs-discuss

_______________________________________________
discuss mailing list
disc...@openvswitch.org
https://mail.openvswitch.org/mailman/listinfo/ovs-discuss

Reply via email to