title: jupyter throwing error: socket.gaierror: [Errno -2] Name or service not known
body: <p>I run a pyspark cluster on AWS EMR and use Jupyter to the pyspark driver. Recently, the script failed. Jupiter fails to start a server. I install with <code>conda install jupyter</code> and start with <code>sudo initctl start jupyter</code>. The cluster runs fine. Here are the config values of the server.</p>
  
  <pre><code># jupyter configs
  mkdir -p ~/.jupyter
  touch ls ~/.jupyter/jupyter_notebook_config.py
  HASHED_PASSWORD=$(python -c "from notebook.auth import passwd; 
  print(passwd('$JUPYTER_PASSWORD'))")
  echo "c.NotebookApp.password = u'$HASHED_PASSWORD'" &gt;&gt; ~/.jupyter/jupyter_notebook_config.py
  echo "c.NotebookApp.open_browser = False" &gt;&gt; ~/.jupyter/jupyter_notebook_config.py
  echo "c.NotebookApp.ip = '*'" &gt;&gt; ~/.jupyter/jupyter_notebook_config.py
  echo "c.NotebookApp.notebook_dir = '/mnt/$BUCKET/$FOLDER'" &gt;&gt; ~/.jupyter/jupyter_notebook_config.py
  echo "c.ContentsManager.checkpoints_kwargs = {'root_dir': '.checkpoints'}" &gt;&gt; ~/.jupyter/jupyter_notebook_config.py
  echo "c.NotebookApp.port = 8080" &gt;&gt; ~/.jupyter/jupyter_notebook_config.py
  </code></pre>