From: "Tu, Lijuan" <lijuan.tu@intel.com>
To: "Wang, Yinan" <yinan.wang@intel.com>, "dts@dpdk.org" <dts@dpdk.org>
Cc: "Wang, Yinan" <yinan.wang@intel.com>
Subject: Re: [dts] [PATCH v2] test_plans: add test plan for pvp virtio bonding test
Date: Wed, 10 Jul 2019 06:16:51 +0000 [thread overview]
Message-ID: <8CE3E05A3F976642AAB0F4675D0AD20E0BADEAC1@SHSMSX101.ccr.corp.intel.com> (raw)
In-Reply-To: <20190627233117.48914-1-yinan.wang@intel.com>
Applied, thanks
> -----Original Message-----
> From: dts [mailto:dts-bounces@dpdk.org] On Behalf Of Yinan
> Sent: Friday, June 28, 2019 7:31 AM
> To: dts@dpdk.org
> Cc: Wang, Yinan <yinan.wang@intel.com>
> Subject: [dts] [PATCH v2] test_plans: add test plan for pvp virtio bonding test
>
> From: Wang Yinan <yinan.wang@intel.com>
>
> Signed-off-by: Wang Yinan <yinan.wang@intel.com>
> ---
> test_plans/pvp_virtio_bonding_test_plan.rst | 165 ++++++++++++++++++++
> 1 file changed, 165 insertions(+)
> create mode 100644 test_plans/pvp_virtio_bonding_test_plan.rst
>
> diff --git a/test_plans/pvp_virtio_bonding_test_plan.rst
> b/test_plans/pvp_virtio_bonding_test_plan.rst
> new file mode 100644
> index 0000000..a90e7d3
> --- /dev/null
> +++ b/test_plans/pvp_virtio_bonding_test_plan.rst
> @@ -0,0 +1,165 @@
> +.. Copyright (c) <2019>, Intel Corporation
> + All rights reserved.
> +
> + Redistribution and use in source and binary forms, with or without
> + modification, are permitted provided that the following conditions
> + are met:
> +
> + - Redistributions of source code must retain the above copyright
> + notice, this list of conditions and the following disclaimer.
> +
> + - Redistributions in binary form must reproduce the above copyright
> + notice, this list of conditions and the following disclaimer in
> + the documentation and/or other materials provided with the
> + distribution.
> +
> + - Neither the name of Intel Corporation nor the names of its
> + contributors may be used to endorse or promote products derived
> + from this software without specific prior written permission.
> +
> + THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND
> CONTRIBUTORS
> + "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
> + LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND
> FITNESS
> + FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE
> + COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT,
> INDIRECT,
> + INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
> + (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
> OR
> + SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
> + HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
> CONTRACT,
> + STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
> + ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
> ADVISED
> + OF THE POSSIBILITY OF SUCH DAMAGE.
> +
> +===========================================
> +vhost-user/virtio-pmd pvp bonding test plan
> +===========================================
> +
> +Description
> +===========
> +
> +The Link Bonding functions make it possible to dynamically create and
> +manage link bonding devices from within testpmd interactive prompt,
> +below are the introduction of seven bonding modes:
> +- Mode = 0 (balance-rr) Round-robin policy: (default).
> +- Mode = 1 (active-backup) Active-backup policy: Only one NIC slave in the
> bond is active.
> +- Mode = 2 (balance-xor) XOR policy: Transmit network packets based on
> the default transmit policy.
> +- Mode = 3 (broadcast) Broadcast policy: Transmit network packets on all
> slave network interfaces.
> +- Mode = 4 (802.3ad) IEEE 802.3ad Dynamic link aggregation.
> +- Mode = 5 (balance-tlb) Adaptive transmit load balancing.
> +- Mode = 6 (balance-alb) Adaptive load balancing.
> +
> +Test case 1: vhost-user/virtio-pmd pvp bonding test with mode 0
> +===============================================================
> +Flow: TG--> NIC --> Vhost --> Virtio3 --> Virtio4 --> Vhost--> NIC-->
> +TG
> +
> +1. Bind one port to igb_uio,launch vhost by below command::
> +
> + ./testpmd -l 1-6 -n 4 --socket-mem 2048,2048 --legacy-mem --file-
> prefix=vhost --vdev 'net_vhost,iface=vhost-net,client=1,queues=1' --vdev
> 'net_vhost1,iface=vhost-net1,client=1,queues=1' --vdev
> 'net_vhost2,iface=vhost-net2,client=1,queues=1' --vdev
> 'net_vhost3,iface=vhost-net3,client=1,queues=1' -- -i --port-
> topology=chained --nb-cores=4 --txd=1024 --rxd=1024
> + testpmd>set fwd mac
> + testpmd>start
> +
> +2. Bootup one vm with four virtio-net devices::
> +
> + qemu-system-x86_64 -name vm0 -enable-kvm -chardev
> socket,path=/tmp/vm0_qga0.sock,server,nowait,id=vm0_qga0 \
> + -device virtio-serial -device
> virtserialport,chardev=vm0_qga0,name=org.qemu.guest_agent.0 \
> + -daemonize -monitor unix:/tmp/vm0_monitor.sock,server,nowait \
> + -net nic,vlan=0,macaddr=00:00:00:c7:56:64,addr=1f \
> + -net user,vlan=0,hostfwd=tcp:127.0.0.1:6008-:22 \
> + -chardev socket,id=char0,path=./vhost-net,server \
> + -netdev type=vhost-user,id=netdev0,chardev=char0,vhostforce \
> + -device virtio-net-pci,netdev=netdev0,mac=52:54:00:00:00:01 \
> + -chardev socket,id=char1,path=./vhost-net1,server \
> + -netdev type=vhost-user,id=netdev1,chardev=char1,vhostforce \
> + -device virtio-net-pci,netdev=netdev1,mac=52:54:00:00:00:02 \
> + -chardev socket,id=char2,path=./vhost-net2,server \
> + -netdev type=vhost-user,id=netdev2,chardev=char2,vhostforce \
> + -device virtio-net-pci,netdev=netdev2,mac=52:54:00:00:00:03 \
> + -chardev socket,id=char3,path=./vhost-net3,server \
> + -netdev type=vhost-user,id=netdev3,chardev=char3,vhostforce \
> + -device virtio-net-pci,netdev=netdev3,mac=52:54:00:00:00:04 \
> + -cpu host -smp 8 -m 4096 \
> + -object memory-backend-file,id=mem,size=4096M,mem-
> path=/mnt/huge,share=on \
> + -numa node,memdev=mem -mem-prealloc -drive
> + file=/home/osimg/ubuntu16.img -vnc :10
> +
> +3. On vm, bind four virtio-net devices to igb_uio::
> +
> + ./dpdk-devbind.py -b igb_uio xx:xx.x xx:xx.x xx:xx.x xx:xx.x
> +
> +4. Launch testpmd in VM::
> +
> + ./testpmd -l 0-5 -n 4 -- -i --port-topology=chained --nb-cores=5
> +
> +5. Create one bonded device in mode 0 on socket 0::
> +
> + testpmd>create bonded device 0 0 # create bonded device (mode)
> (socket)
> + created new bonded device on (port 4) # in this case, already has port
> 0,1,2,3 for vdev, so the bonded device port is 4
> +
> +6. Add three vdev (port 0,1,2) to link bonding device (port 4) and configure
> forwarding on port 3 and port 4::
> +
> + testpmd>add bonding slave 0 4 # add bonding slave (slave id) (port id)
> + testpmd>add bonding slave 1 4
> + testpmd>add bonding slave 2 4
> + testpmd>port start 4
> + testpmd>show bonding config 4
> + testpmd>set portlist 3,4
> + testpmd>set fwd mac
> + testpmd>start
> +
> +7. Send packets to nic port by packet generator.
> +
> +8. Check port stats at VM side, there are throughput between port 3 and
> port 4::
> +
> + testpmd>show port stats all
> +
> +Test case 2: vhost-user/virtio-pmd pvp bonding test with different mode
> +from 1 to 6
> +===============================================================
> ========
> +============
> +
> +1. Bind one port to igb_uio,launch vhost by below command::
> +
> + ./testpmd -l 1-6 -n 4 --socket-mem 2048,2048 --legacy-mem --file-
> prefix=vhost --vdev 'net_vhost,iface=vhost-net,client=1,queues=1' --vdev
> 'net_vhost1,iface=vhost-net1,client=1,queues=1' --vdev
> 'net_vhost2,iface=vhost-net2,client=1,queues=1' --vdev
> 'net_vhost3,iface=vhost-net3,client=1,queues=1' -- -i --port-
> topology=chained --nb-cores=4 --txd=1024 --rxd=1024
> + testpmd>set fwd mac
> + testpmd>start
> +
> +2. Bootup one vm with four virtio-net devices::
> +
> + qemu-system-x86_64 -name vm0 -enable-kvm -chardev
> socket,path=/tmp/vm0_qga0.sock,server,nowait,id=vm0_qga0 \
> + -device virtio-serial -device
> virtserialport,chardev=vm0_qga0,name=org.qemu.guest_agent.0 \
> + -daemonize -monitor unix:/tmp/vm0_monitor.sock,server,nowait \
> + -net nic,vlan=0,macaddr=00:00:00:c7:56:64,addr=1f \
> + -net user,vlan=0,hostfwd=tcp:127.0.0.1:6008-:22 \
> + -chardev socket,id=char0,path=./vhost-net,server \
> + -netdev type=vhost-user,id=netdev0,chardev=char0,vhostforce \
> + -device virtio-net-pci,netdev=netdev0,mac=52:54:00:00:00:01 \
> + -chardev socket,id=char1,path=./vhost-net1,server \
> + -netdev type=vhost-user,id=netdev1,chardev=char1,vhostforce \
> + -device virtio-net-pci,netdev=netdev1,mac=52:54:00:00:00:02 \
> + -chardev socket,id=char2,path=./vhost-net2,server \
> + -netdev type=vhost-user,id=netdev2,chardev=char2,vhostforce \
> + -device virtio-net-pci,netdev=netdev2,mac=52:54:00:00:00:03 \
> + -chardev socket,id=char3,path=./vhost-net3,server \
> + -netdev type=vhost-user,id=netdev3,chardev=char3,vhostforce \
> + -device virtio-net-pci,netdev=netdev3,mac=52:54:00:00:00:04 \
> + -cpu host -smp 8 -m 4096 \
> + -object memory-backend-file,id=mem,size=4096M,mem-
> path=/mnt/huge,share=on \
> + -numa node,memdev=mem -mem-prealloc -drive
> + file=/home/osimg/ubuntu16.img -vnc :10
> +
> +3. On vm, bind four virtio-net devices to igb_uio::
> +
> + ./dpdk-devbind.py -b igb_uio xx:xx.x xx:xx.x xx:xx.x xx:xx.x
> +
> +4. Launch testpmd in VM::
> +
> + ./testpmd -l 0-5 -n 4 -- -i --port-topology=chained --nb-cores=5
> +
> +5. Create bonding device with mode 1 to mode 6::
> +
> + testpmd> create bonded device (mode) 0
> +
> +6. Add three vdev (port 0,1,2) to link bonding device (port 4) and configure
> forwarding on port 3 and port 4::
> +
> + testpmd>add bonding slave 0 4 # add bonding slave (slave id) (port id)
> + testpmd>add bonding slave 1 4
> + testpmd>add bonding slave 2 4
> + testpmd>port start 4
> + testpmd>show bonding config 4
> + testpmd>set portlist 3,4
> + testpmd>set fwd mac
> + testpmd>start
> \ No newline at end of file
> --
> 2.17.1
prev parent reply other threads:[~2019-07-10 6:16 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2019-06-27 23:31 Yinan
2019-07-10 6:16 ` Tu, Lijuan [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=8CE3E05A3F976642AAB0F4675D0AD20E0BADEAC1@SHSMSX101.ccr.corp.intel.com \
--to=lijuan.tu@intel.com \
--cc=dts@dpdk.org \
--cc=yinan.wang@intel.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).