]>
Commit | Line | Data |
---|---|---|
7c673cae FG |
1 | Overview |
2 | --- | |
3 | Utility scripts for automated FIO tests of virtual machines. | |
4 | Virtualization is done using QEMU software. | |
5 | ||
6 | Requirements | |
7 | --- | |
8 | - 'fio' and 'perf' packages must be installed in order for tests to run | |
9 | - Installed fio version must be the same as fio installed on qemu guest | |
10 | systems. Another solution is to provide the path to a FIO binary | |
11 | in arguments for testing scripts. If fio versions are different tests will not run. | |
12 | - All dependency packages for building QEMU. | |
13 | - QEMU source package. By default it is expected to be in the "qemu" directory in the | |
14 | root dir of the main spdk directory. | |
15 | - a qemu-compatible VM image. | |
16 | - RSA key for VM SSH access in $HOME/.ssh/spdk_vhost_id_rsa or in a different | |
17 | directory specified by $SPDK_VHOST_SSH_KEY_FILE global variable. | |
18 | ||
19 | Files: | |
20 | --- | |
21 | common.sh | |
22 | Header file to be included in other files. | |
23 | ||
24 | autotest.sh | |
25 | Script to perform automated fio test with given number of virtual machines | |
26 | and given scenario type (virtio / kernel vhost / spdk vhost). | |
27 | Can run an end-to-end test or with "--dry-run" option can just enable | |
28 | virtual machines and leave them for user's manual tests. | |
29 | ||
30 | run_vhost.sh | |
31 | Run single instance of vhost application. Useful during development. | |
32 | See 'run_vhost.sh --help' | |
33 | ||
34 | run_fio.py | |
35 | Script used to run fio utility on group of virtual machines | |
36 | using default configuration or with parameters specified for | |
37 | autotest.sh execution. | |
38 | Script can also be executed with manually input parameters, resulting | |
39 | in launching multiple fio jobs which are then combinations of all | |
40 | parameters. | |
41 | See 'python run_fio.py --help' | |
42 | ||
43 | vm_setup.sh | |
44 | Utility script used to create a virtual machine | |
45 | with spcified disk/block device and cache type for tests. | |
46 | Useful during development. | |
47 | See 'vm_setup.sh --help' | |
48 | ||
49 | vm_run.sh | |
50 | Utility script used to enable selected virtual machines. | |
51 | Can enable all or specific virtual machines from directory. | |
52 | Before running this script make sure that there was at least 1 | |
53 | virtual machine created using vm_setup.sh script. | |
54 | Useful during development. | |
55 | See 'vm_run.sh --help' | |
56 | ||
57 | vm_shutdown.sh | |
58 | Utility script used to shut down all or specific virtual machines | |
59 | if any remain active after test run. | |
60 | Useful during development. | |
61 | See 'vm_shutdown.sh --help' | |
62 | ||
63 | vm_ssh.sh | |
64 | Utility script used to connect to specific virtual machine via ssh. | |
65 | Useful during development. | |
66 | See 'vm_ssh.sh --help' | |
67 | ||
68 | Examples: | |
69 | --- | |
70 | ||
71 | --- Example 1, simple run: | |
72 | ||
73 | In spdk directory execute: | |
74 | ./test/vhost/autotest.sh --vm=0,<path to VM image>,<device> --fio-bin=<path to fio bin> | |
75 | ||
76 | <device> - backend used for testing, e.g. Malloc0, Nvme0n1... | |
77 | <path to fio bin> - path to FIO binary | |
78 | ||
79 | This runs tests for 1 VM using spdk vhost. | |
80 | By default all jobs defined in test/vhost/fiotest/fio_jobs/ are executed sequentially. | |
81 | ||
82 | --- Example 2, multiple VMs: | |
83 | ||
84 | ./test/vhost/autotest.sh --vm=0,<path to VM image>,<device> --vm=1,<path to VM image 2>,<device 2> | |
85 | Same configuration as Example 1 but fio runs in parallel on 2 VMs |