scripts/nvmf performance: fix config param and connection error
Fixed the following: 1) Missing python paramiko module in package dependecies. 2) Paramiko connection error: TypeError: missing_host_key() missing 1 required positional argument: 'key' The set_missing_host_key_policy call should take a class instance AutoAddPolicy(), instead of the class name. 3) JSON config file defines "rdma_ips" instead of "nic_ips" 4) Added result file location in the documentation 5) Added env variable for PYTHONPATH to documentation 6) config.json changed default rw to randrw instead of read Change-Id: I96624e2912131f62254c684a6c03a53a7f806cde Signed-off-by: John Kariuki <John.K.Kariuki@intel.com> Reviewed-on: https://review.gerrithub.io/c/spdk/spdk/+/455285 Tested-by: SPDK CI Jenkins <sys_sgci@intel.com> Reviewed-by: Jim Harris <james.r.harris@intel.com> Reviewed-by: Shuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com> Reviewed-by: Liang Yan <liang.z.yan@intel.com>
This commit is contained in:
parent
05dde5c296
commit
d601374387
@ -61,3 +61,18 @@ Fio job parameters.
|
|||||||
- run_time: time (in seconds) to run workload
|
- run_time: time (in seconds) to run workload
|
||||||
- ramp_time: time (in seconds) to run workload before statistics are gathered
|
- ramp_time: time (in seconds) to run workload before statistics are gathered
|
||||||
- run_num: how many times to run given workload in loop
|
- run_num: how many times to run given workload in loop
|
||||||
|
|
||||||
|
# Running Test
|
||||||
|
Before running the test script use the setup.sh script to bind the devices you want to
|
||||||
|
use in the test to the VFIO/UIO driver.
|
||||||
|
Run the script on the NVMe-oF target system:
|
||||||
|
|
||||||
|
cd spdk
|
||||||
|
sudo PYTHONPATH=$PYTHONPATH:$PWD/scripts scripts/perf/nvmf/run_nvmf.py
|
||||||
|
|
||||||
|
The script uses another spdk script (scripts/rpc.py) so we pass the path to rpc.py by setting the Python path
|
||||||
|
as a runtime environment parameter.
|
||||||
|
|
||||||
|
# Test Results
|
||||||
|
When the test completes, you will find a csv file (nvmf_results.csv) containing the results in the target node
|
||||||
|
directory /tmp/results.
|
||||||
|
@ -5,7 +5,7 @@
|
|||||||
"transport": "transport_type"
|
"transport": "transport_type"
|
||||||
},
|
},
|
||||||
"target": {
|
"target": {
|
||||||
"rdma_ips": ["192.0.1.1", "192.0.2.1"],
|
"nic_ips": ["192.0.1.1", "192.0.2.1"],
|
||||||
"mode": "spdk",
|
"mode": "spdk",
|
||||||
"use_null_block": false,
|
"use_null_block": false,
|
||||||
"nvmet_dir": "/path/to/nvmetcli",
|
"nvmet_dir": "/path/to/nvmetcli",
|
||||||
@ -14,19 +14,19 @@
|
|||||||
},
|
},
|
||||||
"initiator1": {
|
"initiator1": {
|
||||||
"ip": "10.0.0.1",
|
"ip": "10.0.0.1",
|
||||||
"rdma_ips": ["192.0.1.1"],
|
"nic_ips": ["192.0.1.1"],
|
||||||
"mode": "spdk",
|
"mode": "spdk",
|
||||||
"nvmecli_dir": "/path/to/nvmecli"
|
"nvmecli_dir": "/path/to/nvmecli"
|
||||||
},
|
},
|
||||||
"initiator2": {
|
"initiator2": {
|
||||||
"ip": "10.0.0.2",
|
"ip": "10.0.0.2",
|
||||||
"rdma_ips": ["192.0.2.1"],
|
"nic_ips": ["192.0.2.1"],
|
||||||
"mode": "spdk"
|
"mode": "spdk"
|
||||||
},
|
},
|
||||||
"fio": {
|
"fio": {
|
||||||
"bs": ["4k"],
|
"bs": ["4k"],
|
||||||
"qd": [128],
|
"qd": [128],
|
||||||
"rw": ["read"],
|
"rw": ["randrw"],
|
||||||
"rwmixread": 100,
|
"rwmixread": 100,
|
||||||
"run_time": 5,
|
"run_time": 5,
|
||||||
"ramp_time": 1,
|
"ramp_time": 1,
|
||||||
|
@ -159,6 +159,7 @@ class Target(Server):
|
|||||||
for row in rows:
|
for row in rows:
|
||||||
with open(os.path.join(results_dir, csv_file), "a") as fh:
|
with open(os.path.join(results_dir, csv_file), "a") as fh:
|
||||||
fh.write(row + "\n")
|
fh.write(row + "\n")
|
||||||
|
self.log_print("You can find the test results in the file %s" % os.path.join(results_dir, csv_file))
|
||||||
|
|
||||||
def measure_sar(self, results_dir, sar_file_name):
|
def measure_sar(self, results_dir, sar_file_name):
|
||||||
self.log_print("Waiting %d delay before measuring SAR stats" % self.sar_delay)
|
self.log_print("Waiting %d delay before measuring SAR stats" % self.sar_delay)
|
||||||
@ -186,7 +187,7 @@ class Initiator(Server):
|
|||||||
self.nvmecli_bin = "nvme" # Use system-wide nvme-cli
|
self.nvmecli_bin = "nvme" # Use system-wide nvme-cli
|
||||||
|
|
||||||
self.ssh_connection = paramiko.SSHClient()
|
self.ssh_connection = paramiko.SSHClient()
|
||||||
self.ssh_connection.set_missing_host_key_policy(paramiko.AutoAddPolicy)
|
self.ssh_connection.set_missing_host_key_policy(paramiko.AutoAddPolicy())
|
||||||
self.ssh_connection.connect(self.ip, username=self.username, password=self.password)
|
self.ssh_connection.connect(self.ip, username=self.username, password=self.password)
|
||||||
self.remote_call("sudo rm -rf %s/nvmf_perf" % self.spdk_dir)
|
self.remote_call("sudo rm -rf %s/nvmf_perf" % self.spdk_dir)
|
||||||
self.remote_call("mkdir -p %s" % self.spdk_dir)
|
self.remote_call("mkdir -p %s" % self.spdk_dir)
|
||||||
|
@ -92,6 +92,8 @@ elif [ -f /etc/debian_version ]; then
|
|||||||
"Note: Some SPDK CLI dependencies could not be installed."
|
"Note: Some SPDK CLI dependencies could not be installed."
|
||||||
# Additional dependencies for ISA-L used in compression
|
# Additional dependencies for ISA-L used in compression
|
||||||
apt-get install -y autoconf automake libtool help2man
|
apt-get install -y autoconf automake libtool help2man
|
||||||
|
# Additional dependecies for nvmf performance test script
|
||||||
|
apt-get install -y python3-paramiko
|
||||||
elif [ -f /etc/SuSE-release ] || [ -f /etc/SUSE-brand ]; then
|
elif [ -f /etc/SuSE-release ] || [ -f /etc/SUSE-brand ]; then
|
||||||
zypper install -y gcc gcc-c++ make cunit-devel libaio-devel libopenssl-devel \
|
zypper install -y gcc gcc-c++ make cunit-devel libaio-devel libopenssl-devel \
|
||||||
git-core lcov python-base python-pycodestyle libuuid-devel sg3_utils pciutils
|
git-core lcov python-base python-pycodestyle libuuid-devel sg3_utils pciutils
|
||||||
|
Loading…
Reference in New Issue
Block a user