无法使用jupyterhub运行ipython notebook 2.7

无法使用jupyterhub运行ipython notebook 2.7,ipython,ipython-notebook,jupyter,Ipython,Ipython Notebook,Jupyter,我试图在Ubuntu14.04上用jupyterhub运行iPython2.7笔记本电脑,但我还没有找到一个方法。有什么建议吗 我知道需要在~/.ipython/kernels.json文件中添加内核 我在此文件中有以下内容: { "argv": ["python3", "-m", "IPython.kernel", "-f", "{connection_file}"], "display_name": "Python 3", "language": "python"

我试图在Ubuntu14.04上用jupyterhub运行iPython2.7笔记本电脑,但我还没有找到一个方法。有什么建议吗

我知道需要在~/.ipython/kernels.json文件中添加内核 我在此文件中有以下内容:

{
 "argv": ["python3", "-m", "IPython.kernel",
          "-f", "{connection_file}"],
 "display_name": "Python 3",
 "language": "python"
}
{
 "argv": ["python2.7", "-m", "IPython.kernel",
      "-f", "{connection_file}"],
 "display_name": "Python 2",
 "language": "python"
}   

~/.ipython/kernels.json
不是正确的路径。这些文件不允许手工编辑。此外,您拥有的文件不是有效的json,如果文件位于正确的位置,服务器将无法读取该文件

使用
python2.7-m IPython kernelspec安装self
python3-m IPython kernelspec安装self
让IPython将正确的文件放在正确的位置


也就是说,即使内核文件出错,您也应该能够启动jupyterhub。您是否有其他错误消息?

我可以启动jupyterhub并制作ipython3笔记本电脑。当我运行'python2.7-m IPython kernelspec install self'时,我收到一条错误消息——“python2.7 File not found kernelspec”正在尝试解决这个问题。我无法使kernelspec自动工作-只是在jupyter/kernels/python2/{“display_name”:“Python 2”,“language”:“Python”,“argv”:[“/usr/bin/python2”、“-c”、“from IPython.kernel.zmq.kernelapp import main;main()”、“-f”、“{connection_file}”]}错误消息是因为python2.7上没有安装IPython 3.x。不要手动创建这些文件,以后会出现问题。