pythonjupyter-notebookjupyterjupyter-labjupyterhub

Access ipynb files from shared drive using local Jupyter notebook


Currently, I have my python jupyter notebook installed in my laptop.

So, am able to see two .exe files such as jupyter-dejavue.exe and jupyter-nbconvert.exe under the below path

C:\Users\test\AppData\Roaming\Python\Python38\Scripts\

Currently, I have been asked to move all my code files to the company network shared drive which looks like below

\\ANZINDv024.abcde.com\GLOBAL_CODE_FILES

So, when I launch Jupyter notebook from my start menu (in my laptop), am not able to navigate to the shared drive in the below screen (because I don't see the shared drive folder)

enter image description here

So, I went to my shared drive and double-clicked .ipynb files but it opens in browser (with text format).

So, I chose open with and tried opening with jupyter-dejavue.exe and jupyter-nbconvert.exe but both doesn't launch the jupyter notebook.

How to launch Jupyter notebook to run .ipynb files stored in shared drive?


Solution

  • JupyterLab and Jupyter Notebook are generally restricted to a specific "root directory", which generally restricts you to one drive.

    Option 1: Directory Symbolic Link

    If you have the privileges necessary to create directory symbolic links, you can just create one of those (and access your network share through this link).

    MKLINK /D C:\Users\test\Documents\GLOBAL_CODE_FILES \\ANZINDv024.abcde.com\GLOBAL_CODE_FILES
    

    This lets you avoid reconfiguring anything and get back to work. You will generally need either temporary Administrator access (specifically SeCreateSymbolicLinkPrivilege) or you need Developer Mode turned on.

    Option 2: Different Root

    A more familiar option is to change the root directory for Jupyter (at least temporarily). An easy way to do this would be to create an alternate shortcut on your desktop. The downside is that each root will need a separate process.