Commit Graph

706 Commits

Author SHA1 Message Date
Vitaliy Mysak
60bf34d1f0 scripts/rpc: change default value from None to {}
JSONRPCClient.call recieved optional `params` value,
  but then `params` was used in `json.dumps` function (line #159)
  as a dictionary, so `None` was treated as dictionary
  in some cases, which resulted in TypeError.

This patch fixes above issue by changing
  the default value from `None` to `{}`.

Change-Id: I27ca0ccc2d970c0ff9e8117f02203c03e417adf0
Signed-off-by: Vitaliy Mysak <vitaliy.mysak@intel.com>
Reviewed-on: https://review.gerrithub.io/c/spdk/spdk/+/462070
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Reviewed-by: Darek Stojaczyk <dariusz.stojaczyk@intel.com>
Reviewed-by: Shuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com>
2019-07-18 05:29:00 +00:00
Maciej Szwed
074fa32636 scripts: Fix setup.sh to take into consideration other namespaces
Currently we do not switch driver for NVMe that is mounted.
The problem is that we take into consideration only the
first namespace, but any other namespace can be still mounted.
In such case we should not switch driver.

Signed-off-by: Maciej Szwed <maciej.szwed@intel.com>
Change-Id: Idd13edccd0929574f2914a71e841e67871dd2e9f
Reviewed-on: https://review.gerrithub.io/c/spdk/spdk/+/457762
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Reviewed-by: Karol Latecki <karol.latecki@intel.com>
Reviewed-by: Darek Stojaczyk <dariusz.stojaczyk@intel.com>
Reviewed-by: Shuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com>
2019-07-18 03:18:13 +00:00
Ziye Yang
4739f62365 nvmf: enable transport based scheduler decode in RPC.
Purpose: To eanble the transport based scheduler in RPC.
Previously, we only support it with configuration file.

Signed-off-by: Ziye Yang <ziye.yang@intel.com>
Change-Id: I02ae9b1b316d4fec8b28b550e70dcdc78ce78722
Reviewed-on: https://review.gerrithub.io/c/spdk/spdk/+/461645
Reviewed-by: Changpeng Liu <changpeng.liu@intel.com>
Reviewed-by: Darek Stojaczyk <dariusz.stojaczyk@intel.com>
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
2019-07-17 15:01:20 +00:00
Maciej Wawryk
0abee610f0 test/setup: check open files limit
Signed-off-by: Maciej Wawryk <maciejx.wawryk@intel.com>
Change-Id: I0826c93934025a5ec7126f0f6223d42177054f06
Reviewed-on: https://review.gerrithub.io/c/spdk/spdk/+/462010
Reviewed-by: Darek Stojaczyk <dariusz.stojaczyk@intel.com>
Reviewed-by: Shuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com>
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
2019-07-17 09:20:11 +00:00
Seth Howell
e2c0d9a294 rpc: fix nvmf_create_transport c2h_success option.
This option was intended to enable the user to disable the c2h_option,
but because of the way arguments filter down through the python script,
it was actually impossible to disable the optimization.
My understanding is that typically we will want to keep this
optimization enabled on most systems, but the option should work like it
says it does.

Also, align the implementation of this function with the other ones on
the RPC i.e. use the store_true, store_false paradigm.

Change-Id: I59f0e9a573abf1d567e5539294c63c68899b35f1
Signed-off-by: Seth Howell <seth.howell@intel.com>
Reviewed-on: https://review.gerrithub.io/c/spdk/spdk/+/461737
Reviewed-by: Shuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com>
Reviewed-by: Changpeng Liu <changpeng.liu@intel.com>
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
2019-07-16 01:25:54 +00:00
Vitaliy Mysak
10b8e7cf3e spdkcli: fix pmem_pool_info command
`pmem_pool_info` was incorrectly set to invoke
  `delete_pmem_pool` RPC method.

The name of command was also incorrect - "info_pmem_pool"
  instead of "pmem_pool_info", where
  latter is the original name of RPC method.

This patch fixes both issues with `pmem_pool_info`.

This bug has not been caught because
  there are no tests for `pmem_pool_info` command yet.

Change-Id: Icc207bc3a7cf6c817cb079137d7b473f52186a84
Signed-off-by: Vitaliy Mysak <vitaliy.mysak@intel.com>
Reviewed-on: https://review.gerrithub.io/c/spdk/spdk/+/460840
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Reviewed-by: Ben Walker <benjamin.walker@intel.com>
Reviewed-by: Karol Latecki <karol.latecki@intel.com>
Reviewed-by: Darek Stojaczyk <dariusz.stojaczyk@intel.com>
2019-07-15 03:39:06 +00:00
Evgeniy Kochetov
fca6ff8f75 rpc: Add nvmf_get_stats RPC method
This patch adds nvmf_get_stats RPC method and basic infrastructure to
report NVMf global and per poll group statistics in JSON format.

Signed-off-by: Evgeniy Kochetov <evgeniik@mellanox.com>
Change-Id: I13b83e28b75a02bc1dcb7b95cbce52ae10ff0f7b
Reviewed-on: https://review.gerrithub.io/c/spdk/spdk/+/452298
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Reviewed-by: Ben Walker <benjamin.walker@intel.com>
Reviewed-by: Shuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com>
Reviewed-by: Darek Stojaczyk <dariusz.stojaczyk@intel.com>
2019-07-12 12:46:29 +00:00
Tomasz Kulasek
c39e1e96c2 scripts/check_format: fix checking patch files
This patch excludes *.patch files from some checks in check_format.sh:

 - trailing spaces,
 - POSIX includes

Change-Id: Ic55ce7f4128ddc946d235b4ca487061075edc03b
Signed-off-by: Tomasz Kulasek <tomaszx.kulasek@intel.com>
Reviewed-on: https://review.gerrithub.io/c/spdk/spdk/+/460939
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Reviewed-by: Tomasz Zawadzki <tomasz.zawadzki@intel.com>
Reviewed-by: Darek Stojaczyk <dariusz.stojaczyk@intel.com>
Reviewed-by: Ben Walker <benjamin.walker@intel.com>
Reviewed-by: Paul Luse <paul.e.luse@intel.com>
2019-07-12 07:48:09 +00:00
Tomasz Kulasek
4171d1f552 scripts/check_format: fix unsupported git pathspec magic exclude
Pathspec magic exclude is unsupported in git <1.9.5.

Change-Id: Ibba4e6d6f0fa34ce766a42af0cd32a1dc3d16716
Signed-off-by: Tomasz Kulasek <tomaszx.kulasek@intel.com>
Reviewed-on: https://review.gerrithub.io/c/spdk/spdk/+/460973
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Reviewed-by: Tomasz Zawadzki <tomasz.zawadzki@intel.com>
Reviewed-by: Darek Stojaczyk <dariusz.stojaczyk@intel.com>
Reviewed-by: Ben Walker <benjamin.walker@intel.com>
Reviewed-by: Paul Luse <paul.e.luse@intel.com>
2019-07-12 07:48:09 +00:00
Evgeniy Kochetov
7535cdbd62 rpc: Add thread_get_stats RPC method
SPDK threads collect busy and idle time statistics. This commit adds
thread_get_stats RPC method to retrieve these values.

Signed-off-by: Evgeniy Kochetov <evgeniik@mellanox.com>
Change-Id: I8ed8041c6164eb0c0a9336f4e50b5f26a3f20190
Reviewed-on: https://review.gerrithub.io/c/spdk/spdk/+/445285
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Reviewed-by: Shuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com>
Reviewed-by: Seth Howell <seth.howell5141@gmail.com>
Reviewed-by: Darek Stojaczyk <dariusz.stojaczyk@intel.com>
Reviewed-by: Ben Walker <benjamin.walker@intel.com>
Reviewed-by: Paul Luse <paul.e.luse@intel.com>
2019-07-10 04:28:14 +00:00
Changpeng Liu
5317a9f795 rpc/nvmf: add RPC support to add the persistent configuration file for one NS
Change-Id: Ic4963d3e55cffceca35d18ba8d406658e51a189a
Signed-off-by: Changpeng Liu <changpeng.liu@intel.com>
Reviewed-on: https://review.gerrithub.io/c/spdk/spdk/+/455913
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Reviewed-by: Ben Walker <benjamin.walker@intel.com>
Reviewed-by: Shuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com>
2019-07-10 01:40:26 +00:00
Shuhei Matsumoto
390cffb64e rpc: Add dif_insert_or_strip parameter to nvmf_create_transport RPC
Add an new optional parameter dif_insert_or_strip to
nvmf_create_transport RPC.

.INI config file will be deprecated and dif_insert_or_strip is not
supported in .INI config file.

Change-Id: Ibf38b599cff75eeb0056dd2125d6ec10d444f339
Signed-off-by: Shuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com>
Reviewed-on: https://review.gerrithub.io/c/spdk/spdk/+/458927
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Reviewed-by: Paul Luse <paul.e.luse@intel.com>
Reviewed-by: Changpeng Liu <changpeng.liu@intel.com>
2019-07-10 00:43:02 +00:00
Karol Latecki
772eb8ebbb scripts: replace egrep with grep -E
Calling egrep is non-standard and deprecated.
Use grep -E instead.

Change-Id: Ie5ce5faa641550c4fb08bb32796a46f2aeb76c61
Signed-off-by: Karol Latecki <karol.latecki@intel.com>
Reviewed-on: https://review.gerrithub.io/c/spdk/spdk/+/460516
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Reviewed-by: Darek Stojaczyk <dariusz.stojaczyk@intel.com>
Reviewed-by: Ben Walker <benjamin.walker@intel.com>
2019-07-05 12:06:10 +00:00
Karol Latecki
cf090c6cb9 scripts: replace backticsk with dollar-parenthesis syntax
Scripts were using a mix of two approaches, lets unify that so
just dollar-parenthesis syntax is used.

Also update two scripts from spdk/test which we previously missed.

Change-Id: I429f9bc158076462b419fae597f716c329f9b7aa
Signed-off-by: Karol Latecki <karol.latecki@intel.com>
Reviewed-on: https://review.gerrithub.io/c/spdk/spdk/+/460344
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Reviewed-by: Darek Stojaczyk <dariusz.stojaczyk@intel.com>
Reviewed-by: Shuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com>
Reviewed-by: Ben Walker <benjamin.walker@intel.com>
2019-07-05 12:06:10 +00:00
Darek Stojaczyk
c47d6541e0 scripts/rpc.py: rename mock_ functions
There will be one more "mocked" implementation soon,
so make existing names more descriptive now.

Change-Id: I30daf2b60ab683d5befb06eca50d455712858d61
Signed-off-by: Darek Stojaczyk <dariusz.stojaczyk@intel.com>
Reviewed-on: https://review.gerrithub.io/c/spdk/spdk/+/459390
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Reviewed-by: Shuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com>
Reviewed-by: Ben Walker <benjamin.walker@intel.com>
2019-07-04 07:16:52 +00:00
Darek Stojaczyk
31c25ab3ae scripts/rpc.py: rename print_string to print_json
The previous name wasn't very accurate. The function
accepts a json object, so call it print_json().

Change-Id: If1cae587fd13f0a8a2761049125fc7fb234c0360
Signed-off-by: Darek Stojaczyk <dariusz.stojaczyk@intel.com>
Reviewed-on: https://review.gerrithub.io/c/spdk/spdk/+/459388
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Reviewed-by: Ben Walker <benjamin.walker@intel.com>
Reviewed-by: Shuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com>
2019-07-04 07:16:52 +00:00
Ben Walker
4a770fa9f1 test/vhost: Export default VM_IMAGE from common.sh
Also, construct this path by grabbing the home directory
of the current user.

Change-Id: Ia8d5cc2be40c0c3ac693c80a3132b970f7124183
Signed-off-by: Ben Walker <benjamin.walker@intel.com>
Reviewed-on: https://review.gerrithub.io/c/spdk/spdk/+/456704
Reviewed-by: Changpeng Liu <changpeng.liu@intel.com>
Reviewed-by: Shuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com>
Reviewed-by: Darek Stojaczyk <dariusz.stojaczyk@intel.com>
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
2019-07-03 04:15:18 +00:00
Mateusz Kozlowski
60c8845fd0 bdev/ftl: construct_ftl_bdev respects default ftl config
Changed initialization of the ftl lib when using an rpc call to
allow for usage of any default configuration parameters (currently
only allow_open_bands is exposed).

Signed-off-by: Mateusz Kozlowski <mateusz.kozlowski@intel.com>
Change-Id: I73457dfcacc6b1adeffd13ecc6e98001749e00cf
Reviewed-on: https://review.gerrithub.io/c/spdk/spdk/+/459741
Reviewed-by: Konrad Sztyber <konrad.sztyber@intel.com>
Reviewed-by: Wojciech Malikowski <wojciech.malikowski@intel.com>
Reviewed-by: Darek Stojaczyk <dariusz.stojaczyk@intel.com>
Reviewed-by: Shuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com>
Reviewed-by: Ben Walker <benjamin.walker@intel.com>
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
2019-07-01 14:46:26 +00:00
Liang Yan
4ebf5cef63 perf/nvmf: add link files into zipped SPDK source codes
Change-Id: I9581c936a40be8ccf352778c62bba09ab5a9428e
Signed-off-by: Liang Yan <liang.z.yan@intel.com>
Reviewed-on: https://review.gerrithub.io/c/spdk/spdk/+/459091
Reviewed-by: Karol Latecki <karol.latecki@intel.com>
Reviewed-by: Shuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com>
Reviewed-by: Ben Walker <benjamin.walker@intel.com>
Reviewed-by: Darek Stojaczyk <dariusz.stojaczyk@intel.com>
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
2019-06-28 05:36:37 +00:00
paul luse
bfda995be2 bdev/compress: add RPC to specify PMD
By default QAT will be selected if available however a new RPC
can be used to either auto-select (default) or specify either
ISAL or QAT.

Change-Id: I37cf7640bbd8cef455583e1eccb8adb59cc419d8
Signed-off-by: paul luse <paul.e.luse@intel.com>
Reviewed-on: https://review.gerrithub.io/c/spdk/spdk/+/456693
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Reviewed-by: Shuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com>
Reviewed-by: Ben Walker <benjamin.walker@intel.com>
Reviewed-by: Darek Stojaczyk <dariusz.stojaczyk@intel.com>
2019-06-26 07:57:09 +00:00
Or Gerlitz
6629202cbd nvmf/tcp: Use the success optimization by default
By now (5.1 is released), the Linux kernel initiator supports the
success optimization and further, the version that doesn't support
it (5.0) was EOL-ed. As such, lets open it up @ spdk by default.

Doing so provides a notable performance improvement: running perf with
iodepth of 64, randread, two threads and block size of 512 bytes for 60s
("-q 64 -w randread -o 512 -c 0x5000 -t 60") over the VMA socket acceleration
library and null backing store, we got 730K IOPS with the success
optimization vs 550K without it.

IOPS           MiB/s    Average       min      max
549274.10     268.20     232.99      93.23 3256354.96
728117.57     355.53     175.76      85.93   14632.16

To allow for interop with older kernel initiators, we added
a config knob under which the success optimization can be
enabled or disabled.

Change-Id: Ia4c79f607f82c3563523ae3e07a67eac95b56dbb
Signed-off-by: Or Gerlitz <ogerlitz@mellanox.com>
Reviewed-on: https://review.gerrithub.io/c/spdk/spdk/+/457644
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Reviewed-by: Ben Walker <benjamin.walker@intel.com>
Reviewed-by: Shuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com>
Reviewed-by: Ziye Yang <ziye.yang@intel.com>
Reviewed-by: Darek Stojaczyk <dariusz.stojaczyk@intel.com>
2019-06-26 06:24:03 +00:00
Karol Latecki
0c939301cb scripts/Vagrant: update vagrant boxes
Removing Fedora 26 and 27 which are long past their EOL date.
Adding Fedora 29 and 30.

Change-Id: I35bc8b7a5ac693b7a5af0e6abb35869b18ed5777
Signed-off-by: Karol Latecki <karol.latecki@intel.com>
Reviewed-on: https://review.gerrithub.io/c/spdk/spdk/+/457924
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Reviewed-by: yidong0635 <dongx.yi@intel.com>
Reviewed-by: Pawel Kaminski <pawelx.kaminski@intel.com>
Reviewed-by: Paul Luse <paul.e.luse@intel.com>
Reviewed-by: Darek Stojaczyk <dariusz.stojaczyk@intel.com>
Reviewed-by: Shuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com>
Reviewed-by: Ben Walker <benjamin.walker@intel.com>
2019-06-25 08:27:53 +00:00
paul luse
8d2455caa3 bdev/compress: always use QAT if available
The next patch in this series introduces and RPC that makes the
selection more flexible.

Signed-off-by: paul luse <paul.e.luse@intel.com>
Change-Id: I55617d3c37b51cf9474c358cb92f5218397c0c58
Reviewed-on: https://review.gerrithub.io/c/spdk/spdk/+/457157
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Reviewed-by: Shuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com>
Reviewed-by: Darek Stojaczyk <dariusz.stojaczyk@intel.com>
2019-06-21 07:53:39 +00:00
Liang Yan
f240e2bf48 perf/nvmf: add config file path handling codes
Change-Id: I27c8c4a03237c75761c75cce824a65fe3e4776db
Signed-off-by: Liang Yan <liang.z.yan@intel.com>
Reviewed-on: https://review.gerrithub.io/c/spdk/spdk/+/454760
Reviewed-by: John Kariuki <John.K.Kariuki@intel.com>
Reviewed-by: Paul Luse <paul.e.luse@intel.com>
Reviewed-by: Shuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com>
Reviewed-by: Darek Stojaczyk <dariusz.stojaczyk@intel.com>
Reviewed-by: Karol Latecki <karol.latecki@intel.com>
Reviewed-by: Changpeng Liu <changpeng.liu@intel.com>
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
2019-06-19 07:14:06 +00:00
Pawel Kaminski
6e4ea8fdb4 rpc.py: add --dry-run option to print the json request and exit
Change-Id: If20c10cb74e3825fc29b9d45524353f77b832e4f
Signed-off-by: Pawel Kaminski <pawelx.kaminski@intel.com>
Reviewed-on: https://review.gerrithub.io/c/spdk/spdk/+/457145
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Reviewed-by: Darek Stojaczyk <dariusz.stojaczyk@intel.com>
Reviewed-by: Shuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com>
2019-06-19 03:50:30 +00:00
yidong0635
48cec0b127 vm_setup: fix scan-build not found on ubuntu18
Report issue on ubuntu18 :
"spdk/autobuild.sh: line 55: hash: scan-build: not found"

Check that ubuntu18 should install this package:
apt-get install -y clang-tools, to fit version of ubuntu18
and later.

Move clang-analyzer which for fedora to vm_setup.sh as well.

Change-Id: Ia702c492f8b0f64705c7c15ee57a861ca14521f9
signed-off-by: yidong0635 <dongx.yi@intel.com>
Reviewed-on: https://review.gerrithub.io/c/spdk/spdk/+/457554
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Reviewed-by: Ben Walker <benjamin.walker@intel.com>
Reviewed-by: Karol Latecki <karol.latecki@intel.com>
Reviewed-by: Darek Stojaczyk <dariusz.stojaczyk@intel.com>
2019-06-18 12:55:25 +00:00
Karol Latecki
535654f826 scripts/rpc: add try-except around call_rpc_func
Missing try-except block around call_rpc_func().
If called function returned error there was an uncaught exception
which resulted in backtrace printed to screen.

Change-Id: Ifb37c29d70b93ef648a0503643a51cc1967ef8d0
Signed-off-by: Karol Latecki <karol.latecki@intel.com>
Reviewed-on: https://review.gerrithub.io/c/spdk/spdk/+/456956
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Reviewed-by: Ben Walker <benjamin.walker@intel.com>
Reviewed-by: Darek Stojaczyk <dariusz.stojaczyk@intel.com>
2019-06-08 11:16:07 +00:00
Mateusz Kozlowski
42fe2e9b24 lib/ftl: Add config to construct_ftl rpc for dirty shutdown restore
Gives the ability to change behavior of restore after dirty shutdown
without recompiling ftl library. User can define if partial recovery
or error should be returned after such a scenario.

Signed-off-by: Mateusz Kozlowski <mateusz.kozlowski@intel.com>
Change-Id: I6dda40df7b92d6a377957e4a70a3eab91a6ac4a9
Reviewed-on: https://review.gerrithub.io/c/spdk/spdk/+/456185
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Reviewed-by: Darek Stojaczyk <dariusz.stojaczyk@intel.com>
Reviewed-by: Ben Walker <benjamin.walker@intel.com>
Reviewed-by: Konrad Sztyber <konrad.sztyber@intel.com>
2019-06-07 18:26:57 +00:00
Vitaliy Mysak
1e0e0ea1fc ocf: RPC add WriteBack to allowed cache modes
Make construct_ocf_bdev call accept 'wb'
  as allowed cache mode.
Previusly user could only create OCF bdevs
  in WriteThrough or PassThrough modes.

Change-Id: Ic2e1c8d2905cb51fc13c080aa7b7a4dfd7d9387f
Signed-off-by: Vitaliy Mysak <vitaliy.mysak@intel.com>
Reviewed-on: https://review.gerrithub.io/c/spdk/spdk/+/455628
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Reviewed-by: Darek Stojaczyk <dariusz.stojaczyk@intel.com>
Reviewed-by: Ben Walker <benjamin.walker@intel.com>
Reviewed-by: Tomasz Zawadzki <tomasz.zawadzki@intel.com>
2019-06-07 18:18:42 +00:00
Pawel Kaminski
3bf82af866 script/rpc: Display request when rpc throws exception.
This change will allow easier debugging of
what parameters are sent to spdk target.
It will also help to analyse which commands will fail
if multiple commands are sent to rpc.py.

Change-Id: I8e75b5edce791a1fc41e83664add8893f4c1bbfb
Signed-off-by: Pawel Kaminski <pawelx.kaminski@intel.com>
Reviewed-on: https://review.gerrithub.io/c/spdk/spdk/+/455636
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Reviewed-by: Jim Harris <james.r.harris@intel.com>
Reviewed-by: Ben Walker <benjamin.walker@intel.com>
Reviewed-by: Shuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com>
2019-06-04 03:36:26 +00:00
Seth Howell
5470a0584f scripts/fio.py: add argparse for command line parameters
This script was getting a bit unwieldy. adding argparse will make it
easier to add more options in the future or to set default values and
validate arguments going forward.

Change-Id: I1ffdbdf2082287ceb8a88cd3eb6ecf9bbd6c9e11
Signed-off-by: Seth Howell <seth.howell@intel.com>
Reviewed-on: https://review.gerrithub.io/c/spdk/spdk/+/455724
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: Darek Stojaczyk <dariusz.stojaczyk@intel.com>
2019-06-03 04:34:10 +00:00
Seth Howell
3fb4a66d7d bdev: Create a new delay vbdev module
This module simply sits on another virtual bdev
and adds a simulated average and p99 latency to that drive.

Change-Id: Ie9fc91e27585fd0636cb7dc845cb41744bf24625
Signed-off-by: Seth Howell <seth.howell@intel.com>
Reviewed-on: https://review.gerrithub.io/c/spdk/spdk/+/453594
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: Darek Stojaczyk <dariusz.stojaczyk@intel.com>
2019-05-31 14:37:26 +00:00
John Kariuki
d601374387 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>
2019-05-30 22:01:13 +00:00
Tomasz Kulasek
843ca21287 scripts/fio.py: fix sysfs delay
After iSCSI login sysfs is not updated immediately, but when session is
initialized. It can take a while and causes that sometimes scripts
cannot write to sysfs.

Change-Id: Ie4fa512704f022041bb3d9ab02dbb4210ddd04a0
Signed-off-by: Tomasz Kulasek <tomaszx.kulasek@intel.com>
Reviewed-on: https://review.gerrithub.io/c/spdk/spdk/+/454890
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Reviewed-by: Tomasz Zawadzki <tomasz.zawadzki@intel.com>
Reviewed-by: Maciej Szwed <maciej.szwed@intel.com>
Reviewed-by: Jim Harris <james.r.harris@intel.com>
Reviewed-by: Ben Walker <benjamin.walker@intel.com>
Reviewed-by: Shuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com>
2019-05-30 04:08:37 +00:00
Wojciech Malikowski
a6edaa9600 scripts/setup: Added binding VMD devices
To bind VMD device it need to be specified
in PCI_WHITELIST.

Change-Id: If19c47941278e4df9c6157024bba8b76c90695c6
Signed-off-by: Wojciech Malikowski <wojciech.malikowski@intel.com>
Signed-off-by: Orden Smith <orden.e.smith@intel.com>
Signed-off-by: Darek Stojaczyk <dariusz.stojaczyk@intel.com>
Reviewed-on: https://review.gerrithub.io/c/spdk/spdk/+/455635
Reviewed-by: Ben Walker <benjamin.walker@intel.com>
Reviewed-by: Jim Harris <james.r.harris@intel.com>
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
2019-05-29 20:35:11 +00:00
Jim Harris
6ee44c694e rpc: rename RPC get_rpc_methods to rpc_get_methods
Make the old name a deprecated alias.

Signed-off-by: Jim Harris <james.r.harris@intel.com>
Change-Id: Ibbf50676e0d989b67121e465fc140f94faec46ed

Reviewed-on: https://review.gerrithub.io/c/spdk/spdk/+/453033
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Reviewed-by: Darek Stojaczyk <dariusz.stojaczyk@intel.com>
Reviewed-by: Shuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com>
Reviewed-by: Ben Walker <benjamin.walker@intel.com>
2019-05-27 12:52:53 +00:00
Jim Harris
caec89289f scripts/rpc.py: allow empty lines when executing script
This is a bit more flexible in case script accidentally
has an extra newline at the end of the rpc.py input.

Signed-off-by: Jim Harris <james.r.harris@intel.com>
Change-Id: I1ebf08681e5900a4817712c7b62e4d5c21d43e54

Reviewed-on: https://review.gerrithub.io/c/spdk/spdk/+/453956
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Reviewed-by: Karol Latecki <karol.latecki@intel.com>
Reviewed-by: Shuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com>
Reviewed-by: Ben Walker <benjamin.walker@intel.com>
2019-05-14 19:07:31 +00:00
Mike Carlin
fb6fbf3256 spdkcli: Add support for raid devices
Adds support to spdkcli.py for raid devices via UIRaidBdev with
functionality to construct and destroy raid bdevs.

Information regarding the raid can be viewed via 'show_details' on a
given pooled_device child in the tree.

Signed-off-by: Mike Carlin <mikefcarlin@protonmail.com>
Change-Id: I2ca89e641b201c09b3d4db070eac6cc0c2cdec73
Reviewed-on: https://review.gerrithub.io/c/spdk/spdk/+/452774
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: Pawel Kaminski <pawelx.kaminski@intel.com>
Reviewed-by: Ben Walker <benjamin.walker@intel.com>
2019-05-09 19:36:35 +00:00
Jim Harris
e2d7d02d65 log: use new framework for marking deprecated RPCs
We marked the old set/clear/get_trace_flags as
deprecated in v19.01.  These are now called
set/clear/get_log_flags (to reduce confusion with the
tracing framework).  Use the new methods in this
patch series to mark these RPCs as deprecated.

Signed-off-by: Jim Harris <james.r.harris@intel.com>
Change-Id: I5ce8992ce8f6c1de5d5596b5f94a1587555e8546

Reviewed-on: https://review.gerrithub.io/c/spdk/spdk/+/453563
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Reviewed-by: Shuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com>
Reviewed-by: Ben Walker <benjamin.walker@intel.com>
2019-05-09 04:37:08 +00:00
Jim Harris
c2b5a3f6b4 rpc.py: add framework for detecting deprecated aliases
This will get used in upcoming patches that actually
create RPC aliases.

Thanks to Ben Walker for help on the deprecated_alias
helper.

Signed-off-by: Jim Harris <james.r.harris@intel.com>
Change-Id: Ica4432888b1ecb9bd234690758f67ef82794c50a

Reviewed-on: https://review.gerrithub.io/c/spdk/spdk/+/453035
Reviewed-by: Ben Walker <benjamin.walker@intel.com>
Reviewed-by: Shuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com>
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
2019-05-09 04:37:08 +00:00
Karol Latecki
22c3befd3d scripts/rpc.py: fix pipe for whitespace separated list arguments
Ordinary python str.split() will by default split on each whitespace.
This includes arguments for rpc.py which expect a whitespace separated list,
eg. construct_raid_bdev -b "Bdev_1 Bdev_2".
shlex.split() prevents splitting on quoted arguments.

Change-Id: If37eb87cf82a161263f2b247baff5c8a77c43efc
Signed-off-by: Karol Latecki <karol.latecki@intel.com>
Reviewed-on: https://review.gerrithub.io/c/spdk/spdk/+/453652
Reviewed-by: Tomasz Zawadzki <tomasz.zawadzki@intel.com>
Reviewed-by: Darek Stojaczyk <dariusz.stojaczyk@intel.com>
Reviewed-by: Ben Walker <benjamin.walker@intel.com>
Reviewed-by: Pawel Kaminski <pawelx.kaminski@intel.com>
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
2019-05-08 14:43:59 +00:00
Jim Harris
ac0824b2d8 rpc.py: detect stdin pipe
If user calls rpc.py with no parameters, it currently
hangs, waiting for input.  It should print help in this
case instead.

Signed-off-by: Jim Harris <james.r.harris@intel.com>
Change-Id: I5939999c57b8db0916267935d79ccc1a3201748b

Reviewed-on: https://review.gerrithub.io/c/spdk/spdk/+/453431
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Reviewed-by: Ben Walker <benjamin.walker@intel.com>
Reviewed-by: Darek Stojaczyk <dariusz.stojaczyk@intel.com>
2019-05-07 15:48:22 +00:00
Seth Howell
350e429a57 rdma: add a flag for disabling srq.
There are cases where srq can be a detriment. Add a flag to allow users
to disable srq even if they have a piece of hardware that supports it.

Change-Id: Ia3be8e8c8e8463964e6ff1c02b07afbf4c3cc8f7
Signed-off-by: Seth Howell <seth.howell@intel.com>
Reviewed-on: https://review.gerrithub.io/c/spdk/spdk/+/452271
Reviewed-by: Jim Harris <james.r.harris@intel.com>
Reviewed-by: Shuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com>
Reviewed-by: Ben Walker <benjamin.walker@intel.com>
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
2019-05-06 18:11:13 +00:00
Seth Howell
9d0e11d4a2 rdma: clean up the create_transport rpc docs
Just a couple minor clarifications.

Change-Id: I6c368d263296f742d5bfb0df431d3bf40c800c6c
Signed-off-by: Seth Howell <seth.howell@intel.com>
Reviewed-on: https://review.gerrithub.io/c/spdk/spdk/+/452270
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: Ben Walker <benjamin.walker@intel.com>
2019-05-06 18:11:13 +00:00
Ben Walker
af8affd1a9 iscsi: Deprecate MinConnectionsPerCore
iSCSI is currently being adapted to SPDK's new threading model,
and this parameter doesn't make sense anymore. Remove it for
now until something functionally equivalent is added later.

Change-Id: Ia0e2f5aa81b72d99467c5a900619fbeeb42b2069
Signed-off-by: Ben Walker <benjamin.walker@intel.com>
Reviewed-on: https://review.gerrithub.io/c/spdk/spdk/+/452779
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Reviewed-by: Shuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com>
Reviewed-by: Darek Stojaczyk <dariusz.stojaczyk@intel.com>
Reviewed-by: Jim Harris <james.r.harris@intel.com>
2019-05-06 17:10:48 +00:00
Mike Carlin
a6524cd1f8 raid bdev: Change product_name to "Raid Volume"
The product_name for raid bdevs was "Pooled Device" which was a legacy
naming convention that hadn't been cleaned up yet. This changes the
naming to be up to date with the current naming scheme.

Signed-off-by: Mike Carlin <mikefcarlin@protonmail.com>
Change-Id: I9092a2b793e48bb9ec0349087a31fdcde17ed9cd
Reviewed-on: https://review.gerrithub.io/c/spdk/spdk/+/452269
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Reviewed-by: Darek Stojaczyk <dariusz.stojaczyk@intel.com>
Reviewed-by: Ben Walker <benjamin.walker@intel.com>
Reviewed-by: Paul Luse <paul.e.luse@intel.com>
Reviewed-by: Shuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com>
Reviewed-by: Jim Harris <james.r.harris@intel.com>
2019-05-02 09:02:52 +00:00
Jim Harris
363fe506bc scripts/rpc.py: allow users to pipe multiple requests
Users can now pipe a large number of requests to
rpc.py, separated by newlines - each line will be
executed as if it was passed to rpc.py individually.

There is significant savings using this feature when
executing multiple requests through rpc.py.  On my
system, a loop of 30 RPCs related to setting up
10 NVMf subsystems takes 5 seconds when executed
one at a time.  With this new feature, it takes
less than 1 second.

Signed-off-by: Jim Harris <james.r.harris@intel.com>
Change-Id: Iec957ca67461af8e8c41aee47e1d113714b22d3d

Reviewed-on: https://review.gerrithub.io/c/spdk/spdk/+/452770
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Reviewed-by: Ben Walker <benjamin.walker@intel.com>
Reviewed-by: Shuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com>
2019-05-02 08:53:56 +00:00
Jim Harris
6895f0f27e scripts/rpc.py: add call_rpc_func()
This makes no functional change to the script, but
it prepares for an upcoming change allowing callers
to pipe a newline delimited list of rpc calls.

Signed-off-by: Jim Harris <james.r.harris@intel.com>
Change-Id: I695ca61510f9edd336713e88d134e42c1d78a1b4

Reviewed-on: https://review.gerrithub.io/c/spdk/spdk/+/452769
Reviewed-by: Ben Walker <benjamin.walker@intel.com>
Reviewed-by: Shuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com>
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
2019-05-02 08:53:56 +00:00
Darek Stojaczyk
e72445c4c8 scripts/fio.py: don't print unnecessary qdepth warnings
Don't print messages like:
"Requested queue_depth 128 but only 128 is supported."

Change-Id: I377ad93bd5c784ae9a91fdf37343f1f47ab8184f
Signed-off-by: Darek Stojaczyk <dariusz.stojaczyk@intel.com>
Reviewed-on: https://review.gerrithub.io/c/spdk/spdk/+/452078
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Reviewed-by: Ben Walker <benjamin.walker@intel.com>
Reviewed-by: Shuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com>
Reviewed-by: Jim Harris <james.r.harris@intel.com>
2019-05-01 17:45:54 +00:00
paul luse
600341b6c5 bdev/compress: replace RPC parm name with pm_path
We decided to name compress bdevs with COMP_ and then the name of
the underlying bdev so the RPC parm name was stale.  Previously
hardcoded the path to PM for early dev so replaced name with pm_path.

Note that a sample create looks like this now:

rpc.py construct_compress_bdev -b NVMe0n1 -p ~/pm_files -d compress_isal

And that devs need to pay attention for the pathname they provide, its
easy to leave orphaned pm files around and they can get big.

Change-Id: Ifb5245c922461bbecec4bef266bdeb25e8b87f31
Signed-off-by: paul luse <paul.e.luse@intel.com>
Reviewed-on: https://review.gerrithub.io/c/spdk/spdk/+/452235
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Reviewed-by: Ben Walker <benjamin.walker@intel.com>
Reviewed-by: Jim Harris <james.r.harris@intel.com>
2019-04-26 20:07:19 +00:00