Error when open Jupyter Notebook from putty - python

I'am trying to open Jupyter Notebook from Putty. I have a server where is installed Python and Jupyter. I followed all the steps from this post Remote access Jupyter notebook from Windows but it doesn't work. I got the error: This site can't be reached.
Any idea?
Thx
edit: I added a photo with the ps from putty and the error from browser. It's said:
This site can't be reached
.

The good old logout/reboot mechanisms work in this case too!
You can try closing the jupyter connection in the tunnel's connection, logout from the remote server, re-connect and try. Has worked a few times for me today.
If that doesn't work, there might be stale jupyter notebook processes on the remote server. Query for them and kill them and then logout-log back in and try.
If that still does not work, try implementing your code through ipython to check if Jupyter is working at all, even if its user interface isn't loading on your browser.

Related

How to reconnect to an existing Jupyter notebook session in VS code?

I remember I was able to reconnect to an existing Jupyter notebook session in VS code before by changing the kernel for a notebook. Now the option to reconnect to an existing session is gone, see:
How do I reconnect to an existing Jupyter notebook session in VS code?
To be clear, the sessions were never shut down. In fact, I can still see them running in the Running tab of my browser version of jupyter notebook, although clicking on them results in a 404 error:
The jupyter kernel is running on a remote server. I use a SSH session to connect back to it when I work.
Current versions: VS code is v1.68.1 and the Jupyter extension on remote machine is v2022.5.1001601848, if that helps.
If you would like to connect to an existing jupyter server can you do so by going into the command Jupyter: Specify Jupyter Server for Connections and selecting the appropriate remote server from the list. If the required server is not on that list, then you can select it.

How to use a remote Jupyter server in VSCode?

I want to use a remote Jupyter server via SSH with VSCode but I get an error whenever I try to specify the URI of any server. This also happens with local instances of Jupyter. Any server that is not started by VS Code seems to be unusable.
I am just starting a server like this
$ jupyter notebook --no-browser --port 8080
Then I enter the address in VSCode with the correct port and token
Nothing happens and I get this error, as you can see in the log below.
Command 'Python: Specify local or remote Jupyter server for connections' resulted in an error (Running the contributed command: 'python.datascience.selectjupyteruri' failed.)
Has anyone else been experiencing anything similar? I honestly have no idea how to troubleshoot this. It is worth noting that selecting the Default: VS Code will automatically start a server for you on localhost option raises the same error.
It looks like you're running a fairly old version of the Python extension, as the python.datascience.selectjupyteruri command no longer exists in the Python extension—it is now provided in a standalone Jupyter extension. Please consider upgrading to the latest version of the Python and Jupyter extensions. If that doesn't resolve the problem, please file an issue at https://github.com/microsoft/vscode-jupyter/issues and we'll be happy to help.

Jupyter Notebook: "unable to connect to Kernel"

I have just started to use virtual environment and tried to create one for Jupyter Notebook, and almost succeeded but when I tried to open a new notebook it gave the error "unable to connect to kernel or server":
Refreshing the browser, clearing the browser cache , restarting anaconda etc also did't fix the problem!
Can you tell me how to fix it?
This happens most times, try restarting anaconda it should fix the server issues, also clear browser cache.

Clicking on link in dask dashboard doesn't work ("unable to connect")

I have installed the dask extension utility for my jupyter lab sessions following the instructions here. The installation, on my university linux cluster, went through smoothly.
When I launch a client in the Jupyter notebook, the dashboard shows a link: http://127.0.0.1:8787/status. Clicking on the link should open up the dask diagnostics in a separate tab. That link, however, does not work for me and gives an "unable to connect" message. I checked with an administrator managing the cluster that port 8787 (in the link) is indeed open to regular users like myself. So, something else seems to be the problem.
Any help is much appreciated.
Are you forwarding the port 8787 to localhost on the machine you are working on, e.g. using an ssh session if you are on linux, or puTTy on windows?

How to use iPython notebook with ngrok

(Maybe better ask on superuser?)
iPython works fine if I use an ssh tunnel.
Using ngrok
iPython notebook loads I get an error about mathjax not loading.
I can enter code into cells but if I try to execute I get no result but the kernel seems to be running. Basically nothing works. I have no idea if I am doing something wrong or if this just wont work.
I am starting starting ngrok like this
./ngrok -authtoken myauthtoken 5023
and ipython notebook like
ipython notebook --no-browser --port=5023
Then connect to the iPython session at
https://mysubdomain.ngrok.com
Author of ngrok here: ipython notebooks and any other websocket connections now work properly as of ngrok 0.22 which is available at https://ngrok.com/download

Categories

Resources