How to make web service unavailable. As I develop this application, I'd rather not be burning up CPU or access time when not logged in.

February 11, 2018 101 views
Apache Billing Ubuntu 16.04

Not getting any errors but I notice long periods of CPU usage when I am not actually online developing. The service should not be running while I am not logged in for development. How do I turn off the service so that CPU time is not used?

Running Apache2/WSGI with Python3.

1 Answer

Reducing monthly charges for a droplet that you don't need all the time using Snapshots:

Keep in mind as long as your Droplet exists, you will be billed hourly for it. BUT you can take a snapshot of your Droplet and destroy it, then re-create it again from the snapshot later when you need it.

More context from Billing and Pricing FAQ:

You can turn the Droplet off in the control panel or from the command line, but since your disk space, CPU, RAM, and IP address are all reserved while your Droplet is powered off, you'll still be charged for a Droplet when it's powered off.

If you want to save a Droplet for future use take a snapshot of it and then destroy it. You'll be able to create a new Droplet from the snapshot image anytime to bring it back online.

But snapshots also cost (less) money because they take up disk space. Snapshots are billed at $.05/GB/mo, so a 40GB snapshot costs $2/month.

This tutorial provides an explanation for how backup and snapshots work on DigitalOcean. Additionally, it includes information on how to scale, backup, and clone out servers with snapshots.
Have another answer? Share your knowledge.