rpc: add default UNIX domain socket listen address

RPC is a default feature required for almost all usages,
so enable RPC by default, but with a UNIX domain socket
for security reasons.

-r can now be used from the command line to specify
an alternative RPC listen address from the default
/var/tmp/spdk.sock.

Remove the Enable parameter from the Rpc config section
but still allow specifying an alternative listen address
using the Listen parameter as an alternative to the
command line option.  This keeps backward compatibility
for this release for anyone using the configuration file
still.

Remove the Rpc sections from all configuration files
that were using them, except for those that specified
alternate TCP ports for multi-process test cases.  We
can fix these later to use an alternate UNIX domain
socket and to use the command line instead.

Signed-off-by: Jim Harris <james.r.harris@intel.com>
Change-Id: Ife0d03fcab638c67b659f1eb85348ddc2b55c4c4
Reviewed-on: https://review.gerrithub.io/386561
Reviewed-by: Daniel Verkamp <daniel.verkamp@intel.com>
Tested-by: SPDK Automated Test System <sys_sgsw@intel.com>
Reviewed-by: Ben Walker <benjamin.walker@intel.com>
This commit is contained in:
Jim Harris 2017-11-09 16:33:29 -07:00 committed by Daniel Verkamp
parent fbb9430ec4
commit 6bef902ca5
71 changed files with 104 additions and 199 deletions

View File

@ -1,5 +1,14 @@
# Changelog # 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 ## v17.10: Logical Volumes
### New dependencies ### New dependencies

View File

@ -42,6 +42,8 @@ fi
# Make sure the disks are clean (no leftover partition tables) # Make sure the disks are clean (no leftover partition tables)
timing_enter cleanup timing_enter cleanup
# Remove old domain socket pathname just in case
rm -f $DEFAULT_RPC_ADDR
if [ $(uname -s) = Linux ]; then if [ $(uname -s) = Linux ]; then
# Load the kernel driver # Load the kernel driver
./scripts/setup.sh reset ./scripts/setup.sh reset

View File

@ -62,16 +62,6 @@
ImmediateData Yes ImmediateData Yes
ErrorRecoveryLevel 0 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 # Users must change the PortalGroup section(s) to match the IP addresses
# for their environment. # for their environment.
# PortalGroup sections define which TCP ports the iSCSI server will use # PortalGroup sections define which TCP ports the iSCSI server will use

View File

@ -20,16 +20,6 @@
# Set to 0xFFFFFFFFFFFFFFFF to enable all tracepoint groups. # Set to 0xFFFFFFFFFFFFFFFF to enable all tracepoint groups.
#TpointGroupMask 0x0 #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 # Users may change this section to create a different number or size of
# malloc LUNs. # malloc LUNs.
# This will generate 8 LUNs with a malloc-allocated backend. # This will generate 8 LUNs with a malloc-allocated backend.

View File

@ -16,13 +16,6 @@
# on all cores. # on all cores.
#ReactorMask 0x1 #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] [Ioat]
Disable Yes Disable Yes

View File

@ -29,16 +29,6 @@
# Set to 0xFFFFFFFFFFFFFFFF to enable all tracepoint groups. # Set to 0xFFFFFFFFFFFFFFFF to enable all tracepoint groups.
#TpointGroupMask 0x0 #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 not want to use offload even it is available.
# Users may use the whitelist to initialize specified devices, IDS # Users may use the whitelist to initialize specified devices, IDS
# uses BUS:DEVICE.FUNCTION to identify each Ioat channel. # uses BUS:DEVICE.FUNCTION to identify each Ioat channel.

View File

@ -63,12 +63,15 @@ struct spdk_poller;
typedef void (*spdk_app_shutdown_cb)(void); typedef void (*spdk_app_shutdown_cb)(void);
typedef void (*spdk_sighandler_t)(int); typedef void (*spdk_sighandler_t)(int);
#define SPDK_DEFAULT_RPC_ADDR "/var/tmp/spdk.sock"
/** /**
* \brief Event framework initialization options * \brief Event framework initialization options
*/ */
struct spdk_app_opts { struct spdk_app_opts {
const char *name; const char *name;
const char *config_file; 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 *reactor_mask;
const char *tpoint_group_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)); 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. * \brief Helper function for parsing arguments and printing usage messages.

View File

@ -76,7 +76,7 @@ void spdk_subsystem_init_next(int rc);
void spdk_subsystem_fini_next(void); void spdk_subsystem_fini_next(void);
void spdk_subsystem_config(FILE *fp); 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_finish(void);
void spdk_rpc_config_text(FILE *fp); void spdk_rpc_config_text(FILE *fp);

View File

