my droplet: 4 GB Memory / 80 GB Disk / BLR1 - Ubuntu/ wordpress/ woo commerce I’m getting database error every 2 hour, sometime i can resolve it by restarting the droplet, and sometime i need to restore a backup funny thing that sometimes i don’t do anything and the matter is resolved by itself, but i lose my custom css…i have no idea what is the relation here! but when database error happen, i see that cpu usage is above 100% and i run mysql-tuner and got: [!!] Maximum possible memory usage: 9.9G (257.48% of installed RAM) [!!] Overall possible memory usage with other process exceeded memory
I need help in fining out the solution for cpu 100% I need help in configuration of my.cnf for my droplet: 4GB/ 80GB
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.
I would suggest a few things:
Add a caching plugin for your site so that it would make fewer requests to the database itself.
Use a CDN service like Cloudflare to make reduce the overall work that your server has to do.
Consider switching to a Managed MySQL database which is optimized for you out of the box:
Let me know if you have any questions!