install jupyter

python jupyter setup 

1. 환경준비
    Centos 7.x
    Anaconda Python 3.7 version

2. install
[root@localhost ~]# . ./venv/bin/activate
(venv) [root@localhost ~]# pip install jupyter
Collecting jupyter
  Using cached https://files.pythonhosted.org/packages/83/df/0f5dd132200728a86190397e1ea87cd76244e42d39ec5e88efd25b2abd7e/jupyter-1.0.0-py2.py3-none-any.whl
Collecting ipykernel (from jupyter)
  Downloading https://files.pythonhosted.org/packages/a0/35/dd97fbb48d4e6b5ae97307497e31e46691adc2feedb6279d29fc1c8ad9c1/ipykernel-5.1.1-py3-none-any.whl (114kB)
     |████████████████████████████████| 122kB 253kB/s
Collecting notebook (from jupyter)
  Using cached https://files.pythonhosted.org/packages/f6/36/89ebfffc9dd8c8dbd81c1ffb53e3d4233ee666414c143959477cb07cc5f5/notebook-5.7.8-py2.py3-none-any.whl
Collecting jupyter-console (from jupyter)
  Downloading https://files.pythonhosted.org/packages/cb/ee/6374ae8c21b7d0847f9c3722dcdfac986b8e54fa9ad9ea66e1eb6320d2b8/jupyter_console-6.0.0-py2.py3-none-any.whl
Collecting nbconvert (from jupyter)
  Using cached https://files.pythonhosted.org/packages/35/e7/f46c9d65f149271e47fca6ab084ef5c6e4cb1870f4c5cce6690feac55231/nbconvert-5.5.0-py2.py3-none-any.whl
Collecting ipywidgets (from jupyter)
  Using cached https://files.pythonhosted.org/packages/86/c2/20a3514f87fc063b4853673966e85c091843de659374d6e1dd046319815a/ipywidgets-7.5.0-py2.py3-none-any.whl
Collecting qtconsole (from jupyter)
  Using cached https://files.pythonhosted.org/packages/79/0b/efb5a694b6922bb85c35e4f1db6197daae23c764dd384023fc9517d79e26/qtconsole-4.5.1-py2.py3-none-any.whl
Collecting traitlets>=4.1.0 (from ipykernel->jupyter)
  Downloading https://files.pythonhosted.org/packages/93/d6/abcb22de61d78e2fc3959c964628a5771e47e7cc60d53e9342e21ed6cc9a/traitlets-4.3.2-py2.py3-none-any.whl (74kB)
     |████████████████████████████████| 81kB 6.7MB/s
Collecting jupyter-client (from ipykernel->jupyter)
  Downloading https://files.pythonhosted.org/packages/af/4c/bf613864ae0644e2ac7d4a40bd209c40c8c71e3dc88d5f1d0aa92a68e716/jupyter_client-5.3.1-py2.py3-none-any.whl (91kB)
     |████████████████████████████████| 92kB 8.0MB/s
Collecting ipython>=5.0.0 (from ipykernel->jupyter)
  Downloading https://files.pythonhosted.org/packages/a6/2c/c7d44277b599df35af734d8f4142d501192fdb7aef5d04daf882d7eccfbc/ipython-7.6.1-py3-none-any.whl (774kB)
     |████████████████████████████████| 778kB 11.7MB/s
Collecting tornado>=4.2 (from ipykernel->jupyter)
  Downloading https://files.pythonhosted.org/packages/30/78/2d2823598496127b21423baffaa186b668f73cd91887fcef78b6eade136b/tornado-6.0.3.tar.gz (482kB)
     |████████████████████████████████| 491kB 11.3MB/s
Collecting jinja2 (from notebook->jupyter)
  Downloading https://files.pythonhosted.org/packages/1d/e7/fd8b501e7a6dfe492a433deb7b9d833d39ca74916fa8bc63dd1a4947a671/Jinja2-2.10.1-py2.py3-none-any.whl (124kB)
     |████████████████████████████████| 133kB 10.3MB/s
Collecting terminado>=0.8.1 (from notebook->jupyter)
  Downloading https://files.pythonhosted.org/packages/a7/56/80ea7fa66565fa75ae21ce0c16bc90067530e5d15e48854afcc86585a391/terminado-0.8.2-py2.py3-none-any.whl
Collecting pyzmq>=17 (from notebook->jupyter)
  Downloading https://files.pythonhosted.org/packages/92/92/ea8f20560d5f1d0c6eb3c7c67ca72abfb97307f4e6494fc05cc7c37904cf/pyzmq-18.0.2-cp36-cp36m-manylinux1_x86_64.whl (1.1MB)
     |████████████████████████████████| 1.1MB 9.6MB/s
