title: failed to launch apache.spark.master
body: <p>Whenever i run <strong>start-master.sh</strong> command on my local machine i am getting following error please someone help me to fix this issue  </p>
  
  <h3>Terminal Error</h3>
  
  <p>Error which i get in terminal</p>
  
  <pre><code>starting org.apache.spark.deploy.master.Master, logging to /usr/local/spark-2.0.1-bin-hadoop2.6/logs/spark-andani-org.apache.spark.deploy.master.Master-1-andani.sakha.com.out
  failed to launch org.apache.spark.deploy.master.Master:
  at io.netty.util.concurrent.SingleThreadEventExecutor$2.run(SingleThreadEventExecutor.java:111)
  at java.lang.Thread.run(Thread.java:748)
  </code></pre>
  
  <h3>Log Error</h3>
  
  <p>If i check the spark log file following is the error</p>
  
  <pre><code>Exception in thread "main" java.net.BindException: Cannot assign requested address: Service 'sparkMaster' failed after 16 retries! Consider explicitly setting the appropriate port for the service 'sparkMaster' (for example spark.ui.port for SparkUI) to an available port or increasing spark.port.maxRetries.
     at sun.nio.ch.Net.bind0(Native Method)
     at sun.nio.ch.Net.bind(Net.java:433)
     at sun.nio.ch.Net.bind(Net.java:425)
     at sun.nio.ch.ServerSocketChannelImpl.bind(ServerSocketChannelImpl.java:223)
     at sun.nio.ch.ServerSocketAdaptor.bind(ServerSocketAdaptor.java:74)
     at io.netty.channel.socket.nio.NioServerSocketChannel.doBind(NioServerSocketChannel.java:125)
     at io.netty.channel.AbstractChannel$AbstractUnsafe.bind(AbstractChannel.java:485)
     at io.netty.channel.DefaultChannelPipeline$HeadContext.bind(DefaultChannelPipeline.java:1089)
     at io.netty.channel.AbstractChannelHandlerContext.invokeBind(AbstractChannelHandlerContext.java:430)
     at io.netty.channel.AbstractChannelHandlerContext.bind(AbstractChannelHandlerContext.java:415)
     at io.netty.channel.DefaultChannelPipeline.bind(DefaultChannelPipeline.java:903)
     at io.netty.channel.AbstractChannel.bind(AbstractChannel.java:198)
     at io.netty.bootstrap.AbstractBootstrap$2.run(AbstractBootstrap.java:348)
     at io.netty.util.concurrent.SingleThreadEventExecutor.runAllTasks(SingleThreadEventExecutor.java:357)
     at io.netty.channel.nio.NioEventLoop.run(NioEventLoop.java:357)
     at io.netty.util.concurrent.SingleThreadEventExecutor$2.run(SingleThreadEventExecutor.java:111)
     at java.lang.Thread.run(Thread.java:748)
  </code></pre>