title: Jupyter notebook can't find kernel when run through /etc/rc.local
body: <p>I have a Jupyter Notebook server on an EC2 instance with python2 (default) and ITorch kernels. Everything works fine when run through SSH command line.</p>
  
  <p>The problem is that when I try to make this run at startup, the notebook server can't find ITorch kernel. I does work fine for python notebooks though. The error I get is a window saying</p>
  
  <pre><code>Kernel not found
  I couldn't find a kernel matching iTorch. Please select a kernel: (python2)
  </code></pre>
  
  <p>What I did was adding this line to <code>/etc/rc.local</code></p>
  
  <pre><code> /home/ubuntu/anaconda2/bin/jupyter-notebook --JupyterApp.config-file=/home/ubuntu/.jupyter/jupyter_notebook_config.py &amp;&gt; /dev/null &amp;
  </code></pre>
  
  <p>The notebook server apparently runs fine. This is from the system log</p>
  
  <pre><code>ip-172-31-20-152 login: [32m[I 12:20:51.073 NotebookApp][0;10m Serving notebooks from local directory: /home/ubuntu/notebook
  [32m[I 12:20:51.076 NotebookApp][0;10m 0 active kernels 
  [32m[I 12:20:51.078 NotebookApp][0;10m The Jupyter Notebook is running at: https://[all ip addresses on your system]:8888/
  [32m[I 12:20:51.081 NotebookApp][0;10m Use Control-C to stop this server and shut down all kernels (twice to skip confirmation).
  </code></pre>
  
  <p>These are the only lines I modified in my config file</p>
  
  <pre><code># Configuration file for jupyter-notebook.
  c = get_config()
  c.NotebookApp.notebook_dir = u'/home/ubuntu/notebook'
  c.NotebookApp.certfile = u'/home/ubuntu/certs/mycert.pem'
  c.NotebookApp.keyfile = u'/home/ubuntu/certs/mycert.key'
  c.NotebookApp.ip = '*'
  c.NotebookApp.open_browser = False
  c.NotebookApp.password = u'&lt;password&gt;'
  c.NotebookApp.port = 8888
  </code></pre>