Initial code drop from Cisco
[nfvbench.git] / nfvbenchvm / README.rst
1 NFVBENCH VM IMAGE FOR OPENSTACK 
2 +++++++++++++++++++++++++++++++
3
4 This repo will build a centos 7 image with testpmd and VPP installed.
5 The VM will come with a pre-canned user/password: nfvbench/nfvbench
6
7 BUILD INSTRUCTIONS
8 ==================
9
10 Pre-requisites
11 --------------
12 - must run on Linux
13 - the following packages must be installed prior to using this script:
14     - git
15     - qemu-utils
16     - kpartx
17
18 Build the image
19 ---------------
20 - cd dib
21 - update the version number for the image (if needed) by modifying __version__ in build-image.sh 
22 - setup your http_proxy if needed
23 - bash build-image.sh
24
25 IMAGE INSTANCE AND CONFIG
26 =========================
27
28 Interface Requirements
29 ----------------------
30 The instance must be launched using OpenStack with 2 network interfaces.
31 For best performance, it should use a flavor with:
32
33 - 2 vCPU
34 - 4 GB RAM
35 - cpu pinning set to exclusive
36
37 Auto-configuration
38 ------------------
39 nfvbench VM will automatically find the two virtual interfaces to use, and use the forwarder specifed in the config file.
40
41 In the case testpmd is used, testpmd will be launched with mac forwarding mode where the destination macs rewritten according to the config file.
42
43 In the case VPP is used, VPP will set up a L3 router, and forwarding traffic from one port to the other.
44
45 nfvbenchvm Config
46 -----------------
47 nfvbenchvm config file is located at ``/etc/nfvbenchvm.conf``.
48
49 .. code-block:: bash
50
51     FORWARDER=VPP
52     TG_MAC0=00:10:94:00:0A:00
53     TG_MAC1=00:11:94:00:0A:00
54     VNF1_GATEWAY_CIDR=1.1.0.2/8
55     VNF2_GATEWAY_CIDR=2.2.0.2/8
56     TG1_NET=10.0.0.0/8
57     TG2_NET=20.0.0.0/8
58     TG1_GATEWAY_IP=1.1.0.100
59     TG1_GATEWAY_IP=2.2.0.100
60
61
62 Launching nfvbenchvm VM
63 -----------------------
64
65 Normally this image will be used together with NFVBench, and the required configurations will be automatically generated and pushed to VM by NFVBench. If launched manually, no forwarder will be run. Users will have the full control to run either testpmd or VPP via VNC console.
66
67 To check if testpmd is running, you can run this command in VNC console:
68
69 .. code-block:: bash
70
71     sudo screen -r testpmd
72
73 To check if VPP is running, you can run this command in VNC console:
74
75 .. code-block:: bash
76
77     service vpp status
78
79
80 Hardcoded Username and Password
81 --------------------------------
82 - Username: nfvbench 
83 - Password: nfvbench 
84