@ -194,6 +194,7 @@ spdk_app_opts_init(struct spdk_app_opts *opts)
opts->reactor_mask = NULL; opts->reactor_mask = NULL;
opts->max_delay_us = 0; opts->max_delay_us = 0;
opts->print_level = SPDK_LOG_NOTICE; opts->print_level = SPDK_LOG_NOTICE;
opts->rpc_addr = SPDK_DEFAULT_RPC_ADDR;
} }
static int static int
@ -256,7 +257,9 @@ spdk_app_setup_signal_handlers(struct spdk_app_opts *opts)
static void static void
start_rpc(void *arg1, void *arg2) 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); 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_fn = start_fn;
g_app_start_arg1 = arg1; g_app_start_arg1 = arg1;
g_app_start_arg2 = arg2; 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); 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(" -n channel number of memory channels used for DPDK\n");
printf(" -p core master (primary) core for DPDK\n"); printf(" -p core master (primary) core for DPDK\n");
printf(" -q disable notice level logging to stderr\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: "); printf(" -s size memory size in MB for DPDK (default: ");
if (default_opts->mem_size > 0) { if (default_opts->mem_size > 0) {
printf("%dMB)\n", default_opts->mem_size); 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': case 'q':
opts->print_level = SPDK_LOG_WARN; opts->print_level = SPDK_LOG_WARN;
break; break;
case 'r':
opts->rpc_addr = optarg;
break;
case 's': case 's':
opts->mem_size = atoi(optarg); opts->mem_size = atoi(optarg);
break; break;

View File

@ -41,40 +41,20 @@
#include "spdk_internal/event.h" #include "spdk_internal/event.h"
#define RPC_SELECT_INTERVAL 4000 /* 4ms */ #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 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 * static const char *
rpc_get_listen_addr(void) rpc_get_listen_addr(void)
{ {
struct spdk_conf_section *sp; struct spdk_conf_section *sp;
const char *val;
sp = spdk_conf_find_section(NULL, "Rpc"); sp = spdk_conf_find_section(NULL, "Rpc");
if (sp == NULL) { if (sp == NULL) {
return RPC_DEFAULT_LISTEN_ADDR; return NULL;
} }
val = spdk_conf_section_get_val(sp, "Listen"); return spdk_conf_section_get_val(sp, "Listen");
if (val == NULL) {
val = RPC_DEFAULT_LISTEN_ADDR;
}
return val;
} }
static void static void
@ -84,18 +64,16 @@ spdk_rpc_subsystem_poll(void *arg)
} }
void void
spdk_rpc_initialize(void) spdk_rpc_initialize(const char *listen_addr)
{ {
const char *listen_addr;
int rc; int rc;
if (!enable_rpc()) { if (rpc_get_listen_addr() != NULL) {
return; listen_addr = rpc_get_listen_addr();
} }
listen_addr = rpc_get_listen_addr();
if (listen_addr == NULL) { if (listen_addr == NULL) {
listen_addr = RPC_DEFAULT_LISTEN_ADDR; return;
} }
/* Listen on the requested address */ /* Listen on the requested address */
@ -123,13 +101,7 @@ spdk_rpc_config_text(FILE *fp)
fprintf(fp, fprintf(fp,
"\n" "\n"
"[Rpc]\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" " # Listen address for the RPC service.\n"
" # May be an IP address or an absolute path to a Unix socket.\n" " # May be an IP address or an absolute path to a Unix socket.\n"
" Listen %s\n", " Listen %s\n", rpc_get_listen_addr());
enable_rpc() ? "Yes" : "No", rpc_get_listen_addr());
} }

View File

@ -76,9 +76,6 @@
"\n" \ "\n" \
" ImmediateData %s\n" \ " ImmediateData %s\n" \
" ErrorRecoveryLevel %d\n" \ " ErrorRecoveryLevel %d\n" \
"\n" \
" # Defines whether iSCSI target will enable configuration via RPC\n" \
" # RpcConfiguration Yes\n" \
"\n" "\n"
static void static void

View File

