diff options
author | Sean Owen <sowen@cloudera.com> | 2016-09-18 16:22:31 +0100 |
---|---|---|
committer | Sean Owen <sowen@cloudera.com> | 2016-09-18 16:22:31 +0100 |
commit | 342c0e65bec4b9a715017089ab6ea127f3c46540 (patch) | |
tree | e36f5743b9f72d44f4a96667e4edff06b897dd18 | |
parent | 5d3f4615f8d0a19b97cde5ae603f74aef2cc2fd2 (diff) | |
download | spark-342c0e65bec4b9a715017089ab6ea127f3c46540.tar.gz spark-342c0e65bec4b9a715017089ab6ea127f3c46540.tar.bz2 spark-342c0e65bec4b9a715017089ab6ea127f3c46540.zip |
[SPARK-17546][DEPLOY] start-* scripts should use hostname -f
## What changes were proposed in this pull request?
Call `hostname -f` to get fully qualified host name
## How was this patch tested?
Jenkins tests of course, but also verified output of command on OS X and Linux
Author: Sean Owen <sowen@cloudera.com>
Closes #15129 from srowen/SPARK-17546.
-rwxr-xr-x | sbin/start-master.sh | 2 | ||||
-rwxr-xr-x | sbin/start-mesos-dispatcher.sh | 2 | ||||
-rwxr-xr-x | sbin/start-slaves.sh | 2 |
3 files changed, 3 insertions, 3 deletions
diff --git a/sbin/start-master.sh b/sbin/start-master.sh index 981cb15bc0..d970fcc45e 100755 --- a/sbin/start-master.sh +++ b/sbin/start-master.sh @@ -48,7 +48,7 @@ if [ "$SPARK_MASTER_PORT" = "" ]; then fi if [ "$SPARK_MASTER_HOST" = "" ]; then - SPARK_MASTER_HOST=`hostname` + SPARK_MASTER_HOST=`hostname -f` fi if [ "$SPARK_MASTER_WEBUI_PORT" = "" ]; then diff --git a/sbin/start-mesos-dispatcher.sh b/sbin/start-mesos-dispatcher.sh index 06a966d1c2..ef65fb9539 100755 --- a/sbin/start-mesos-dispatcher.sh +++ b/sbin/start-mesos-dispatcher.sh @@ -34,7 +34,7 @@ if [ "$SPARK_MESOS_DISPATCHER_PORT" = "" ]; then fi if [ "$SPARK_MESOS_DISPATCHER_HOST" = "" ]; then - SPARK_MESOS_DISPATCHER_HOST=`hostname` + SPARK_MESOS_DISPATCHER_HOST=`hostname -f` fi if [ "$SPARK_MESOS_DISPATCHER_NUM" = "" ]; then diff --git a/sbin/start-slaves.sh b/sbin/start-slaves.sh index 0fa1605489..7d8871251f 100755 --- a/sbin/start-slaves.sh +++ b/sbin/start-slaves.sh @@ -32,7 +32,7 @@ if [ "$SPARK_MASTER_PORT" = "" ]; then fi if [ "$SPARK_MASTER_HOST" = "" ]; then - SPARK_MASTER_HOST="`hostname`" + SPARK_MASTER_HOST="`hostname -f`" fi # Launch the slaves |