Scale up as you grow — whether you're running one virtual machine or ten thousand.

From GPU-powered inference and Kubernetes to managed databases and storage, get everything you need to build, scale, and deploy intelligent applications.

This textbox defaults to using Markdown to format your answer.
You can type !ref in this text area to quickly search our full set of tutorials, documentation & marketplace offerings and insert the link!
These answers are provided by our Community. If you find them useful, show some love by clicking the heart. If you run into issues leave a comment, or add your own answer to help others.
Wow, 4GB single file reading directly in python on 8GB system? I would extend the swap space to at least 6GB (mkswap I mean) then try to ask kernel to use swap efficiently by modifying swappiness: Read it here: https://askubuntu.com/questions/103915/how-do-i-configure-swappiness
Hello,
I’ll recommend to examine the logs if the droplet us running out of memory. Usually there will be references in /var/log/messages indicating that a process was killed - oom or out of memory
What I would usually do if I’m getting that error on a Droplet with 1GB of RAM, is to add swap space, that way you would have some extra buffer in case that your RAM is fully exhausted. This step usually benefits a lot a smaller droplet.
You can follow the steps on how to do that here:
https://www.digitalocean.com/community/tutorials/how-to-add-swap-space-on-ubuntu-22-04
Regards