Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Glitch due to Cookie generator make_config.py while saving anything on RStudio Notebooks #2

Closed
herambgadgil opened this issue Apr 19, 2021 · 9 comments

Comments

@herambgadgil
Copy link

herambgadgil commented Apr 19, 2021

Hi Henry,

I am encountering another issue while running RStudio notebook. If we stop and start the notebook, everything that has been stored, including installed packages are lost and the session starts like a fresh RStudio install with a clean slate. This, I believe, is because of the make_config.py file which is necessary to generate pseudo cookies for RStudio to function properly in the AI-instances.

Wanted to raise the issue here and understand if there is a simple fix for it. Appreciate any help on this!

Let me know if you need any additional information.

Thanks!
Heramb

@htappen
Copy link
Owner

htappen commented Apr 19, 2021 via email

@herambgadgil
Copy link
Author

I think the user rstudio does not have privileges to any other path apart from /home/rstudio. I am getting following error if I try to save a test file to /home/jupyter

19 Apr 2021 18:35:35 [rsession-rstudio] ERROR system error 2 (No such file or directory) [path: /home/jupyter/heramb-test.R]; 
OCCURRED AT rstudio::core::Error rstudio::core::FilePath::openForWrite(std::shared_ptr<std::basic_ostream<char> >&, bool) const src/cpp/shared_core/FilePath.cpp:1482; 
LOGGED FROM: rstudio::core::Error rstudio::core::{anonymous}::openFileForWritingWithRetry(const rstudio::core::FilePath&, bool, int, std::shared_ptr<std::basic_ostream<char> >*) src/cpp/core/FileSerializer.cpp:73

I also tried to bring the python3 /root/make_config.py to the main Dockerfile from the startup.sh but got no success. This was a very amateur as I am just starting on Dockers. Apologies for any ignorance. :-)

Thanks!
Heramb

@htappen
Copy link
Owner

htappen commented Apr 19, 2021 via email

@htappen htappen closed this as completed Apr 19, 2021
@htappen
Copy link
Owner

htappen commented Apr 19, 2021

Fixed

@herambgadgil
Copy link
Author

herambgadgil commented Apr 22, 2021

Hello,

I have been trying for couple of days to get the new fix up and running on my instance. But it is not starting up. I get the following error. I have tried pushing the changes to my old container registry as well as creating a fresh container registry and the results have been the same.

image

These are the permissions that I have granted to the service-account that runs my ai-notebook.

image

The build is successful but the AI-Notebook fails. Below are the steps that I am implementing. Could you please let me know if I am missing out on anything

Step 1: Pull the latest changes from https://github.com/htappen/r-google-cloud-ai
Step 2: Initialize project to which the build needs to be pushed
Step 3: gcloud builds submit --config cloudbuild.yaml
Step 4: Create a fresh AI-Notebook with custom-image:latest

Thanks!
Heramb

@htappen
Copy link
Owner

htappen commented Apr 22, 2021

Hmm, it's working fresh for me. What happens if you do gcloud builds submit . -t gcr.io/<MY PROJECT>/<MY REPO>:latest?

I'm wondering if there's something bugged with cloudbuild.yaml

@htappen
Copy link
Owner

htappen commented Apr 22, 2021

Looking at the screenshot, it looks like there's a problem with the proxy -- either a bug with nginx config or a problem with the VM itself that prevents the proxy from turning on.

Can you please share the machine type you're using?

Also, can you please try some of the procedures listed here

What happen if you run /opt/deeplearning/bin/load_container.sh?

@htappen htappen reopened this Apr 22, 2021
@herambgadgil
Copy link
Author

Hello,

One of the engineers in my organization found that my problem was due to misalignment of the code in the startup.sh file. He presumes that might be due to windows (local machine) to unix (gcp container registry) build push.

He cloned your repo on linux box and pushed it to GCR which ran just fine! The scripts are being retained even after I restart the instance. One small thing that I am seeing now is this error message. Its not a road blocker but mentioning it for reference anyway.

image

Could we keep this issue open for another couple of days? I will run few tests and then confirm back once they are successful.

Cannot thank you enough for helping with this and for quick & prompt responses. Appreciate it very much! :-)

Thanks!
Heramb

@herambgadgil
Copy link
Author

Hi Henry,

Everything is looking good! I ran few tests and everything went well. I think we can close the issue.

Thanks a lot for all your help! Appreciate it very much :-)

Thanks!
Heramb

@htappen htappen closed this as completed Apr 26, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants