'Error 502 (Bad Gateway) when accessing Jupyter Notebook from Google Deep Learning VM
I have recently quoted a Deep Learning VM from Google Cloud. DLVM provides a link to the jupyter notebook of our VM, but when I paste the link to the browser, it gave us Error 502 (Bad Gateway).
The VM consists of 100 GB of memory, 4 vCPU (26 GB Memory), and 2 Tesla T4 GPUS. I tried to stop and restart the instance several times but it did not work.
The link to Jupyter Notebook is provided by this command given by the "Get started" page:
gcloud compute instances describe --project <project-id> --zone <zone-id> <instance-id> | grep googleusercontent.com | grep datalab
The command successfully gave me a link.
However, when I paste the link to the browser, it gave me an error as followings:
Error 502 (Bad Gateway)!! 502. That’s an error. That’s all we know.
Solution 1:[1]
Restarting the Jupyterhub server will resolve this error
Solution 2:[2]
It is hard to debug the problem based on just this information.
Some things to try:
- try opening the link in the incognito mode (after clearing the cookies) and sing in with Google Account
- make sure that your user has Project Editor permissions on the GCP project
- try to create notebooks via our new UI: https://console.cloud.google.com/mlengine/notebooks/instances
let me know if any of this helps, if not please ping me directly I can assist with debugging.
Solution 3:[3]
I had the same problem and here's what I found helps. If you deploy the DLVM with specs that are same as or above the default, i.e
Machine type : 2 vCPUs with 13GB memory and 1 GPU
it won't crash. Any config less than this, gives me the same error as you. I can't get anymore info or logs on the error nor do I know if lesser configs are actually below the minimum system reqs for the DLVM but this will definitely let you use the DLVM seamlessly.
Sources
This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.
Source: Stack Overflow
Solution | Source |
---|---|
Solution 1 | Parth |
Solution 2 | Viacheslav V Kovalevskyi |
Solution 3 | Judy T Raj |