Error Establishing Database Connection in every 2-3 days

My site always gives Error Establishing Database Connection in every 2-3 days

I have tried to define( 'WP_ALLOW_REPAIR' , true); method but not working
only it can be fixed by restart server
I am using
Digitalocean Ubuntu18 with 1gb Ram
please help.
my site- https://techpanga.com/

we have the same problem here, but what happened on my site is worse. an error occurs almost every 6 hours, and usually enough to restart MySQL but sometimes the server must restart too, maybe something is wrong on my website https://layarkaca21.world, need help as soon as possible. Running Ubuntu with 2gb ram VULTR, latest wordpress with ee v.3

How much space do you have on your drives?

Have you tried repairing through WPCLI?

https://developer.wordpress.org/cli/commands/db/repair/

done that
nothing is working

Same is happening to my sites. The only option which helps - restart sites.
Any suggestions how to Troubleshoot this? Logs, debug, system etc.

Did any of you figure out what is causing this or how to fix it?