diff --git a/CHANGELOG.md b/CHANGELOG.md index 30ea58edd..5b82cea3a 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,5 +1,14 @@ # Changelog +## v18.01 + +### RPC + +A JSON RPC listener is now enabled by default using a UNIX domain socket at /var/run/spdk.sock. +A -r option command line option has been added to enable an alternative UNIX domain socket location, +or a TCP port in the format ip_addr:tcp_port (i.e. 127.0.0.1:5260). The Rpc configuration file +section is now deprecated and will be removed in the v18.04 release. + ## v17.10: Logical Volumes ### New dependencies diff --git a/autotest.sh b/autotest.sh index 42bf22f0a..a3d22b4cb 100755 --- a/autotest.sh +++ b/autotest.sh @@ -42,6 +42,8 @@ fi # Make sure the disks are clean (no leftover partition tables) timing_enter cleanup +# Remove old domain socket pathname just in case +rm -f $DEFAULT_RPC_ADDR if [ $(uname -s) = Linux ]; then # Load the kernel driver ./scripts/setup.sh reset diff --git a/etc/spdk/iscsi.conf.in b/etc/spdk/iscsi.conf.in index 8c11df70d..5a1eaccb1 100644 --- a/etc/spdk/iscsi.conf.in +++ b/etc/spdk/iscsi.conf.in @@ -62,16 +62,6 @@ ImmediateData Yes ErrorRecoveryLevel 0 -[Rpc] - # Defines whether to enable configuration via RPC. - # Default is disabled. Note that the RPC interface is not - # authenticated, so users should be careful about enabling - # RPC in non-trusted environments. - Enable No - # Listen address for the RPC service. - # May be an IP address or an absolute path to a Unix socket. - Listen 127.0.0.1 - # Users must change the PortalGroup section(s) to match the IP addresses # for their environment. # PortalGroup sections define which TCP ports the iSCSI server will use diff --git a/etc/spdk/nvmf.conf.in b/etc/spdk/nvmf.conf.in index 7e6d08c99..2f0b9c959 100644 --- a/etc/spdk/nvmf.conf.in +++ b/etc/spdk/nvmf.conf.in @@ -20,16 +20,6 @@ # Set to 0xFFFFFFFFFFFFFFFF to enable all tracepoint groups. #TpointGroupMask 0x0 -[Rpc] - # Defines whether to enable configuration via RPC. - # Default is disabled. Note that the RPC interface is not - # authenticated, so users should be careful about enabling - # RPC in non-trusted environments. - Enable No - # Listen address for the RPC service. - # May be an IP address or an absolute path to a Unix socket. - Listen 127.0.0.1 - # Users may change this section to create a different number or size of # malloc LUNs. # This will generate 8 LUNs with a malloc-allocated backend. diff --git a/etc/spdk/rocksdb.conf.in b/etc/spdk/rocksdb.conf.in index e5bfa2965..004609987 100644 --- a/etc/spdk/rocksdb.conf.in +++ b/etc/spdk/rocksdb.conf.in @@ -16,13 +16,6 @@ # on all cores. #ReactorMask 0x1 -[Rpc] - # Defines whether spdk will enable configuration via RPC. - # Default is disabled. Note that the RPC interface is not - # authenticated, so users should be careful about enabling - # RPC in non-trusted environments. - #Enable No - [Ioat] Disable Yes diff --git a/etc/spdk/vhost.conf.in b/etc/spdk/vhost.conf.in index c94cb1418..2e29a1761 100644 --- a/etc/spdk/vhost.conf.in +++ b/etc/spdk/vhost.conf.in @@ -29,16 +29,6 @@ # Set to 0xFFFFFFFFFFFFFFFF to enable all tracepoint groups. #TpointGroupMask 0x0 -[Rpc] - # Defines whether SPDK vhost will enable configuration via RPC. - # Default is disabled. Note that the RPC interface is not - # authenticated, so users should be careful about enabling - # RPC in non-trusted environments. - Enable No - # Listen address for the RPC service. - # May be an IP address or an absolute path to a Unix socket. - Listen 127.0.0.1 - # Users may not want to use offload even it is available. # Users may use the whitelist to initialize specified devices, IDS # uses BUS:DEVICE.FUNCTION to identify each Ioat channel. diff --git a/include/spdk/event.h b/include/spdk/event.h index 7bf318494..db188441f 100644 --- a/include/spdk/event.h +++ b/include/spdk/event.h @@ -63,12 +63,15 @@ struct spdk_poller; typedef void (*spdk_app_shutdown_cb)(void); typedef void (*spdk_sighandler_t)(int); +#define SPDK_DEFAULT_RPC_ADDR "/var/tmp/spdk.sock" + /** * \brief Event framework initialization options */ struct spdk_app_opts { const char *name; const char *config_file; + const char *rpc_addr; /* Can be UNIX domain socket path or IP address + TCP port */ const char *reactor_mask; const char *tpoint_group_mask; @@ -152,7 +155,7 @@ int spdk_app_get_core_count(void) __attribute__((deprecated)); */ uint32_t spdk_app_get_current_core(void) __attribute__((deprecated)); -#define SPDK_APP_GETOPT_STRING "c:de:hi:m:n:p:qs:t:" +#define SPDK_APP_GETOPT_STRING "c:de:hi:m:n:p:qr:s:t:" /** * \brief Helper function for parsing arguments and printing usage messages. diff --git a/include/spdk_internal/event.h b/include/spdk_internal/event.h index aee71d5d5..13efd1f18 100644 --- a/include/spdk_internal/event.h +++ b/include/spdk_internal/event.h @@ -76,7 +76,7 @@ void spdk_subsystem_init_next(int rc); void spdk_subsystem_fini_next(void); void spdk_subsystem_config(FILE *fp); -void spdk_rpc_initialize(void); +void spdk_rpc_initialize(const char *listen_addr); void spdk_rpc_finish(void); void spdk_rpc_config_text(FILE *fp); diff --git a/lib/event/app.c b/lib/event/app.c index aa16e3e78..7c577a577 100644 --- a/lib/event/app.c +++ b/lib/event/app.c @@ -194,6 +194,7 @@ spdk_app_opts_init(struct spdk_app_opts *opts) opts->reactor_mask = NULL; opts->max_delay_us = 0; opts->print_level = SPDK_LOG_NOTICE; + opts->rpc_addr = SPDK_DEFAULT_RPC_ADDR; } static int @@ -256,7 +257,9 @@ spdk_app_setup_signal_handlers(struct spdk_app_opts *opts) static void start_rpc(void *arg1, void *arg2) { - spdk_rpc_initialize(); + const char *rpc_addr = arg1; + + spdk_rpc_initialize(rpc_addr); g_app_start_fn(g_app_start_arg1, g_app_start_arg2); } @@ -407,7 +410,7 @@ spdk_app_start(struct spdk_app_opts *opts, spdk_event_fn start_fn, g_app_start_fn = start_fn; g_app_start_arg1 = arg1; g_app_start_arg2 = arg2; - app_start_event = spdk_event_allocate(g_init_lcore, start_rpc, NULL, NULL); + app_start_event = spdk_event_allocate(g_init_lcore, start_rpc, (void *)opts->rpc_addr, NULL); spdk_subsystem_init(app_start_event); @@ -462,6 +465,7 @@ usage(char *executable_name, struct spdk_app_opts *default_opts, void (*app_usag printf(" -n channel number of memory channels used for DPDK\n"); printf(" -p core master (primary) core for DPDK\n"); printf(" -q disable notice level logging to stderr\n"); + printf(" -r RPC listen address (default %s)\n", SPDK_DEFAULT_RPC_ADDR); printf(" -s size memory size in MB for DPDK (default: "); if (default_opts->mem_size > 0) { printf("%dMB)\n", default_opts->mem_size); @@ -522,6 +526,9 @@ spdk_app_parse_args(int argc, char **argv, struct spdk_app_opts *opts, case 'q': opts->print_level = SPDK_LOG_WARN; break; + case 'r': + opts->rpc_addr = optarg; + break; case 's': opts->mem_size = atoi(optarg); break; diff --git a/lib/event/rpc.c b/lib/event/rpc.c index 29bbb6c35..3b9a5232a 100644 --- a/lib/event/rpc.c +++ b/lib/event/rpc.c @@ -41,40 +41,20 @@ #include "spdk_internal/event.h" #define RPC_SELECT_INTERVAL 4000 /* 4ms */ -#define RPC_DEFAULT_LISTEN_ADDR "127.0.0.1:5260" static struct spdk_poller *g_rpc_poller = NULL; -static int -enable_rpc(void) -{ - struct spdk_conf_section *sp; - - sp = spdk_conf_find_section(NULL, "Rpc"); - if (sp == NULL) { - return 0; - } - - return spdk_conf_section_get_boolval(sp, "Enable", false); -} - static const char * rpc_get_listen_addr(void) { struct spdk_conf_section *sp; - const char *val; sp = spdk_conf_find_section(NULL, "Rpc"); if (sp == NULL) { - return RPC_DEFAULT_LISTEN_ADDR; + return NULL; } - val = spdk_conf_section_get_val(sp, "Listen"); - if (val == NULL) { - val = RPC_DEFAULT_LISTEN_ADDR; - } - - return val; + return spdk_conf_section_get_val(sp, "Listen"); } static void @@ -84,18 +64,16 @@ spdk_rpc_subsystem_poll(void *arg) } void -spdk_rpc_initialize(void) +spdk_rpc_initialize(const char *listen_addr) { - const char *listen_addr; int rc; - if (!enable_rpc()) { - return; + if (rpc_get_listen_addr() != NULL) { + listen_addr = rpc_get_listen_addr(); } - listen_addr = rpc_get_listen_addr(); if (listen_addr == NULL) { - listen_addr = RPC_DEFAULT_LISTEN_ADDR; + return; } /* Listen on the requested address */ @@ -123,13 +101,7 @@ spdk_rpc_config_text(FILE *fp) fprintf(fp, "\n" "[Rpc]\n" - " # Defines whether to enable configuration via RPC.\n" - " # Default is disabled. Note that the RPC interface is not\n" - " # authenticated, so users should be careful about enabling\n" - " # RPC in non-trusted environments.\n" - " Enable %s\n" " # Listen address for the RPC service.\n" " # May be an IP address or an absolute path to a Unix socket.\n" - " Listen %s\n", - enable_rpc() ? "Yes" : "No", rpc_get_listen_addr()); + " Listen %s\n", rpc_get_listen_addr()); } diff --git a/lib/iscsi/iscsi_subsystem.c b/lib/iscsi/iscsi_subsystem.c index 1f1aadebb..1a0d4599c 100644 --- a/lib/iscsi/iscsi_subsystem.c +++ b/lib/iscsi/iscsi_subsystem.c @@ -76,9 +76,6 @@ "\n" \ " ImmediateData %s\n" \ " ErrorRecoveryLevel %d\n" \ -"\n" \ -" # Defines whether iSCSI target will enable configuration via RPC\n" \ -" # RpcConfiguration Yes\n" \ "\n" static void diff --git a/lib/rpc/rpc.c b/lib/rpc/rpc.c index 2f96bf5fe..65f96d51d 100644 --- a/lib/rpc/rpc.c +++ b/lib/rpc/rpc.c @@ -93,7 +93,10 @@ spdk_rpc_listen(const char *listen_addr) return -1; } - unlink(g_rpc_listen_addr_unix.sun_path); + if (access(g_rpc_listen_addr_unix.sun_path, F_OK) == 0) { + SPDK_ERRLOG("RPC Unix domain socket path already exists.\n"); + return -1; + } g_jsonrpc_server = spdk_jsonrpc_server_listen(AF_UNIX, 0, (struct sockaddr *)&g_rpc_listen_addr_unix, diff --git a/scripts/autotest_common.sh b/scripts/autotest_common.sh index d81bd44df..b801515c3 100755 --- a/scripts/autotest_common.sh +++ b/scripts/autotest_common.sh @@ -46,6 +46,8 @@ export SPDK_GPT_GUID=`grep SPDK_GPT_PART_TYPE_GUID $rootdir/lib/bdev/gpt/gpt.h \ # Override the default HUGEMEM in scripts/setup.sh export HUGEMEM=8192 +DEFAULT_RPC_ADDR=/var/tmp/spdk.sock + case `uname` in FreeBSD) DPDK_FREEBSD_DIR=/usr/local/share/dpdk/x86_64-native-bsdapp-clang @@ -179,6 +181,29 @@ function process_core() { } function waitforlisten() { + # $1 = process pid + if [ -z "$1" ]; then + exit 1 + fi + + echo "Waiting for process to start up and listen on UNIX domain socket $DEFAULT_RPC_ADDR..." + # turn off trace for this loop + set +x + ret=1 + while [ $ret -ne 0 ]; do + # if the process is no longer running, then exit the script + # since it means the application crashed + if ! kill -s 0 $1; then + exit + fi + if netstat -an -x | grep -iw LISTENING | grep -q $DEFAULT_RPC_ADDR; then + ret=0 + fi + done + set -x +} + +function waitforlisten_tcp() { # $1 = process pid # $2 = TCP port number if [ -z "$1" ] || [ -z "$2" ]; then @@ -353,7 +378,7 @@ function part_dev_by_gpt () { $rootdir/test/lib/bdev/nbd/nbd -c ${conf}.gpt -b $devname -n /dev/nbd0 & nbd_pid=$! echo "Process nbd pid: $nbd_pid" - waitforlisten $nbd_pid 5260 + waitforlisten $nbd_pid waitfornbd nbd0 if [ "$operation" = create ]; then diff --git a/scripts/rpc.py b/scripts/rpc.py index f80f1405b..883fa1ffb 100755 --- a/scripts/rpc.py +++ b/scripts/rpc.py @@ -16,8 +16,8 @@ def print_array(a): print " ".join((quote(v) for v in a)) parser = argparse.ArgumentParser(description='SPDK RPC command line interface') -parser.add_argument('-s', dest='server_addr', help='RPC server address', default='127.0.0.1') -parser.add_argument('-p', dest='port', help='RPC port number', default=5260, type=int) +parser.add_argument('-s', dest='server_addr', help='RPC server address', default='/var/tmp/spdk.sock') +parser.add_argument('-p', dest='port', help='RPC port number (if server_addr is IP address)', default=5260, type=int) parser.add_argument('-v', dest='verbose', help='Verbose mode', action='store_true') subparsers = parser.add_subparsers(help='RPC methods') diff --git a/test/app/stub/stub.c b/test/app/stub/stub.c index 8b176ffed..595e75bcb 100644 --- a/test/app/stub/stub.c +++ b/test/app/stub/stub.c @@ -100,6 +100,7 @@ main(int argc, char **argv) spdk_app_opts_init(&opts); opts.name = "stub"; + opts.rpc_addr = NULL; while ((ch = getopt(argc, argv, "i:m:n:p:s:H")) != -1) { switch (ch) { diff --git a/test/iscsi_tgt/calsoft/calsoft.sh b/test/iscsi_tgt/calsoft/calsoft.sh index efa5f2b03..4ee3b7c57 100755 --- a/test/iscsi_tgt/calsoft/calsoft.sh +++ b/test/iscsi_tgt/calsoft/calsoft.sh @@ -13,7 +13,6 @@ timing_enter calsoft # iSCSI target configuration PORT=3260 -RPC_PORT=5260 INITIATOR_TAG=2 INITIATOR_NAME=ALL NETMASK=$INITIATOR_IP/32 @@ -36,7 +35,7 @@ echo "Process pid: $pid" trap "killprocess $pid; exit 1 " SIGINT SIGTERM EXIT -waitforlisten $pid ${RPC_PORT} +waitforlisten $pid echo "iscsi_tgt is listening. Running tests..." timing_exit start_iscsi_tgt diff --git a/test/iscsi_tgt/calsoft/iscsi.conf b/test/iscsi_tgt/calsoft/iscsi.conf index 892ff9bbe..d03da872c 100644 --- a/test/iscsi_tgt/calsoft/iscsi.conf +++ b/test/iscsi_tgt/calsoft/iscsi.conf @@ -11,6 +11,3 @@ ErrorRecoveryLevel 2 NopInInterval 10 AllowDuplicateIsid Yes - -[Rpc] - Enable Yes diff --git a/test/iscsi_tgt/ext4test/ext4test.sh b/test/iscsi_tgt/ext4test/ext4test.sh index 7b777613e..62b76cd15 100755 --- a/test/iscsi_tgt/ext4test/ext4test.sh +++ b/test/iscsi_tgt/ext4test/ext4test.sh @@ -16,7 +16,6 @@ $rootdir/scripts/gen_nvme.sh >> $testdir/iscsi.conf # iSCSI target configuration PORT=3260 -RPC_PORT=5260 INITIATOR_TAG=2 INITIATOR_NAME=ALL NETMASK=$INITIATOR_IP/32 @@ -31,7 +30,7 @@ echo "Process pid: $pid" trap "killprocess $pid; exit 1" SIGINT SIGTERM EXIT -waitforlisten $pid ${RPC_PORT} +waitforlisten $pid echo "iscsi_tgt is listening. Running tests..." timing_exit start_iscsi_tgt diff --git a/test/iscsi_tgt/ext4test/iscsi.conf.in b/test/iscsi_tgt/ext4test/iscsi.conf.in index bb7219b65..8576cf3ce 100644 --- a/test/iscsi_tgt/ext4test/iscsi.conf.in +++ b/test/iscsi_tgt/ext4test/iscsi.conf.in @@ -10,9 +10,6 @@ ImmediateData Yes ErrorRecoveryLevel 0 -[Rpc] - Enable Yes - # Do not specify InitiatorGroup, PortalGroup, Malloc, # or TargetNode entries here - the autotest.sh script # will use RPC to set up this part of the configuration. diff --git a/test/iscsi_tgt/filesystem/filesystem.sh b/test/iscsi_tgt/filesystem/filesystem.sh index df45f35ae..419107d5f 100755 --- a/test/iscsi_tgt/filesystem/filesystem.sh +++ b/test/iscsi_tgt/filesystem/filesystem.sh @@ -9,7 +9,6 @@ timing_enter filesystem # iSCSI target configuration PORT=3260 -RPC_PORT=5260 INITIATOR_TAG=2 INITIATOR_NAME=ALL NETMASK=$INITIATOR_IP/32 @@ -26,7 +25,7 @@ echo "Process pid: $pid" trap "killprocess $pid; exit 1" SIGINT SIGTERM EXIT -waitforlisten $pid ${RPC_PORT} +waitforlisten $pid echo "iscsi_tgt is listening. Running tests..." timing_exit start_iscsi_tgt diff --git a/test/iscsi_tgt/filesystem/iscsi.conf b/test/iscsi_tgt/filesystem/iscsi.conf index fde6fbf6c..432768819 100644 --- a/test/iscsi_tgt/filesystem/iscsi.conf +++ b/test/iscsi_tgt/filesystem/iscsi.conf @@ -8,6 +8,3 @@ MaxSessions 16 ImmediateData Yes ErrorRecoveryLevel 0 - -[Rpc] - Enable Yes diff --git a/test/iscsi_tgt/fio/fio.sh b/test/iscsi_tgt/fio/fio.sh index ea1e0f1ca..486a5bd7d 100755 --- a/test/iscsi_tgt/fio/fio.sh +++ b/test/iscsi_tgt/fio/fio.sh @@ -34,7 +34,7 @@ function running_config() { pid=$! echo "Process pid: $pid" trap "iscsicleanup; killprocess $pid; exit 1" SIGINT SIGTERM EXIT - waitforlisten $pid ${RPC_PORT} + waitforlisten $pid echo "iscsi_tgt is listening. Running tests..." timing_exit start_iscsi_tgt2 @@ -59,7 +59,6 @@ cp $testdir/iscsi.conf.in $testdir/iscsi.conf # iSCSI target configuration PORT=3260 -RPC_PORT=5260 INITIATOR_TAG=2 INITIATOR_NAME=ALL NETMASK=$INITIATOR_IP/32 @@ -77,7 +76,7 @@ echo "Process pid: $pid" trap "killprocess $pid; exit 1" SIGINT SIGTERM EXIT -waitforlisten $pid ${RPC_PORT} +waitforlisten $pid echo "iscsi_tgt is listening. Running tests..." timing_exit start_iscsi_tgt diff --git a/test/iscsi_tgt/fio/iscsi.conf.in b/test/iscsi_tgt/fio/iscsi.conf.in index 25b1aad11..c6c0cac96 100644 --- a/test/iscsi_tgt/fio/iscsi.conf.in +++ b/test/iscsi_tgt/fio/iscsi.conf.in @@ -9,9 +9,6 @@ ImmediateData Yes ErrorRecoveryLevel 0 -[Rpc] - Enable Yes - [Nvme] RetryCount 4 Timeout 0 diff --git a/test/iscsi_tgt/idle_migration/idle_migration.sh b/test/iscsi_tgt/idle_migration/idle_migration.sh index 722a92c93..5f57b2393 100755 --- a/test/iscsi_tgt/idle_migration/idle_migration.sh +++ b/test/iscsi_tgt/idle_migration/idle_migration.sh @@ -9,7 +9,6 @@ timing_enter idle_migration # iSCSI target configuration PORT=3260 -RPC_PORT=5260 fio_py="python $rootdir/scripts/fio.py" @@ -21,7 +20,7 @@ echo "Process pid: $pid" trap "killprocess $pid; exit 1" SIGINT SIGTERM EXIT -waitforlisten $pid ${RPC_PORT} +waitforlisten $pid echo "iscsi_tgt is listening. Running tests..." timing_exit start_iscsi_tgt diff --git a/test/iscsi_tgt/idle_migration/iscsi.conf b/test/iscsi_tgt/idle_migration/iscsi.conf index eae370033..0546b93a7 100644 --- a/test/iscsi_tgt/idle_migration/iscsi.conf +++ b/test/iscsi_tgt/idle_migration/iscsi.conf @@ -8,5 +8,3 @@ MaxSessions 64 ImmediateData Yes ErrorRecoveryLevel 0 -[Rpc] - Enable Yes diff --git a/test/iscsi_tgt/ip_migration/ip_migration.sh b/test/iscsi_tgt/ip_migration/ip_migration.sh index 5ef348be5..a314bd27d 100755 --- a/test/iscsi_tgt/ip_migration/ip_migration.sh +++ b/test/iscsi_tgt/ip_migration/ip_migration.sh @@ -51,7 +51,7 @@ do trap "kill_all_iscsi_target; exit 1" SIGINT SIGTERM EXIT - waitforlisten $pid $port + waitforlisten_tcp $pid $port echo "iscsi_tgt is listening. Running tests..." timing_exit start_iscsi_tgt_$i diff --git a/test/iscsi_tgt/ip_migration/iscsi.conf b/test/iscsi_tgt/ip_migration/iscsi.conf index 440b4db80..8f62be052 100644 --- a/test/iscsi_tgt/ip_migration/iscsi.conf +++ b/test/iscsi_tgt/ip_migration/iscsi.conf @@ -11,4 +11,3 @@ # The RPC section must be the last section in this file. [Rpc] - Enable Yes diff --git a/test/iscsi_tgt/lvol/iscsi.conf b/test/iscsi_tgt/lvol/iscsi.conf index fde6fbf6c..432768819 100644 --- a/test/iscsi_tgt/lvol/iscsi.conf +++ b/test/iscsi_tgt/lvol/iscsi.conf @@ -8,6 +8,3 @@ MaxSessions 16 ImmediateData Yes ErrorRecoveryLevel 0 - -[Rpc] - Enable Yes diff --git a/test/iscsi_tgt/lvol/iscsi_lvol.sh b/test/iscsi_tgt/lvol/iscsi_lvol.sh index c0834aad6..a0225f05f 100755 --- a/test/iscsi_tgt/lvol/iscsi_lvol.sh +++ b/test/iscsi_tgt/lvol/iscsi_lvol.sh @@ -12,7 +12,6 @@ timing_enter iscsi_lvol # iSCSI target configuration PORT=3260 -RPC_PORT=5260 INITIATOR_TAG=2 INITIATOR_NAME=ALL NETMASK=$INITIATOR_IP/32 @@ -30,7 +29,7 @@ echo "Process pid: $pid" trap "iscsicleanup; killprocess $pid; exit 1" SIGINT SIGTERM EXIT -waitforlisten $pid ${RPC_PORT} +waitforlisten $pid echo "iscsi_tgt is listening. Running tests..." timing_exit start_iscsi_tgt diff --git a/test/iscsi_tgt/nvme_remote/fio_remote_nvme.sh b/test/iscsi_tgt/nvme_remote/fio_remote_nvme.sh index 081230cd2..49b0313fa 100755 --- a/test/iscsi_tgt/nvme_remote/fio_remote_nvme.sh +++ b/test/iscsi_tgt/nvme_remote/fio_remote_nvme.sh @@ -28,7 +28,7 @@ $rootdir/app/nvmf_tgt/nvmf_tgt -c $rootdir/test/nvmf/nvmf.conf -m 0x2 -p 1 -s 38 nvmfpid=$! echo "NVMf target launched. pid: $nvmfpid" trap "killprocess $nvmfpid; exit 1" SIGINT SIGTERM EXIT -waitforlisten $nvmfpid 5260 +waitforlisten $nvmfpid echo "NVMf target has started." bdevs=$($rpc_py construct_malloc_bdev 64 512) $rpc_py construct_nvmf_subsystem nqn.2016-06.io.spdk:cnode1 "trtype:RDMA traddr:$NVMF_FIRST_TARGET_IP trsvcid:4420" "" -a -s SPDK00000000000001 -n "$bdevs" @@ -48,18 +48,18 @@ iscsipid=$! echo "iSCSI target launched. pid: $iscsipid" trap "killprocess $iscsipid; killprocess $nvmfpid; exit 1" SIGINT SIGTERM EXIT # The configuration file for the iSCSI target told it to use port 5261 for RPC -waitforlisten $iscsipid 5261 +waitforlisten_tcp $iscsipid 5261 echo "iSCSI target has started." timing_exit start_iscsi_tgt echo "Creating an iSCSI target node." -$rpc_py -p 5261 add_portal_group 1 $TARGET_IP:$ISCSI_PORT -$rpc_py -p 5261 add_initiator_group 1 ALL $INITIATOR_IP/32 +$rpc_py -s 127.0.0.1 -p 5261 add_portal_group 1 $TARGET_IP:$ISCSI_PORT +$rpc_py -s 127.0.0.1 -p 5261 add_initiator_group 1 ALL $INITIATOR_IP/32 if [ $1 -eq 0 ]; then - $rpc_py -p 5261 construct_nvme_bdev -b "Nvme0" -t "rdma" -f "ipv4" -a $NVMF_FIRST_TARGET_IP -s $NVMF_PORT -n nqn.2016-06.io.spdk:cnode1 + $rpc_py -s 127.0.0.1 -p 5261 construct_nvme_bdev -b "Nvme0" -t "rdma" -f "ipv4" -a $NVMF_FIRST_TARGET_IP -s $NVMF_PORT -n nqn.2016-06.io.spdk:cnode1 fi -$rpc_py -p 5261 construct_target_node Target1 Target1_alias 'Nvme0n1:0' '1:1' 64 1 0 0 0 +$rpc_py -s 127.0.0.1 -p 5261 construct_target_node Target1 Target1_alias 'Nvme0n1:0' '1:1' 64 1 0 0 0 sleep 1 echo "Logging in to iSCSI target." diff --git a/test/iscsi_tgt/pmem/iscsi.conf b/test/iscsi_tgt/pmem/iscsi.conf index fde6fbf6c..432768819 100644 --- a/test/iscsi_tgt/pmem/iscsi.conf +++ b/test/iscsi_tgt/pmem/iscsi.conf @@ -8,6 +8,3 @@ MaxSessions 16 ImmediateData Yes ErrorRecoveryLevel 0 - -[Rpc] - Enable Yes diff --git a/test/iscsi_tgt/pmem/iscsi_pmem.sh b/test/iscsi_tgt/pmem/iscsi_pmem.sh index 16045dde0..abae95095 100755 --- a/test/iscsi_tgt/pmem/iscsi_pmem.sh +++ b/test/iscsi_tgt/pmem/iscsi_pmem.sh @@ -13,7 +13,6 @@ BLOCKSIZE=$1 RUNTIME=$2 PMEM_BDEVS="" PORT=3260 -RPC_PORT=5260 INITIATOR_TAG=2 INITIATOR_NAME=ALL NETMASK=$INITIATOR_IP/32 @@ -33,7 +32,7 @@ echo "Process pid: $pid" trap "iscsicleanup; killprocess $pid; rm -f /tmp/pool_file*; exit 1" SIGINT SIGTERM EXIT -waitforlisten $pid ${RPC_PORT} +waitforlisten $pid echo "iscsi_tgt is listening. Running tests..." timing_exit start_iscsi_target diff --git a/test/iscsi_tgt/rbd/iscsi.conf b/test/iscsi_tgt/rbd/iscsi.conf index fde6fbf6c..432768819 100644 --- a/test/iscsi_tgt/rbd/iscsi.conf +++ b/test/iscsi_tgt/rbd/iscsi.conf @@ -8,6 +8,3 @@ MaxSessions 16 ImmediateData Yes ErrorRecoveryLevel 0 - -[Rpc] - Enable Yes diff --git a/test/iscsi_tgt/rbd/rbd.sh b/test/iscsi_tgt/rbd/rbd.sh index 66617b079..1ea42df51 100755 --- a/test/iscsi_tgt/rbd/rbd.sh +++ b/test/iscsi_tgt/rbd/rbd.sh @@ -14,7 +14,6 @@ timing_enter rbd # iSCSI target configuration PORT=3260 -RPC_PORT=5260 INITIATOR_TAG=2 INITIATOR_NAME=ALL NETMASK=$INITIATOR_IP/32 @@ -29,7 +28,7 @@ pid=$! trap "killprocess $pid; exit 1" SIGINT SIGTERM EXIT -waitforlisten $pid ${RPC_PORT} +waitforlisten $pid echo "iscsi_tgt is listening. Running tests..." timing_exit start_iscsi_tgt diff --git a/test/iscsi_tgt/reset/iscsi.conf b/test/iscsi_tgt/reset/iscsi.conf index fde6fbf6c..432768819 100644 --- a/test/iscsi_tgt/reset/iscsi.conf +++ b/test/iscsi_tgt/reset/iscsi.conf @@ -8,6 +8,3 @@ MaxSessions 16 ImmediateData Yes ErrorRecoveryLevel 0 - -[Rpc] - Enable Yes diff --git a/test/iscsi_tgt/reset/reset.sh b/test/iscsi_tgt/reset/reset.sh index 35b5bb614..b53cfa59e 100755 --- a/test/iscsi_tgt/reset/reset.sh +++ b/test/iscsi_tgt/reset/reset.sh @@ -11,7 +11,6 @@ timing_enter reset # iSCSI target configuration PORT=3260 -RPC_PORT=5260 INITIATOR_TAG=2 INITIATOR_NAME=ALL NETMASK=$INITIATOR_IP/32 @@ -33,7 +32,7 @@ echo "Process pid: $pid" trap "killprocess $pid; exit 1" SIGINT SIGTERM EXIT -waitforlisten $pid ${RPC_PORT} +waitforlisten $pid echo "iscsi_tgt is listening. Running tests..." timing_exit start_iscsi_tgt diff --git a/test/iscsi_tgt/rpc_config/iscsi.conf b/test/iscsi_tgt/rpc_config/iscsi.conf index fde6fbf6c..432768819 100644 --- a/test/iscsi_tgt/rpc_config/iscsi.conf +++ b/test/iscsi_tgt/rpc_config/iscsi.conf @@ -8,6 +8,3 @@ MaxSessions 16 ImmediateData Yes ErrorRecoveryLevel 0 - -[Rpc] - Enable Yes diff --git a/test/iscsi_tgt/rpc_config/rpc_config.sh b/test/iscsi_tgt/rpc_config/rpc_config.sh index ec467e8e1..80c98dd3d 100755 --- a/test/iscsi_tgt/rpc_config/rpc_config.sh +++ b/test/iscsi_tgt/rpc_config/rpc_config.sh @@ -9,7 +9,6 @@ timing_enter rpc_config # iSCSI target configuration PORT=3260 -RPC_PORT=5260 INITIATOR_TAG=2 INITIATOR_NAME=ALL NETMASK=$INITIATOR_IP/32 @@ -27,7 +26,7 @@ echo "Process pid: $pid" trap "killprocess $pid; exit 1" SIGINT SIGTERM EXIT -waitforlisten $pid ${RPC_PORT} +waitforlisten $pid echo "iscsi_tgt is listening. Running tests..." timing_exit start_iscsi_tgt diff --git a/test/lib/bdev/bdev.conf.in b/test/lib/bdev/bdev.conf.in index 2e900418b..17cdeedad 100644 --- a/test/lib/bdev/bdev.conf.in +++ b/test/lib/bdev/bdev.conf.in @@ -14,8 +14,5 @@ AIO /dev/ram0 AIO0 AIO /tmp/aiofile AIO1 2048 -[Rpc] - Enable Yes - [Ioat] Disable Yes diff --git a/test/lib/bdev/bdevio/bdevio.c b/test/lib/bdev/bdevio/bdevio.c index f657820fc..79d96016d 100644 --- a/test/lib/bdev/bdevio/bdevio.c +++ b/test/lib/bdev/bdevio/bdevio.c @@ -950,6 +950,7 @@ main(int argc, char **argv) config_file = argv[1]; } bdevtest_init(config_file, "0x7", &opts); + opts.rpc_addr = NULL; num_failures = spdk_app_start(&opts, start_timer, NULL, NULL); spdk_app_fini(); diff --git a/test/lib/bdev/bdevperf/bdevperf.c b/test/lib/bdev/bdevperf/bdevperf.c index e7301be8e..b55da3656 100644 --- a/test/lib/bdev/bdevperf/bdevperf.c +++ b/test/lib/bdev/bdevperf/bdevperf.c @@ -757,6 +757,7 @@ main(int argc, char **argv) } bdevtest_init(config_file, core_mask, &opts); + opts.rpc_addr = NULL; spdk_app_start(&opts, bdevperf_run, NULL, NULL); diff --git a/test/lvol/lvol.sh b/test/lvol/lvol.sh index ab5d3d1c3..1972acb2d 100755 --- a/test/lvol/lvol.sh +++ b/test/lvol/lvol.sh @@ -10,7 +10,6 @@ test_cases=all x="" rpc_py="$TEST_DIR/scripts/rpc.py " -RPC_PORT=5260 function usage() { [[ ! -z $2 ]] && ( echo "$2"; echo ""; ) @@ -82,7 +81,7 @@ function vhost_start() $TEST_DIR/app/vhost/vhost -c $BASE_DIR/vhost.conf.in & vhost_pid=$! echo $vhost_pid > $BASE_DIR/vhost.pid - waitforlisten $vhost_pid $RPC_PORT + waitforlisten $vhost_pid } ### Function stops vhost app diff --git a/test/lvol/vhost.conf.in b/test/lvol/vhost.conf.in index d7664685b..622d0d717 100755 --- a/test/lvol/vhost.conf.in +++ b/test/lvol/vhost.conf.in @@ -1,5 +1,2 @@ [Global] LogFacility "local7" -[Rpc] - Enable Yes - Listen 127.0.0.1 diff --git a/test/nvmf/common.sh b/test/nvmf/common.sh index 94a48a267..51566403c 100755 --- a/test/nvmf/common.sh +++ b/test/nvmf/common.sh @@ -3,7 +3,6 @@ NVMF_PORT=4420 NVMF_IP_PREFIX="192.168.100" NVMF_IP_LEAST_ADDR=8 -RPC_PORT=5260 if [ -z "$NVMF_APP" ]; then NVMF_APP=./app/nvmf_tgt/nvmf_tgt diff --git a/test/nvmf/discovery/discovery.sh b/test/nvmf/discovery/discovery.sh index 3e175f42b..23e6e0b0e 100755 --- a/test/nvmf/discovery/discovery.sh +++ b/test/nvmf/discovery/discovery.sh @@ -32,7 +32,7 @@ nvmfpid=$! trap "killprocess $nvmfpid; exit 1" SIGINT SIGTERM EXIT -waitforlisten $nvmfpid ${RPC_PORT} +waitforlisten $nvmfpid timing_exit start_nvmf_tgt bdevs="$bdevs $($rpc_py construct_null_bdev Null0 $NULL_BDEV_SIZE $NULL_BLOCK_SIZE)" diff --git a/test/nvmf/filesystem/filesystem.sh b/test/nvmf/filesystem/filesystem.sh index b1b8665f2..0096e42da 100755 --- a/test/nvmf/filesystem/filesystem.sh +++ b/test/nvmf/filesystem/filesystem.sh @@ -27,7 +27,7 @@ nvmfpid=$! trap "killprocess $nvmfpid; exit 1" SIGINT SIGTERM EXIT -waitforlisten $nvmfpid ${RPC_PORT} +waitforlisten $nvmfpid timing_exit start_nvmf_tgt bdevs="$bdevs $($rpc_py construct_malloc_bdev $MALLOC_BDEV_SIZE $MALLOC_BLOCK_SIZE)" diff --git a/test/nvmf/fio/fio.sh b/test/nvmf/fio/fio.sh index 3d23d5324..245ec6d12 100755 --- a/test/nvmf/fio/fio.sh +++ b/test/nvmf/fio/fio.sh @@ -27,7 +27,7 @@ nvmfpid=$! trap "killprocess $nvmfpid; exit 1" SIGINT SIGTERM EXIT -waitforlisten $nvmfpid ${RPC_PORT} +waitforlisten $nvmfpid timing_exit start_nvmf_tgt bdevs="$bdevs $($rpc_py construct_malloc_bdev $MALLOC_BDEV_SIZE $MALLOC_BLOCK_SIZE)" diff --git a/test/nvmf/host/aer.sh b/test/nvmf/host/aer.sh index 19940e3ad..b841f4190 100755 --- a/test/nvmf/host/aer.sh +++ b/test/nvmf/host/aer.sh @@ -24,7 +24,7 @@ nvmfpid=$! trap "killprocess $nvmfpid; exit 1" SIGINT SIGTERM EXIT -waitforlisten $nvmfpid ${RPC_PORT} +waitforlisten $nvmfpid timing_exit start_nvmf_tgt bdevs="$bdevs $($rpc_py construct_malloc_bdev 64 512)" diff --git a/test/nvmf/host/bdevperf.sh b/test/nvmf/host/bdevperf.sh index d2c6603af..41bd78a18 100755 --- a/test/nvmf/host/bdevperf.sh +++ b/test/nvmf/host/bdevperf.sh @@ -27,7 +27,7 @@ nvmfpid=$! trap "killprocess $nvmfpid; exit 1" SIGINT SIGTERM EXIT -waitforlisten $nvmfpid ${RPC_PORT} +waitforlisten $nvmfpid timing_exit start_nvmf_tgt bdevs="$bdevs $($rpc_py construct_malloc_bdev $MALLOC_BDEV_SIZE $MALLOC_BLOCK_SIZE)" diff --git a/test/nvmf/host/fio.sh b/test/nvmf/host/fio.sh index 7deaa1370..ce3728f8a 100755 --- a/test/nvmf/host/fio.sh +++ b/test/nvmf/host/fio.sh @@ -29,7 +29,7 @@ nvmfpid=$! trap "killprocess $nvmfpid; exit 1" SIGINT SIGTERM EXIT -waitforlisten $nvmfpid ${RPC_PORT} +waitforlisten $nvmfpid timing_exit start_nvmf_tgt bdevs="$bdevs $($rpc_py construct_malloc_bdev 64 512)" diff --git a/test/nvmf/host/identify.sh b/test/nvmf/host/identify.sh index e459053e1..0172154df 100755 --- a/test/nvmf/host/identify.sh +++ b/test/nvmf/host/identify.sh @@ -26,7 +26,7 @@ nvmfpid=$! trap "killprocess $nvmfpid; exit 1" SIGINT SIGTERM EXIT -waitforlisten $nvmfpid ${RPC_PORT} +waitforlisten $nvmfpid timing_exit start_nvmf_tgt bdevs="$bdevs $($rpc_py construct_malloc_bdev $MALLOC_BDEV_SIZE $MALLOC_BLOCK_SIZE)" diff --git a/test/nvmf/host/perf.sh b/test/nvmf/host/perf.sh index 8bf091979..e17bfd3c2 100755 --- a/test/nvmf/host/perf.sh +++ b/test/nvmf/host/perf.sh @@ -32,7 +32,7 @@ nvmfpid=$! trap "killprocess $nvmfpid; exit 1" SIGINT SIGTERM EXIT -waitforlisten $nvmfpid ${RPC_PORT} +waitforlisten $nvmfpid timing_exit start_nvmf_tgt bdevs="$bdevs $($rpc_py construct_malloc_bdev $MALLOC_BDEV_SIZE $MALLOC_BLOCK_SIZE)" diff --git a/test/nvmf/lvol/nvmf_lvol.sh b/test/nvmf/lvol/nvmf_lvol.sh index 643af60dd..77da6acbd 100755 --- a/test/nvmf/lvol/nvmf_lvol.sh +++ b/test/nvmf/lvol/nvmf_lvol.sh @@ -36,7 +36,7 @@ pid=$! trap "disconnect_nvmf; killprocess $pid; exit 1" SIGINT SIGTERM EXIT -waitforlisten $pid ${RPC_PORT} +waitforlisten $pid timing_exit start_nvmf_tgt modprobe -v nvme-rdma diff --git a/test/nvmf/multiconnection/multiconnection.sh b/test/nvmf/multiconnection/multiconnection.sh index 6a194321a..e574cd267 100755 --- a/test/nvmf/multiconnection/multiconnection.sh +++ b/test/nvmf/multiconnection/multiconnection.sh @@ -27,7 +27,7 @@ pid=$! trap "killprocess $pid; exit 1" SIGINT SIGTERM EXIT -waitforlisten $pid ${RPC_PORT} +waitforlisten $pid timing_exit start_nvmf_tgt modprobe -v nvme-rdma diff --git a/test/nvmf/nvme_cli/nvme_cli.sh b/test/nvmf/nvme_cli/nvme_cli.sh index 434fcd9e5..1ed3a58bc 100755 --- a/test/nvmf/nvme_cli/nvme_cli.sh +++ b/test/nvmf/nvme_cli/nvme_cli.sh @@ -26,7 +26,7 @@ nvmfpid=$! trap "killprocess $nvmfpid; exit 1" SIGINT SIGTERM EXIT -waitforlisten $nvmfpid ${RPC_PORT} +waitforlisten $nvmfpid timing_exit start_nvmf_tgt bdevs="$bdevs $($rpc_py construct_malloc_bdev $MALLOC_BDEV_SIZE $MALLOC_BLOCK_SIZE)" diff --git a/test/nvmf/nvmf.conf b/test/nvmf/nvmf.conf index 1f36711f6..bf19eefda 100644 --- a/test/nvmf/nvmf.conf +++ b/test/nvmf/nvmf.conf @@ -1,8 +1,5 @@ [Global] Comment "Global section" -[Rpc] - Enable Yes - [Nvmf] MaxQueuesPerSession 4 diff --git a/test/nvmf/pmem/nvmf.conf b/test/nvmf/pmem/nvmf.conf index b26bedd1f..169e6a91f 100644 --- a/test/nvmf/pmem/nvmf.conf +++ b/test/nvmf/pmem/nvmf.conf @@ -1,8 +1,5 @@ [Global] Comment "Global section" -[Rpc] - Enable Yes - [Nvmf] MaxQueuesPerSession 16 diff --git a/test/nvmf/pmem/nvmf_pmem.sh b/test/nvmf/pmem/nvmf_pmem.sh index 3e0d43bb5..160510d29 100755 --- a/test/nvmf/pmem/nvmf_pmem.sh +++ b/test/nvmf/pmem/nvmf_pmem.sh @@ -49,7 +49,7 @@ pid=$! trap "disconnect_nvmf; rm -f /tmp/pool_file*; killprocess $pid; exit 1" SIGINT SIGTERM EXIT -waitforlisten $pid ${RPC_PORT} +waitforlisten $pid timing_exit start_nvmf_tgt modprobe -v nvme-rdma diff --git a/test/nvmf/rpc/rpc.sh b/test/nvmf/rpc/rpc.sh index 9b62ee295..f50894ec4 100755 --- a/test/nvmf/rpc/rpc.sh +++ b/test/nvmf/rpc/rpc.sh @@ -24,7 +24,7 @@ pid=$! trap "killprocess $pid; exit 1" SIGINT SIGTERM EXIT -waitforlisten $pid ${RPC_PORT} +waitforlisten $pid timing_exit start_nvmf_tgt # set times for subsystem construct/delete diff --git a/test/nvmf/shutdown/shutdown.sh b/test/nvmf/shutdown/shutdown.sh index aef53b166..3550447d8 100755 --- a/test/nvmf/shutdown/shutdown.sh +++ b/test/nvmf/shutdown/shutdown.sh @@ -27,7 +27,7 @@ pid=$! trap "killprocess $pid; exit 1" SIGINT SIGTERM EXIT -waitforlisten $pid ${RPC_PORT} +waitforlisten $pid timing_exit start_nvmf_tgt # Create 10 subsystems diff --git a/test/pmem/common.sh b/test/pmem/common.sh index dd8d024e6..5329100f7 100644 --- a/test/pmem/common.sh +++ b/test/pmem/common.sh @@ -3,7 +3,6 @@ BASE_DIR=$(readlink -f $(dirname $0)) [[ -z "$TEST_DIR" ]] && TEST_DIR="$(cd $BASE_DIR/../../ && pwd)" rpc_py="$TEST_DIR/scripts/rpc.py " -RPC_PORT=5260 source $TEST_DIR/scripts/autotest_common.sh @@ -76,10 +75,9 @@ function pmem_print_tc_name function vhost_start() { - local vhost_conf_template="$TEST_DIR/test/pmem/vhost.conf.in" local vhost_pid - $TEST_DIR/app/vhost/vhost -c $vhost_conf_template & + $TEST_DIR/app/vhost/vhost & if [ $? != 0 ]; then echo -e "ERROR: Failed to launch vhost!" return 1 @@ -87,7 +85,7 @@ function vhost_start() vhost_pid=$! echo $vhost_pid > $TEST_DIR/test/pmem/vhost.pid - waitforlisten $vhost_pid $RPC_PORT + waitforlisten $vhost_pid } function vhost_kill() diff --git a/test/pmem/vhost.conf.in b/test/pmem/vhost.conf.in deleted file mode 100644 index 9a11019bd..000000000 --- a/test/pmem/vhost.conf.in +++ /dev/null @@ -1,3 +0,0 @@ -[Rpc] - Enable Yes - Listen 127.0.0.1 diff --git a/test/vhost/common/common.sh b/test/vhost/common/common.sh index 28b5249fc..79499a0b8 100644 --- a/test/vhost/common/common.sh +++ b/test/vhost/common/common.sh @@ -41,8 +41,6 @@ mkdir -p $TEST_DIR . $COMMON_DIR/autotest.config -RPC_PORT=5260 - # Trace flag is optional, if it wasn't set earlier - disable it after sourcing # autotest_common.sh if [[ $- =~ x ]]; then @@ -162,7 +160,7 @@ function spdk_vhost_run() echo $vhost_pid > $vhost_pid_file echo "INFO: waiting for app to run..." - waitforlisten "$vhost_pid" ${RPC_PORT} + waitforlisten "$vhost_pid" echo "INFO: vhost started - pid=$vhost_pid" rm $vhost_conf_file diff --git a/test/vhost/fiotest/autotest.sh b/test/vhost/fiotest/autotest.sh index b99b4c535..f7dac7b50 100755 --- a/test/vhost/fiotest/autotest.sh +++ b/test/vhost/fiotest/autotest.sh @@ -132,7 +132,6 @@ echo "Setting up VM" echo "" rpc_py="python $SPDK_BUILD_DIR/scripts/rpc.py " -rpc_py+="-s 127.0.0.1 " for vm_conf in ${vms[@]}; do IFS=',' read -ra conf <<< "$vm_conf" diff --git a/test/vhost/fiotest/vhost.conf.in b/test/vhost/fiotest/vhost.conf.in index c54c75a04..151cb3bcd 100644 --- a/test/vhost/fiotest/vhost.conf.in +++ b/test/vhost/fiotest/vhost.conf.in @@ -1,8 +1,5 @@ [Global] -[Rpc] - Enable Yes - [Ioat] Disable Yes diff --git a/test/vhost/hotplug/vhost.conf.base b/test/vhost/hotplug/vhost.conf.base index f6e53f7de..5fab30fd7 100644 --- a/test/vhost/hotplug/vhost.conf.base +++ b/test/vhost/hotplug/vhost.conf.base @@ -1,7 +1,4 @@ [Global] -[Rpc] - Enable Yes - [Ioat] Disable Yes diff --git a/test/vhost/initiator/vhost.conf.in b/test/vhost/initiator/vhost.conf.in index 02fd34c0e..50b5ff0ff 100644 --- a/test/vhost/initiator/vhost.conf.in +++ b/test/vhost/initiator/vhost.conf.in @@ -1,6 +1,3 @@ -[Rpc] - Enable Yes - [Ioat] Disable Yes diff --git a/test/vhost/integrity/integrity_start.sh b/test/vhost/integrity/integrity_start.sh index 6e9974c54..150125e32 100755 --- a/test/vhost/integrity/integrity_start.sh +++ b/test/vhost/integrity/integrity_start.sh @@ -9,8 +9,6 @@ qemu_install_dir="$testdir/root" MAKE="make -j$(( $(nproc) * 2 ))" rpc_py="python $rootdir/scripts/rpc.py " -rpc_py+="-s 127.0.0.1 " -RPC_PORT=5260 HOST_IP=192.200.200.1 VM_IP=192.200.200.254 VM_UNAME="root" @@ -113,7 +111,7 @@ cd /tmp $rootdir/app/vhost/vhost -c $basedir/vhost.conf & pid=$! echo "Process pid: $pid" -waitforlisten "$pid" "$RPC_PORT" +waitforlisten "$pid" if [[ "$VHOST_MODE" == "scsi" ]]; then $rpc_py construct_vhost_scsi_controller naa.0 $rpc_py add_vhost_scsi_lun naa.0 0 Nvme0n1 diff --git a/test/vhost/integrity/vhost.conf.in b/test/vhost/integrity/vhost.conf.in index f6e53f7de..5fab30fd7 100644 --- a/test/vhost/integrity/vhost.conf.in +++ b/test/vhost/integrity/vhost.conf.in @@ -1,7 +1,4 @@ [Global] -[Rpc] - Enable Yes - [Ioat] Disable Yes diff --git a/test/vhost/lvol/lvol_test.sh b/test/vhost/lvol/lvol_test.sh index ea8f1ccd0..72ca2e983 100755 --- a/test/vhost/lvol/lvol_test.sh +++ b/test/vhost/lvol/lvol_test.sh @@ -7,7 +7,6 @@ BASE_DIR=$(readlink -f $(dirname $0)) . $COMMON_DIR/common.sh rpc_py="python $SPDK_BUILD_DIR/scripts/rpc.py " -rpc_py+="-s 127.0.0.1 " vm_count=1 max_disks="" diff --git a/test/vhost/lvol/vhost.conf.in b/test/vhost/lvol/vhost.conf.in index 2b79dc16a..8e3501847 100644 --- a/test/vhost/lvol/vhost.conf.in +++ b/test/vhost/lvol/vhost.conf.in @@ -1,5 +1,3 @@ [Global] -[Rpc] - Enable Yes [Ioat] Disable Yes