Add RAMCloud transport timeout option.
- This option might be used as part of ONOS-1245
Change-Id: Ice5fb8dbe9891a77e6d86bfb9822101fa381d32d
diff --git a/conf/onos_node.conf b/conf/onos_node.conf
index 8215ce4..81319c3 100644
--- a/conf/onos_node.conf
+++ b/conf/onos_node.conf
@@ -19,9 +19,12 @@
# myid will be assigned incrementally according to order of list
#zookeeper.hosts = onosdev1,onosdev2,onosdev3,onosdev4
-# RAMClouod clusterName (ONOS-RC by default)
+# RAMCloud clusterName (ONOS-RC by default)
#ramcloud.clusterName = ONOS-RC
+# RAMCloud transport timeout (1000 by ONOS default)
+#ramcloud.timeout = 1000
+
# Protocol used by RAMCloud coordinator (fast+udp by default)
#ramcloud.coordinator.protocol = fast+udp
@@ -51,11 +54,13 @@
#ramcloud.server.logCleanerThreads = 1
# RAMCloud server option detectFailures [0=disabled] (1 by default)
+# Note: Disable this option when running on low performing VM, etc.
#ramcloud.server.detectFailures = 1
# RAMCloud server option replicas (0 by default)
# This value must be the same cluster wide.
-# On N node cluster, maximum value will be N-1 replicas
+# On N node cluster, maximum value will be N-1 replicas.
+# A replication factor 2 is probably reasonably safe, 3 is conservative.
#ramcloud.server.replicas = 0
# RAMCloud server option file (/var/tmp/ramclouddata/backup.`hostname`.log by default)
diff --git a/onos.sh b/onos.sh
index b155176..508ae3e 100755
--- a/onos.sh
+++ b/onos.sh
@@ -569,6 +569,8 @@
local zk_addr="localhost:2181"
# RAMCloud cluster name
local rc_cluster_name=$(read-conf ${ONOS_CONF} ramcloud.clusterName "ONOS-RC")
+ # RAMCloud transport timeout
+ local rc_timeout=$(read-conf ${ONOS_CONF} ramcloud.timeout 1000)
# RAMCloud option deadServerTimeout
# (note RC default is 250ms, setting relaxed ONOS default to 1000ms)
local rc_coord_deadServerTimeout=$(read-conf ${ONOS_CONF} ramcloud.coordinator.deadServerTimeout 1000)
@@ -580,6 +582,7 @@
local coord_args="-C ${coord_addr}"
coord_args="${coord_args} --externalStorage zk:${zk_addr}"
coord_args="${coord_args} --clusterName ${rc_cluster_name}"
+ coord_args="${coord_args} --timeout ${rc_timeout}"
coord_args="${coord_args} --deadServerTimeout ${rc_coord_deadServerTimeout}"
# Read environment variables if set
@@ -695,6 +698,8 @@
local zk_addr="localhost:2181"
# RAMCloud cluster name
local rc_cluster_name=$(read-conf ${ONOS_CONF} ramcloud.clusterName "ONOS-RC")
+ # RAMCloud transport timeout
+ local rc_timeout=$(read-conf ${ONOS_CONF} ramcloud.timeout 1000)
# replication factor (-r) config
local rc_replicas=$(read-conf ${ONOS_CONF} ramcloud.server.replicas 0)
# backup file path (-f) config
@@ -704,6 +709,7 @@
local server_args="-L ${server_addr}"
server_args="${server_args} --externalStorage zk:${zk_addr}"
server_args="${server_args} --clusterName ${rc_cluster_name}"
+ server_args="${server_args} --timeout ${rc_timeout}"
server_args="${server_args} --masterServiceThreads ${masterServiceThreads}"
server_args="${server_args} --logCleanerThreads ${logCleanerThreads}"
server_args="${server_args} --detectFailures ${detectFailures}"