Ubuntu Server Guide
Attaching DPDK ports to OpenVswitch
Download 1.23 Mb. Pdf ko'rish
|
ubuntu-server-guide (1)
- Bu sahifa navigatsiya:
- OpenVswitch DPDK to KVM Guests
Attaching DPDK ports to OpenVswitch
The OpenVswitch you now started supports all port types OpenVswitch usually does, plus DPDK port types. Here an example how to create a bridge and - instead of a normal external port - add an external DPDK port to it. When doing so you can specify the device that will be associated. ovs−v s c t l add−br ovsdpdkbr0 −− s e t b r i d g e ovsdpdkbr0 datapath_type=netdev ovs−v s c t l add−p o r t ovsdpdkbr0 dpdk0 −− s e t I n t e r f a c e dpdk0 type=dpdk ” o p t i o n s : dpdk−d e v a r g s=${OVSDEV_PCIID}” Further tuning can be applied by setting options: ovs−v s c t l s e t I n t e r f a c e dpdk0 ” o p t i o n s : n_rxq=2” OpenVswitch DPDK to KVM Guests If you are not building some sort of SDN switch or NFV on top of DPDK it is very likely that you want to forward traffic to KVM guests. The good news is, that with the new qemu/libvirt/dpdk/openvswitch versions in Ubuntu this is no more about manually appending commandline string. This chapter covers a basic configuration how to connect a KVM guest to a OpenVswitch-DPDK instance. The recommended way to get to a KVM guest is using vhost_user_client. This will cause OVS-DPDK to create connect to a socket that qemu created. That way old issues like guest failures on OVS restart are avoided. Here an example how to add such a port to the bridge you created above. ovs−v s c t l add−p o r t ovsdpdkbr0 vhost−u s e r −1 −− s e t I n t e r f a c e vhost−u s e r −1 type= d p d k v h o s t u s e r c l i e n t ” o p t i o n s : vhost−s e r v e r −path=/var / run / v h o s t u s e r c l i e n t / vhost−u s e r −c l i e n t −1” This will connect to the specified path that has to be created by a guest listening on it. To let libvirt/kvm consume this socket and create a guest virtio network device for it add a snippet like this to your guest definition as the network definition. < i n t e r f a c e type =’ v h o s t u s e r ’> mode=’ s e r v e r ’/> i n t e r f a c e > 72 |
Ma'lumotlar bazasi mualliflik huquqi bilan himoyalangan ©fayllar.org 2024
ma'muriyatiga murojaat qiling
ma'muriyatiga murojaat qiling