Collecting jupyter-core>=4.4.0 (from notebook->jupyter)
  Downloading https://files.pythonhosted.org/packages/e6/25/6ffb0f6e57fa6ef5d2f814377133b361b42a6dd39105f4885a4f1666c2c3/jupyter_core-4.5.0-py2.py3-none-any.whl (78kB)
     |████████████████████████████████| 81kB 6.9MB/s
Collecting nbformat (from notebook->jupyter)
  Downloading https://files.pythonhosted.org/packages/da/27/9a654d2b6cc1eaa517d1c5a4405166c7f6d72f04f6e7eea41855fe808a46/nbformat-4.4.0-py2.py3-none-any.whl (155kB)
     |████████████████████████████████| 163kB 11.9MB/s
Collecting ipython-genutils (from notebook->jupyter)
  Downloading https://files.pythonhosted.org/packages/fa/bc/9bd3b5c2b4774d5f33b2d544f1460be9df7df2fe42f352135381c347c69a/ipython_genutils-0.2.0-py2.py3-none-any.whl
Collecting Send2Trash (from notebook->jupyter)
  Downloading https://files.pythonhosted.org/packages/49/46/c3dc27481d1cc57b9385aff41c474ceb7714f7935b1247194adae45db714/Send2Trash-1.5.0-py3-none-any.whl
Collecting prometheus-client (from notebook->jupyter)
  Downloading https://files.pythonhosted.org/packages/b3/23/41a5a24b502d35a4ad50a5bb7202a5e1d9a0364d0c12f56db3dbf7aca76d/prometheus_client-0.7.1.tar.gz
Collecting prompt-toolkit<2.1.0,>=2.0.0 (from jupyter-console->jupyter)
  Downloading https://files.pythonhosted.org/packages/f7/a7/9b1dd14ef45345f186ef69d175bdd2491c40ab1dfa4b2b3e4352df719ed7/prompt_toolkit-2.0.9-py3-none-any.whl (337kB)
     |████████████████████████████████| 337kB 9.8MB/s
Collecting pygments (from jupyter-console->jupyter)
  Downloading https://files.pythonhosted.org/packages/5c/73/1dfa428150e3ccb0fa3e68db406e5be48698f2a979ccbcec795f28f44048/Pygments-2.4.2-py2.py3-none-any.whl (883kB)
     |████████████████████████████████| 890kB 10.9MB/s
Collecting defusedxml (from nbconvert->jupyter)
  Downloading https://files.pythonhosted.org/packages/06/74/9b387472866358ebc08732de3da6dc48e44b0aacd2ddaa5cb85ab7e986a2/defusedxml-0.6.0-py2.py3-none-any.whl
Collecting bleach (from nbconvert->jupyter)
  Downloading https://files.pythonhosted.org/packages/ab/05/27e1466475e816d3001efb6e0a85a819be17411420494a1e602c36f8299d/bleach-3.1.0-py2.py3-none-any.whl (157kB)
     |████████████████████████████████| 163kB 12.7MB/s
Collecting pandocfilters>=1.4.1 (from nbconvert->jupyter)
  Downloading https://files.pythonhosted.org/packages/4c/ea/236e2584af67bb6df960832731a6e5325fd4441de001767da328c33368ce/pandocfilters-1.4.2.tar.gz
Collecting mistune>=0.8.1 (from nbconvert->jupyter)
  Downloading https://files.pythonhosted.org/packages/09/ec/4b43dae793655b7d8a25f76119624350b4d65eb663459eb9603d7f1f0345/mistune-0.8.4-py2.py3-none-any.whl
Collecting entrypoints>=0.2.2 (from nbconvert->jupyter)
  Downloading https://files.pythonhosted.org/packages/ac/c6/44694103f8c221443ee6b0041f69e2740d89a25641e62fb4f2ee568f2f9c/entrypoints-0.3-py2.py3-none-any.whl
Collecting testpath (from nbconvert->jupyter)
  Downloading https://files.pythonhosted.org/packages/be/a4/162f9ebb6489421fe46dcca2ae420369edfee4b563c668d93cb4605d12ba/testpath-0.4.2-py2.py3-none-any.whl (163kB)
     |████████████████████████████████| 163kB 10.8MB/s
Collecting widgetsnbextension~=3.5.0 (from ipywidgets->jupyter)
  Downloading https://files.pythonhosted.org/packages/04/2b/32408aa2aaf5230450903b148dae888734add9e2fc190a817811546d2f93/widgetsnbextension-3.5.0-py2.py3-none-any.whl (2.2MB)
     |████████████████████████████████| 2.2MB 9.5MB/s