@ -93,7 +93,10 @@ spdk_rpc_listen(const char *listen_addr)
return -1; 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, g_jsonrpc_server = spdk_jsonrpc_server_listen(AF_UNIX, 0,
(struct sockaddr *)&g_rpc_listen_addr_unix, (struct sockaddr *)&g_rpc_listen_addr_unix,

View File

@ -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 # Override the default HUGEMEM in scripts/setup.sh
export HUGEMEM=8192 export HUGEMEM=8192
DEFAULT_RPC_ADDR=/var/tmp/spdk.sock
case `uname` in case `uname` in
FreeBSD) FreeBSD)
DPDK_FREEBSD_DIR=/usr/local/share/dpdk/x86_64-native-bsdapp-clang DPDK_FREEBSD_DIR=/usr/local/share/dpdk/x86_64-native-bsdapp-clang
@ -179,6 +181,29 @@ function process_core() {
} }
function waitforlisten() { 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 # $1 = process pid
# $2 = TCP port number # $2 = TCP port number
if [ -z "$1" ] || [ -z "$2" ]; then 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 & $rootdir/test/lib/bdev/nbd/nbd -c ${conf}.gpt -b $devname -n /dev/nbd0 &
nbd_pid=$! nbd_pid=$!
echo "Process nbd pid: $nbd_pid" echo "Process nbd pid: $nbd_pid"
waitforlisten $nbd_pid 5260 waitforlisten $nbd_pid
waitfornbd nbd0 waitfornbd nbd0
if [ "$operation" = create ]; then if [ "$operation" = create ]; then

View File

@ -16,8 +16,8 @@ def print_array(a):
print " ".join((quote(v) for v in a)) print " ".join((quote(v) for v in a))
parser = argparse.ArgumentParser(description='SPDK RPC command line interface') 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('-s', dest='server_addr', help='RPC server address', default='/var/tmp/spdk.sock')
parser.add_argument('-p', dest='port', help='RPC port number', default=5260, type=int) 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') parser.add_argument('-v', dest='verbose', help='Verbose mode', action='store_true')
subparsers = parser.add_subparsers(help='RPC methods') subparsers = parser.add_subparsers(help='RPC methods')

View File

@ -100,6 +100,7 @@ main(int argc, char **argv)
spdk_app_opts_init(&opts); spdk_app_opts_init(&opts);
opts.name = "stub"; opts.name = "stub";
opts.rpc_addr = NULL;
while ((ch = getopt(argc, argv, "i:m:n:p:s:H")) != -1) { while ((ch = getopt(argc, argv, "i:m:n:p:s:H")) != -1) {
switch (ch) { switch (ch) {

View File

@ -13,7 +13,6 @@ timing_enter calsoft
# iSCSI target configuration # iSCSI target configuration
PORT=3260 PORT=3260
RPC_PORT=5260
INITIATOR_TAG=2 INITIATOR_TAG=2
INITIATOR_NAME=ALL INITIATOR_NAME=ALL
NETMASK=$INITIATOR_IP/32 NETMASK=$INITIATOR_IP/32
@ -36,7 +35,7 @@ echo "Process pid: $pid"
trap "killprocess $pid; exit 1 " SIGINT SIGTERM EXIT trap "killprocess $pid; exit 1 " SIGINT SIGTERM EXIT
waitforlisten $pid ${RPC_PORT} waitforlisten $pid
echo "iscsi_tgt is listening. Running tests..." echo "iscsi_tgt is listening. Running tests..."
timing_exit start_iscsi_tgt timing_exit start_iscsi_tgt

View File

@ -11,6 +11,3 @@
ErrorRecoveryLevel 2 ErrorRecoveryLevel 2
NopInInterval 10 NopInInterval 10
AllowDuplicateIsid Yes AllowDuplicateIsid Yes
[Rpc]
Enable Yes

View File

@ -16,7 +16,6 @@ $rootdir/scripts/gen_nvme.sh >> $testdir/iscsi.conf
# iSCSI target configuration # iSCSI target configuration
PORT=3260 PORT=3260
RPC_PORT=5260
INITIATOR_TAG=2 INITIATOR_TAG=2
INITIATOR_NAME=ALL INITIATOR_NAME=ALL
NETMASK=$INITIATOR_IP/32 NETMASK=$INITIATOR_IP/32
@ -31,7 +30,7 @@ echo "Process pid: $pid"
trap "killprocess $pid; exit 1" SIGINT SIGTERM EXIT trap "killprocess $pid; exit 1" SIGINT SIGTERM EXIT
waitforlisten $pid ${RPC_PORT} waitforlisten $pid
echo "iscsi_tgt is listening. Running tests..." echo "iscsi_tgt is listening. Running tests..."
timing_exit start_iscsi_tgt timing_exit start_iscsi_tgt

View File

@ -10,9 +10,6 @@
ImmediateData Yes ImmediateData Yes
ErrorRecoveryLevel 0 ErrorRecoveryLevel 0
[Rpc]
Enable Yes
# Do not specify InitiatorGroup, PortalGroup, Malloc, # Do not specify InitiatorGroup, PortalGroup, Malloc,
# or TargetNode entries here - the autotest.sh script # or TargetNode entries here - the autotest.sh script
# will use RPC to set up this part of the configuration. # will use RPC to set up this part of the configuration.

View File

@ -9,7 +9,6 @@ timing_enter filesystem
# iSCSI target configuration # iSCSI target configuration
PORT=3260 PORT=3260
RPC_PORT=5260
INITIATOR_TAG=2 INITIATOR_TAG=2
INITIATOR_NAME=ALL INITIATOR_NAME=ALL
NETMASK=$INITIATOR_IP/32 NETMASK=$INITIATOR_IP/32
@ -26,7 +25,7 @@ echo "Process pid: $pid"
trap "killprocess $pid; exit 1" SIGINT SIGTERM EXIT trap "killprocess $pid; exit 1" SIGINT SIGTERM EXIT
waitforlisten $pid ${RPC_PORT} waitforlisten $pid
echo "iscsi_tgt is listening. Running tests..." echo "iscsi_tgt is listening. Running tests..."
timing_exit start_iscsi_tgt timing_exit start_iscsi_tgt

View File

@ -8,6 +8,3 @@
MaxSessions 16 MaxSessions 16
ImmediateData Yes ImmediateData Yes
ErrorRecoveryLevel 0 ErrorRecoveryLevel 0
[Rpc]
Enable Yes

View File

@ -34,7 +34,7 @@ function running_config() {
pid=$! pid=$!
echo "Process pid: $pid" echo "Process pid: $pid"
trap "iscsicleanup; killprocess $pid; exit 1" SIGINT SIGTERM EXIT trap "iscsicleanup; killprocess $pid; exit 1" SIGINT SIGTERM EXIT
waitforlisten $pid ${RPC_PORT} waitforlisten $pid
echo "iscsi_tgt is listening. Running tests..." echo "iscsi_tgt is listening. Running tests..."
timing_exit start_iscsi_tgt2 timing_exit start_iscsi_tgt2
@ -59,7 +59,6 @@ cp $testdir/iscsi.conf.in $testdir/iscsi.conf
# iSCSI target configuration # iSCSI target configuration
PORT=3260 PORT=3260
RPC_PORT=5260
INITIATOR_TAG=2 INITIATOR_TAG=2
INITIATOR_NAME=ALL INITIATOR_NAME=ALL
NETMASK=$INITIATOR_IP/32 NETMASK=$INITIATOR_IP/32
@ -77,7 +76,7 @@ echo "Process pid: $pid"
trap "killprocess $pid; exit 1" SIGINT SIGTERM EXIT trap "killprocess $pid; exit 1" SIGINT SIGTERM EXIT
waitforlisten $pid ${RPC_PORT} waitforlisten $pid
echo "iscsi_tgt is listening. Running tests..." echo "iscsi_tgt is listening. Running tests..."
timing_exit start_iscsi_tgt timing_exit start_iscsi_tgt

View File

@ -9,9 +9,6 @@
ImmediateData Yes ImmediateData Yes
ErrorRecoveryLevel 0 ErrorRecoveryLevel 0
[Rpc]
Enable Yes
[Nvme] [Nvme]
RetryCount 4 RetryCount 4
Timeout 0 Timeout 0

View File

@ -9,7 +9,6 @@ timing_enter idle_migration
# iSCSI target configuration # iSCSI target configuration
PORT=3260 PORT=3260
RPC_PORT=5260
fio_py="python $rootdir/scripts/fio.py" fio_py="python $rootdir/scripts/fio.py"
@ -21,7 +20,7 @@ echo "Process pid: $pid"
trap "killprocess $pid; exit 1" SIGINT SIGTERM EXIT trap "killprocess $pid; exit 1" SIGINT SIGTERM EXIT
waitforlisten $pid ${RPC_PORT} waitforlisten $pid
echo "iscsi_tgt is listening. Running tests..." echo "iscsi_tgt is listening. Running tests..."
timing_exit start_iscsi_tgt timing_exit start_iscsi_tgt

View File

@ -8,5 +8,3 @@
MaxSessions 64 MaxSessions 64
ImmediateData Yes ImmediateData Yes
ErrorRecoveryLevel 0 ErrorRecoveryLevel 0
[Rpc]
Enable Yes

View File

@ -51,7 +51,7 @@ do
trap "kill_all_iscsi_target; exit 1" SIGINT SIGTERM EXIT trap "kill_all_iscsi_target; exit 1" SIGINT SIGTERM EXIT
waitforlisten $pid $port waitforlisten_tcp $pid $port
echo "iscsi_tgt is listening. Running tests..." echo "iscsi_tgt is listening. Running tests..."
timing_exit start_iscsi_tgt_$i timing_exit start_iscsi_tgt_$i

View File

@ -11,4 +11,3 @@
# The RPC section must be the last section in this file. # The RPC section must be the last section in this file.
[Rpc] [Rpc]
Enable Yes

View File

@ -8,6 +8,3 @@
MaxSessions 16 MaxSessions 16
ImmediateData Yes ImmediateData Yes
ErrorRecoveryLevel 0 ErrorRecoveryLevel 0
[Rpc]
Enable Yes

View File

@ -12,7 +12,6 @@ timing_enter iscsi_lvol
# iSCSI target configuration # iSCSI target configuration
PORT=3260 PORT=3260
RPC_PORT=5260
INITIATOR_TAG=2 INITIATOR_TAG=2
INITIATOR_NAME=ALL INITIATOR_NAME=ALL
NETMASK=$INITIATOR_IP/32 NETMASK=$INITIATOR_IP/32
@ -30,7 +29,7 @@ echo "Process pid: $pid"
trap "iscsicleanup; killprocess $pid; exit 1" SIGINT SIGTERM EXIT trap "iscsicleanup; killprocess $pid; exit 1" SIGINT SIGTERM EXIT
waitforlisten $pid ${RPC_PORT} waitforlisten $pid
echo "iscsi_tgt is listening. Running tests..." echo "iscsi_tgt is listening. Running tests..."
timing_exit start_iscsi_tgt timing_exit start_iscsi_tgt

View File

@ -28,7 +28,7 @@ $rootdir/app/nvmf_tgt/nvmf_tgt -c $rootdir/test/nvmf/nvmf.conf -m 0x2 -p 1 -s 38
nvmfpid=$! nvmfpid=$!
echo "NVMf target launched. pid: $nvmfpid" echo "NVMf target launched. pid: $nvmfpid"
trap "killprocess $nvmfpid; exit 1" SIGINT SIGTERM EXIT trap "killprocess $nvmfpid; exit 1" SIGINT SIGTERM EXIT
waitforlisten $nvmfpid 5260 waitforlisten $nvmfpid
echo "NVMf target has started." echo "NVMf target has started."
bdevs=$($rpc_py construct_malloc_bdev 64 512) 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" $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" echo "iSCSI target launched. pid: $iscsipid"
trap "killprocess $iscsipid; killprocess $nvmfpid; exit 1" SIGINT SIGTERM EXIT 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 # 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." echo "iSCSI target has started."
timing_exit start_iscsi_tgt timing_exit start_iscsi_tgt
echo "Creating an iSCSI target node." echo "Creating an iSCSI target node."
$rpc_py -p 5261 add_portal_group 1 $TARGET_IP:$ISCSI_PORT $rpc_py -s 127.0.0.1 -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_initiator_group 1 ALL $INITIATOR_IP/32
if [ $1 -eq 0 ]; then 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 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 sleep 1
echo "Logging in to iSCSI target." echo "Logging in to iSCSI target."

View File

@ -8,6 +8,3 @@
MaxSessions 16 MaxSessions 16
ImmediateData Yes ImmediateData Yes
ErrorRecoveryLevel 0 ErrorRecoveryLevel 0
[Rpc]
Enable Yes

View File

@ -13,7 +13,6 @@ BLOCKSIZE=$1
RUNTIME=$2 RUNTIME=$2
PMEM_BDEVS="" PMEM_BDEVS=""
PORT=3260 PORT=3260
RPC_PORT=5260
INITIATOR_TAG=2 INITIATOR_TAG=2
INITIATOR_NAME=ALL INITIATOR_NAME=ALL
NETMASK=$INITIATOR_IP/32 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 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..." echo "iscsi_tgt is listening. Running tests..."
timing_exit start_iscsi_target timing_exit start_iscsi_target

View File

@ -8,6 +8,3 @@
MaxSessions 16 MaxSessions 16
ImmediateData Yes ImmediateData Yes
ErrorRecoveryLevel 0 ErrorRecoveryLevel 0
[Rpc]
Enable Yes

View File

@ -14,7 +14,6 @@ timing_enter rbd
# iSCSI target configuration # iSCSI target configuration
PORT=3260 PORT=3260
RPC_PORT=5260
INITIATOR_TAG=2 INITIATOR_TAG=2
INITIATOR_NAME=ALL INITIATOR_NAME=ALL
NETMASK=$INITIATOR_IP/32 NETMASK=$INITIATOR_IP/32
@ -29,7 +28,7 @@ pid=$!
trap "killprocess $pid; exit 1" SIGINT SIGTERM EXIT trap "killprocess $pid; exit 1" SIGINT SIGTERM EXIT
waitforlisten $pid ${RPC_PORT} waitforlisten $pid
echo "iscsi_tgt is listening. Running tests..." echo "iscsi_tgt is listening. Running tests..."
timing_exit start_iscsi_tgt timing_exit start_iscsi_tgt

View File

@ -8,6 +8,3 @@
MaxSessions 16 MaxSessions 16
ImmediateData Yes ImmediateData Yes
ErrorRecoveryLevel 0 ErrorRecoveryLevel 0
[Rpc]
Enable Yes

View File

@ -11,7 +11,6 @@ timing_enter reset
# iSCSI target configuration # iSCSI target configuration
PORT=3260 PORT=3260
RPC_PORT=5260
INITIATOR_TAG=2 INITIATOR_TAG=2
INITIATOR_NAME=ALL INITIATOR_NAME=ALL
NETMASK=$INITIATOR_IP/32 NETMASK=$INITIATOR_IP/32
@ -33,7 +32,7 @@ echo "Process pid: $pid"
trap "killprocess $pid; exit 1" SIGINT SIGTERM EXIT trap "killprocess $pid; exit 1" SIGINT SIGTERM EXIT
waitforlisten $pid ${RPC_PORT} waitforlisten $pid
echo "iscsi_tgt is listening. Running tests..." echo "iscsi_tgt is listening. Running tests..."
timing_exit start_iscsi_tgt timing_exit start_iscsi_tgt

View File

@ -8,6 +8,3 @@
MaxSessions 16 MaxSessions 16
ImmediateData Yes ImmediateData Yes
ErrorRecoveryLevel 0 ErrorRecoveryLevel 0
[Rpc]
Enable Yes

View File

@ -9,7 +9,6 @@ timing_enter rpc_config
# iSCSI target configuration # iSCSI target configuration
PORT=3260 PORT=3260
RPC_PORT=5260
INITIATOR_TAG=2 INITIATOR_TAG=2
INITIATOR_NAME=ALL INITIATOR_NAME=ALL
NETMASK=$INITIATOR_IP/32 NETMASK=$INITIATOR_IP/32
@ -27,7 +26,7 @@ echo "Process pid: $pid"
trap "killprocess $pid; exit 1" SIGINT SIGTERM EXIT trap "killprocess $pid; exit 1" SIGINT SIGTERM EXIT
waitforlisten $pid ${RPC_PORT} waitforlisten $pid
echo "iscsi_tgt is listening. Running tests..." echo "iscsi_tgt is listening. Running tests..."
timing_exit start_iscsi_tgt timing_exit start_iscsi_tgt

View File

@ -14,8 +14,5 @@
AIO /dev/ram0 AIO0 AIO /dev/ram0 AIO0
AIO /tmp/aiofile AIO1 2048 AIO /tmp/aiofile AIO1 2048
[Rpc]
Enable Yes
[Ioat] [Ioat]
Disable Yes Disable Yes

View File

@ -950,6 +950,7 @@ main(int argc, char **argv)
config_file = argv[1]; config_file = argv[1];
} }
bdevtest_init(config_file, "0x7", &opts); bdevtest_init(config_file, "0x7", &opts);
opts.rpc_addr = NULL;
num_failures = spdk_app_start(&opts, start_timer, NULL, NULL); num_failures = spdk_app_start(&opts, start_timer, NULL, NULL);
spdk_app_fini(); spdk_app_fini();

View File

@ -757,6 +757,7 @@ main(int argc, char **argv)
} }
bdevtest_init(config_file, core_mask, &opts); bdevtest_init(config_file, core_mask, &opts);
opts.rpc_addr = NULL;
spdk_app_start(&opts, bdevperf_run, NULL, NULL); spdk_app_start(&opts, bdevperf_run, NULL, NULL);

View File

@ -10,7 +10,6 @@ test_cases=all
x="" x=""
rpc_py="$TEST_DIR/scripts/rpc.py " rpc_py="$TEST_DIR/scripts/rpc.py "
RPC_PORT=5260
function usage() { function usage() {
[[ ! -z $2 ]] && ( echo "$2"; echo ""; ) [[ ! -z $2 ]] && ( echo "$2"; echo ""; )
@ -82,7 +81,7 @@ function vhost_start()
$TEST_DIR/app/vhost/vhost -c $BASE_DIR/vhost.conf.in & $TEST_DIR/app/vhost/vhost -c $BASE_DIR/vhost.conf.in &
vhost_pid=$! vhost_pid=$!
echo $vhost_pid > $BASE_DIR/vhost.pid echo $vhost_pid > $BASE_DIR/vhost.pid
waitforlisten $vhost_pid $RPC_PORT waitforlisten $vhost_pid
} }
### Function stops vhost app ### Function stops vhost app

View File

@ -1,5 +1,2 @@
[Global] [Global]
LogFacility "local7" LogFacility "local7"
[Rpc]
Enable Yes
Listen 127.0.0.1

View File

@ -3,7 +3,6 @@
NVMF_PORT=4420 NVMF_PORT=4420
NVMF_IP_PREFIX="192.168.100" NVMF_IP_PREFIX="192.168.100"
NVMF_IP_LEAST_ADDR=8 NVMF_IP_LEAST_ADDR=8
RPC_PORT=5260
if [ -z "$NVMF_APP" ]; then if [ -z "$NVMF_APP" ]; then
NVMF_APP=./app/nvmf_tgt/nvmf_tgt NVMF_APP=./app/nvmf_tgt/nvmf_tgt

View File

@ -32,7 +32,7 @@ nvmfpid=$!
trap "killprocess $nvmfpid; exit 1" SIGINT SIGTERM EXIT trap "killprocess $nvmfpid; exit 1" SIGINT SIGTERM EXIT
waitforlisten $nvmfpid ${RPC_PORT} waitforlisten $nvmfpid
timing_exit start_nvmf_tgt timing_exit start_nvmf_tgt
bdevs="$bdevs $($rpc_py construct_null_bdev Null0 $NULL_BDEV_SIZE $NULL_BLOCK_SIZE)" bdevs="$bdevs $($rpc_py construct_null_bdev Null0 $NULL_BDEV_SIZE $NULL_BLOCK_SIZE)"

View File

@ -27,7 +27,7 @@ nvmfpid=$!
trap "killprocess $nvmfpid; exit 1" SIGINT SIGTERM EXIT trap "killprocess $nvmfpid; exit 1" SIGINT SIGTERM EXIT
waitforlisten $nvmfpid ${RPC_PORT} waitforlisten $nvmfpid
timing_exit start_nvmf_tgt timing_exit start_nvmf_tgt
bdevs="$bdevs $($rpc_py construct_malloc_bdev $MALLOC_BDEV_SIZE $MALLOC_BLOCK_SIZE)" bdevs="$bdevs $($rpc_py construct_malloc_bdev $MALLOC_BDEV_SIZE $MALLOC_BLOCK_SIZE)"

View File

@ -27,7 +27,7 @@ nvmfpid=$!
trap "killprocess $nvmfpid; exit 1" SIGINT SIGTERM EXIT trap "killprocess $nvmfpid; exit 1" SIGINT SIGTERM EXIT
waitforlisten $nvmfpid ${RPC_PORT} waitforlisten $nvmfpid
timing_exit start_nvmf_tgt timing_exit start_nvmf_tgt
bdevs="$bdevs $($rpc_py construct_malloc_bdev $MALLOC_BDEV_SIZE $MALLOC_BLOCK_SIZE)" bdevs="$bdevs $($rpc_py construct_malloc_bdev $MALLOC_BDEV_SIZE $MALLOC_BLOCK_SIZE)"

View File

@ -24,7 +24,7 @@ nvmfpid=$!
trap "killprocess $nvmfpid; exit 1" SIGINT SIGTERM EXIT trap "killprocess $nvmfpid; exit 1" SIGINT SIGTERM EXIT
waitforlisten $nvmfpid ${RPC_PORT} waitforlisten $nvmfpid
timing_exit start_nvmf_tgt timing_exit start_nvmf_tgt
bdevs="$bdevs $($rpc_py construct_malloc_bdev 64 512)" bdevs="$bdevs $($rpc_py construct_malloc_bdev 64 512)"

View File

@ -27,7 +27,7 @@ nvmfpid=$!
trap "killprocess $nvmfpid; exit 1" SIGINT SIGTERM EXIT trap "killprocess $nvmfpid; exit 1" SIGINT SIGTERM EXIT
waitforlisten $nvmfpid ${RPC_PORT} waitforlisten $nvmfpid
timing_exit start_nvmf_tgt timing_exit start_nvmf_tgt
bdevs="$bdevs $($rpc_py construct_malloc_bdev $MALLOC_BDEV_SIZE $MALLOC_BLOCK_SIZE)" bdevs="$bdevs $($rpc_py construct_malloc_bdev $MALLOC_BDEV_SIZE $MALLOC_BLOCK_SIZE)"

View File

@ -29,7 +29,7 @@ nvmfpid=$!
trap "killprocess $nvmfpid; exit 1" SIGINT SIGTERM EXIT trap "killprocess $nvmfpid; exit 1" SIGINT SIGTERM EXIT
waitforlisten $nvmfpid ${RPC_PORT} waitforlisten $nvmfpid
timing_exit start_nvmf_tgt timing_exit start_nvmf_tgt
bdevs="$bdevs $($rpc_py construct_malloc_bdev 64 512)" bdevs="$bdevs $($rpc_py construct_malloc_bdev 64 512)"

View File

@ -26,7 +26,7 @@ nvmfpid=$!
trap "killprocess $nvmfpid; exit 1" SIGINT SIGTERM EXIT trap "killprocess $nvmfpid; exit 1" SIGINT SIGTERM EXIT
waitforlisten $nvmfpid ${RPC_PORT} waitforlisten $nvmfpid
timing_exit start_nvmf_tgt timing_exit start_nvmf_tgt
bdevs="$bdevs $($rpc_py construct_malloc_bdev $MALLOC_BDEV_SIZE $MALLOC_BLOCK_SIZE)" bdevs="$bdevs $($rpc_py construct_malloc_bdev $MALLOC_BDEV_SIZE $MALLOC_BLOCK_SIZE)"

View File

@ -32,7 +32,7 @@ nvmfpid=$!
trap "killprocess $nvmfpid; exit 1" SIGINT SIGTERM EXIT trap "killprocess $nvmfpid; exit 1" SIGINT SIGTERM EXIT
waitforlisten $nvmfpid ${RPC_PORT} waitforlisten $nvmfpid
timing_exit start_nvmf_tgt timing_exit start_nvmf_tgt
bdevs="$bdevs $($rpc_py construct_malloc_bdev $MALLOC_BDEV_SIZE $MALLOC_BLOCK_SIZE)" bdevs="$bdevs $($rpc_py construct_malloc_bdev $MALLOC_BDEV_SIZE $MALLOC_BLOCK_SIZE)"

View File

@ -36,7 +36,7 @@ pid=$!
trap "disconnect_nvmf; killprocess $pid; exit 1" SIGINT SIGTERM EXIT trap "disconnect_nvmf; killprocess $pid; exit 1" SIGINT SIGTERM EXIT
waitforlisten $pid ${RPC_PORT} waitforlisten $pid
timing_exit start_nvmf_tgt timing_exit start_nvmf_tgt
modprobe -v nvme-rdma modprobe -v nvme-rdma

View File

@ -27,7 +27,7 @@ pid=$!
trap "killprocess $pid; exit 1" SIGINT SIGTERM EXIT trap "killprocess $pid; exit 1" SIGINT SIGTERM EXIT
waitforlisten $pid ${RPC_PORT} waitforlisten $pid
timing_exit start_nvmf_tgt timing_exit start_nvmf_tgt
modprobe -v nvme-rdma modprobe -v nvme-rdma

View File

@ -26,7 +26,7 @@ nvmfpid=$!
trap "killprocess $nvmfpid; exit 1" SIGINT SIGTERM EXIT trap "killprocess $nvmfpid; exit 1" SIGINT SIGTERM EXIT
waitforlisten $nvmfpid ${RPC_PORT} waitforlisten $nvmfpid
timing_exit start_nvmf_tgt timing_exit start_nvmf_tgt
bdevs="$bdevs $($rpc_py construct_malloc_bdev $MALLOC_BDEV_SIZE $MALLOC_BLOCK_SIZE)" bdevs="$bdevs $($rpc_py construct_malloc_bdev $MALLOC_BDEV_SIZE $MALLOC_BLOCK_SIZE)"

View File

@ -1,8 +1,5 @@
[Global] [Global]
Comment "Global section" Comment "Global section"
[Rpc]
Enable Yes
[Nvmf] [Nvmf]
MaxQueuesPerSession 4 MaxQueuesPerSession 4

View File

@ -1,8 +1,5 @@
[Global] [Global]
Comment "Global section" Comment "Global section"
[Rpc]
Enable Yes
[Nvmf] [Nvmf]
MaxQueuesPerSession 16 MaxQueuesPerSession 16

View File

@ -49,7 +49,7 @@ pid=$!
trap "disconnect_nvmf; rm -f /tmp/pool_file*; killprocess $pid; exit 1" SIGINT SIGTERM EXIT 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 timing_exit start_nvmf_tgt
modprobe -v nvme-rdma modprobe -v nvme-rdma

View File

@ -24,7 +24,7 @@ pid=$!
trap "killprocess $pid; exit 1" SIGINT SIGTERM EXIT trap "killprocess $pid; exit 1" SIGINT SIGTERM EXIT
waitforlisten $pid ${RPC_PORT} waitforlisten $pid
timing_exit start_nvmf_tgt timing_exit start_nvmf_tgt
# set times for subsystem construct/delete # set times for subsystem construct/delete

View File

@ -27,7 +27,7 @@ pid=$!
trap "killprocess $pid; exit 1" SIGINT SIGTERM EXIT trap "killprocess $pid; exit 1" SIGINT SIGTERM EXIT
waitforlisten $pid ${RPC_PORT} waitforlisten $pid
timing_exit start_nvmf_tgt timing_exit start_nvmf_tgt
# Create 10 subsystems # Create 10 subsystems

View File

@ -3,7 +3,6 @@
BASE_DIR=$(readlink -f $(dirname $0)) BASE_DIR=$(readlink -f $(dirname $0))
[[ -z "$TEST_DIR" ]] && TEST_DIR="$(cd $BASE_DIR/../../ && pwd)" [[ -z "$TEST_DIR" ]] && TEST_DIR="$(cd $BASE_DIR/../../ && pwd)"
rpc_py="$TEST_DIR/scripts/rpc.py " rpc_py="$TEST_DIR/scripts/rpc.py "
RPC_PORT=5260
source $TEST_DIR/scripts/autotest_common.sh source $TEST_DIR/scripts/autotest_common.sh
@ -76,10 +75,9 @@ function pmem_print_tc_name
function vhost_start() function vhost_start()
{ {
local vhost_conf_template="$TEST_DIR/test/pmem/vhost.conf.in"
local vhost_pid local vhost_pid
$TEST_DIR/app/vhost/vhost -c $vhost_conf_template & $TEST_DIR/app/vhost/vhost &
if [ $? != 0 ]; then if [ $? != 0 ]; then
echo -e "ERROR: Failed to launch vhost!" echo -e "ERROR: Failed to launch vhost!"
return 1 return 1
@ -87,7 +85,7 @@ function vhost_start()
vhost_pid=$! vhost_pid=$!
echo $vhost_pid > $TEST_DIR/test/pmem/vhost.pid echo $vhost_pid > $TEST_DIR/test/pmem/vhost.pid
waitforlisten $vhost_pid $RPC_PORT waitforlisten $vhost_pid
} }
function vhost_kill() function vhost_kill()

View File

@ -1,3 +0,0 @@
[Rpc]
Enable Yes
Listen 127.0.0.1

View File

@ -41,8 +41,6 @@ mkdir -p $TEST_DIR
. $COMMON_DIR/autotest.config . $COMMON_DIR/autotest.config
RPC_PORT=5260
# Trace flag is optional, if it wasn't set earlier - disable it after sourcing # Trace flag is optional, if it wasn't set earlier - disable it after sourcing
# autotest_common.sh # autotest_common.sh
if [[ $- =~ x ]]; then if [[ $- =~ x ]]; then
@ -162,7 +160,7 @@ function spdk_vhost_run()
echo $vhost_pid > $vhost_pid_file echo $vhost_pid > $vhost_pid_file
echo "INFO: waiting for app to run..." echo "INFO: waiting for app to run..."
waitforlisten "$vhost_pid" ${RPC_PORT} waitforlisten "$vhost_pid"
echo "INFO: vhost started - pid=$vhost_pid" echo "INFO: vhost started - pid=$vhost_pid"
rm $vhost_conf_file rm $vhost_conf_file

View File

@ -132,7 +132,6 @@ echo "Setting up VM"
echo "" echo ""
rpc_py="python $SPDK_BUILD_DIR/scripts/rpc.py " rpc_py="python $SPDK_BUILD_DIR/scripts/rpc.py "
rpc_py+="-s 127.0.0.1 "
for vm_conf in ${vms[@]}; do for vm_conf in ${vms[@]}; do
IFS=',' read -ra conf <<< "$vm_conf" IFS=',' read -ra conf <<< "$vm_conf"

View File

@ -1,8 +1,5 @@
[Global] [Global]
[Rpc]
Enable Yes
[Ioat] [Ioat]
Disable Yes Disable Yes

View File

@ -1,7 +1,4 @@
[Global] [Global]
[Rpc]
Enable Yes
[Ioat] [Ioat]
Disable Yes Disable Yes

View File

@ -1,6 +1,3 @@
[Rpc]
Enable Yes
[Ioat] [Ioat]
Disable Yes Disable Yes

View File

@ -9,8 +9,6 @@ qemu_install_dir="$testdir/root"
MAKE="make -j$(( $(nproc) * 2 ))" MAKE="make -j$(( $(nproc) * 2 ))"
rpc_py="python $rootdir/scripts/rpc.py " rpc_py="python $rootdir/scripts/rpc.py "
rpc_py+="-s 127.0.0.1 "
RPC_PORT=5260
HOST_IP=192.200.200.1 HOST_IP=192.200.200.1
VM_IP=192.200.200.254 VM_IP=192.200.200.254
VM_UNAME="root" VM_UNAME="root"
@ -113,7 +111,7 @@ cd /tmp
$rootdir/app/vhost/vhost -c $basedir/vhost.conf & $rootdir/app/vhost/vhost -c $basedir/vhost.conf &
pid=$! pid=$!
echo "Process pid: $pid" echo "Process pid: $pid"
waitforlisten "$pid" "$RPC_PORT" waitforlisten "$pid"
if [[ "$VHOST_MODE" == "scsi" ]]; then if [[ "$VHOST_MODE" == "scsi" ]]; then
$rpc_py construct_vhost_scsi_controller naa.0 $rpc_py construct_vhost_scsi_controller naa.0
$rpc_py add_vhost_scsi_lun naa.0 0 Nvme0n1 $rpc_py add_vhost_scsi_lun naa.0 0 Nvme0n1

View File

@ -1,7 +1,4 @@
[Global] [Global]
[Rpc]
Enable Yes
[Ioat] [Ioat]
Disable Yes Disable Yes

View File

@ -7,7 +7,6 @@ BASE_DIR=$(readlink -f $(dirname $0))
. $COMMON_DIR/common.sh . $COMMON_DIR/common.sh
rpc_py="python $SPDK_BUILD_DIR/scripts/rpc.py " rpc_py="python $SPDK_BUILD_DIR/scripts/rpc.py "
rpc_py+="-s 127.0.0.1 "
vm_count=1 vm_count=1
max_disks="" max_disks=""

View File

@ -1,5 +1,3 @@
[Global] [Global]
[Rpc]
Enable Yes
[Ioat] [Ioat]
Disable Yes Disable Yes