README.md revision e0d34a1f
1# Vhost and VPP testing script
2
3This script intends to provide a reference script for testing [VPP](http://fd.io/) vhost-user performances.
4It uses the basic topology PHY -> VM -> PHY.
5You will therefore need a machine with two physical interfaces and the ability to run a VM with qemu in
6order to run the test.
7
8## A word about the VM
9
10The VM that is executed is a CLONE of the running system.
11In practice, that means that the VM is using, as root filesystem,
12a mounted OverlayFS instance of the root directory (Meaning that
13the VM will share the same file, but all updates will not affect the
14root file system).
15
16This also means that the VM boots on a shared file system, which implies
17that the initramfs image must include the 9p driver.
18
19One way of doing it is documented [here] (http://unix.stackexchange.com/questions/90423/can-virtfs-9p-be-used-as-root-file-system).
20$ printf '%s\n' 9p 9pnet 9pnet_virtio | sudo tee -a /etc/initramfs-tools/modules
21$ sudo update-initramfs -u
22
23
24## HowTo
25
26$ cd vhost-test
27
28First copy and update the configuration file such that the parameters
29correspond to your setup.
30
31$ cp conf.sh.default conf.sh
32$ vim conf.sh
33
34Then, run the setup.
35
36$ ./vhost.sh start
37
38Once the setup is running, you can re-pin the processes.
39This is important, as it also performs 'chrt' on the working threads.
40
41$ ./vhost.sh pin
42
43Once the setup is running, you can:
44- Log into the VM
45$ ./vhost.sh ssh
46
47- Log into VPP
48$ sudo screen -r vhtestvpp
49
50
51Finally, when you are done, you can stop the VMs.
52
53$ ./vhost.sh stop
54
55## Traffic Generation
56
57Traffic generation is, for now, out of the scope of this script.
58You are supposed to update ./conf.sh by setting up the right parameters.
59Use the traffic generator you like to test the perfs.
60
61## Administrativa
62
63### Current status
64
65This script hasn't been tested by anyone but me for now.
66You should therefore expect bugs on different setups.
67
68### Main contributors
69
70Pierre Pfister - LF-ID:ppfister
71
72
73