5

Playing with data is a joy in Junyper/Datalab, but I do not want it to become costly.

Google recommends:

"You can minimize compute charges by stopping/restarting Cloud Datalab instances."

However, if I stop the AppEngine instance or the Compute Engine VM instance, they simply restart ...

So how to correctly stop/pause Google Cloud Datalab, so that I'm only charged for my use, not for the idle time? Is there some kind of trigger that restarts the instances?

nunofmendes
  • 3,731
  • 2
  • 32
  • 42
  • _Google Cloud Datalab_ is currently in **beta**, so the problem discribed above is likely to disappear, or the solution might change in the future. – Karel Van Roey Mar 05 '16 at 10:55
  • I have this problem too...If you delete the lab, then, I think you'll lose all your code. I think Google's documentation on the shutdown is incorrect. https://github.com/GoogleCloudPlatform/datalab/issues/742 – Mike Chirico Mar 06 '16 at 13:31
  • @MikeChirico Thx for sharing the issue link. Deleting the datalab VM instance does not necessarily result in data loss [!]: The notebooks are in a git-repo (can be synced with Github/etc), and your raw data should only **temporarily** be stored inside the VM. Better options are Google Cloud Storage, BigQuery, ... But having to delete the VM instances is cumbersome and interrupts the flow of normal usage. [!] Try this technique first with non-vital data! – Karel Van Roey Mar 06 '16 at 14:22

1 Answers1

8

Here's what I'm doing. I like keeping everything in the cloud; but, I want to resume work with minimal fuss and cost.

Save Data/Source and Delete Datalab

1. Commit changes to Your Cloud Git Repository. As long as the source changes are committed, they'll pop backup when you re-create google cloud. Keep your data in buckets gs://... or BigQuery. Commit all changed Notebooks.

Your Cloud Git Repository

2. Delete the datalab module.

https://console.cloud.google.com/projectselector/appengine/versions?moduleId=datalab enter image description here

Resuming Your Work:

When you're ready to resume your work, goto launch cloud datalab sign-in, and deploy. It will take 6 or 7 minutes. Once it's deployed, up, and running, you can go directly to your tree and resume your work. You're probably talking 10 minutes tops.

Mike Chirico
  • 3,381
  • 1
  • 23
  • 20
  • Thx @mike, I agree this 'best' solution at the moment. Although I hope Google will provide a more suitable solution in the near future. – Karel Van Roey Mar 06 '16 at 22:02