Requirement already satisfied: six in ./venv/lib/python3.6/site-packages (from traitlets>=4.1.0->ipykernel->jupyter) (1.12.0)
Collecting decorator (from traitlets>=4.1.0->ipykernel->jupyter)
  Downloading https://files.pythonhosted.org/packages/5f/88/0075e461560a1e750a0dcbf77f1d9de775028c37a19a346a6c565a257399/decorator-4.4.0-py2.py3-none-any.whl
Requirement already satisfied: python-dateutil>=2.1 in ./venv/lib/python3.6/site-packages (from jupyter-client->ipykernel->jupyter) (2.7.5)
Requirement already satisfied: setuptools>=18.5 in ./venv/lib/python3.6/site-packages (from ipython>=5.0.0->ipykernel->jupyter) (40.6.2)
Collecting backcall (from ipython>=5.0.0->ipykernel->jupyter)
  Downloading https://files.pythonhosted.org/packages/84/71/c8ca4f5bb1e08401b916c68003acf0a0655df935d74d93bf3f3364b310e0/backcall-0.1.0.tar.gz
Collecting pexpect; sys_platform != "win32" (from ipython>=5.0.0->ipykernel->jupyter)
  Downloading https://files.pythonhosted.org/packages/0e/3e/377007e3f36ec42f1b84ec322ee12141a9e10d808312e5738f52f80a232c/pexpect-4.7.0-py2.py3-none-any.whl (58kB)
     |████████████████████████████████| 61kB 5.3MB/s
Collecting jedi>=0.10 (from ipython>=5.0.0->ipykernel->jupyter)
  Downloading https://files.pythonhosted.org/packages/68/42/6309f3871b2f8361764ac5b2fe6719f9c6e6561d9307d8cecda319cf5843/jedi-0.14.0-py2.py3-none-any.whl (1.0MB)
     |████████████████████████████████| 1.0MB 11.1MB/s
Collecting pickleshare (from ipython>=5.0.0->ipykernel->jupyter)
  Downloading https://files.pythonhosted.org/packages/9a/41/220f49aaea88bc6fa6cba8d05ecf24676326156c23b991e80b3f2fc24c77/pickleshare-0.7.5-py2.py3-none-any.whl
Collecting MarkupSafe>=0.23 (from jinja2->notebook->jupyter)
  Downloading https://files.pythonhosted.org/packages/b2/5f/23e0023be6bb885d00ffbefad2942bc51a620328ee910f64abe5a8d18dd1/MarkupSafe-1.1.1-cp36-cp36m-manylinux1_x86_64.whl
Collecting ptyprocess; os_name != "nt" (from terminado>=0.8.1->notebook->jupyter)
  Downloading https://files.pythonhosted.org/packages/d1/29/605c2cc68a9992d18dada28206eeada56ea4bd07a239669da41674648b6f/ptyprocess-0.6.0-py2.py3-none-any.whl
Requirement already satisfied: jsonschema!=2.5.0,>=2.4 in ./venv/lib/python3.6/site-packages (from nbformat->notebook->jupyter) (3.0.1)
Collecting wcwidth (from prompt-toolkit<2.1.0,>=2.0.0->jupyter-console->jupyter)
  Downloading https://files.pythonhosted.org/packages/7e/9f/526a6947247599b084ee5232e4f9190a38f398d7300d866af3ab571a5bfe/wcwidth-0.1.7-py2.py3-none-any.whl
Collecting webencodings (from bleach->nbconvert->jupyter)
  Downloading https://files.pythonhosted.org/packages/f4/24/2a3e3df732393fed8b3ebf2ec078f05546de641fe1b667ee316ec1dcf3b7/webencodings-0.5.1-py2.py3-none-any.whl
Collecting parso>=0.3.0 (from jedi>=0.10->ipython>=5.0.0->ipykernel->jupyter)
  Downloading https://files.pythonhosted.org/packages/68/59/482f5a00fe3da7f0aaeedf61c2a25c445b68c9124437195f6e8b2beddbc0/parso-0.5.0-py2.py3-none-any.whl (94kB)
     |████████████████████████████████| 102kB 8.0MB/s
Requirement already satisfied: attrs>=17.4.0 in ./venv/lib/python3.6/site-packages (from jsonschema!=2.5.0,>=2.4->nbformat->notebook->jupyter) (19.1.0)
Requirement already satisfied: pyrsistent>=0.14.0 in ./venv/lib/python3.6/site-packages (from jsonschema!=2.5.0,>=2.4->nbformat->notebook->jupyter) (0.15.3)
Installing collected packages: decorator, ipython-genutils, traitlets, pyzmq, tornado, jupyter-core, jupyter-client, wcwidth, prompt-toolkit, backcall, ptyprocess, pexpect, pygments, parso, jedi, pickleshare, ipython, ipykernel, MarkupSafe, jinja2, terminado, nbformat, defusedxml, webencodings, bleach, pandocfilters, mistune, entrypoints, testpath, nbconvert, Send2Trash, prometheus-client, notebook, jupyter-console, widgetsnbextension, ipywidgets, qtconsole, jupyter
  Running setup.py install for tornado ... done
  Running setup.py install for backcall ... done
  Running setup.py install for pandocfilters ... done
  Running setup.py install for prometheus-client ... done
Successfully installed MarkupSafe-1.1.1 Send2Trash-1.5.0 backcall-0.1.0 bleach-3.1.0 decorator-4.4.0 defusedxml-0.6.0 entrypoints-0.3 ipykernel-5.1.1 ipython-7.6.1 ipython-genutils-0.2.0 ipywidgets-7.5.0 jedi-0.14.0 jinja2-2.10.1 jupyter-1.0.0 jupyter-client-5.3.1 jupyter-console-6.0.0 jupyter-core-4.5.0 mistune-0.8.4 nbconvert-5.5.0 nbformat-4.4.0 notebook-5.7.8 pandocfilters-1.4.2 parso-0.5.0 pexpect-4.7.0 pickleshare-0.7.5 prometheus-client-0.7.1 prompt-toolkit-2.0.9 ptyprocess-0.6.0 pygments-2.4.2 pyzmq-18.0.2 qtconsole-4.5.1 terminado-0.8.2 testpath-0.4.2 tornado-6.0.3 traitlets-4.3.2 wcwidth-0.1.7 webencodings-0.5.1 widgetsnbextension-3.5.0
(venv) [root@localhost ~]#



(venv) [root@localhost ~]# jupyter notebook --allow-root
[I 12:58:03.156 NotebookApp] Serving notebooks from local directory: /root
[I 12:58:03.156 NotebookApp] The Jupyter Notebook is running at:
[I 12:58:03.156 NotebookApp] http://localhost:8888/?token=674ae2dec320c76603f5f00c7603984a5d404e2aed29e247
[I 12:58:03.156 NotebookApp] Use Control-C to stop this server and shut down all kernels (twice to skip confirmation).
[C 12:58:03.170 NotebookApp]

    To access the notebook, open this file in a browser:
        file:///root/.local/share/jupyter/runtime/nbserver-64741-open.html
    Or copy and paste one of these URLs:
        http://localhost:8888/?token=674ae2dec320c76603f5f00c7603984a5d404e2aed29e247
START /usr/bin/firefox "/root/.local/share/jupyter/runtime/nbserver-64741-open.html"
Running without a11y support!
[I 13:00:19.140 NotebookApp] 302 GET / (::1) 1.65ms
[I 13:00:19.168 NotebookApp] 302 GET /tree? (::1) 2.16ms
^C[I 13:01:22.080 NotebookApp] interrupted
Serving notebooks from local directory: /root
0 active kernels
The Jupyter Notebook is running at:
http://localhost:8888/?token=674ae2dec320c76603f5f00c7603984a5d404e2aed29e247
Shutdown this notebook server (y/[n])? y
[C 13:01:23.846 NotebookApp] Shutdown confirmed
[I 13:01:23.849 NotebookApp] Shutting down 0 kernels

## generate password 

(venv) [root@localhost ~]# jupyter notebook --generate-config
Writing default config to: /root/.jupyter/jupyter_notebook_config.py

(venv) [root@localhost ~]# vi /root/.jupyter/jupyter_notebook_config.py


## Hashed password to use for web authentication.
#
#  To generate, type in a python/IPython shell:
#
#    from notebook.auth import passwd; passwd()
#
#  The string should be of the form type:salt:hashed-password.
c.NotebookApp.password = 'sha1:e1d8afadc987:

'




(venv) [root@localhost ~]# sha1:e1d8afadc987:a04e4823aa4b34a3c281018c5900d5e78d795661
bash: sha1:e1d8afadc987:a04e4823aa4b34a3c281018c5900d5e78d795661: 명령을 찾을 수 없습니다...
(venv) [root@localhost ~]# vi /root/.jupyter/jupyter_notebook_config.py
(venv) [root@localhost ~]# jupyter notebook --allow-root --ip=0.0.0.0
[I 13:05:02.374 NotebookApp] Serving notebooks from local directory: /root
[I 13:05:02.375 NotebookApp] The Jupyter Notebook is running at:
[I 13:05:02.375 NotebookApp] http://(localhost.localdomain or 127.0.0.1):8888/
[I 13:05:02.375 NotebookApp] Use Control-C to stop this server and shut down all kernels (twice to skip confirmation).

댓글

이 블로그의 인기 게시물

[!] CDN: trunk URL couldn't be downloaded: https://cdn.cocoapods.org/CocoaPods-version.yml Response: URL using bad/illegal format or missing URL

starcraft map

Data Analysis with Superset - boardless chart