Hi all, I am running a wordpress website on Ubuntu 12.04, everything looks fine but sometimes i get out of the blue: Error establishing a database connection. When i restart the server with “reboot” in putty, everything seems fine. So it seems like the mysql server crashes or something… Can someone help me with this, it is really frustrating that i have to reboot it once or twice a day. Thank you
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!
If you think that mysql server is the problem try to enable mysql log files. Also on which package your website runs? 512mb? You probably are running low on memory. By the way you can set up a cron job to restart your server
Hi there,
You need activate the swap in your droplet.
Please, follow this:
sysctl -w vm.drop_caches=3 or echo 3 > /proc/sys/vm/drop_caches sudo swapon -a or sudo swapon + partition_of_swap Ex: sudo swapon /dev/sda2
To permanent configuration, add it into /etc/fstab vi /etc/fstab and add: /dev/sda2 swap swap defaults 0 0 Reboot the droplet and be happy!
Hmm i cannot get this to work:
root@dailyblackcoin:~# sysctl -w vm.dropcaches=3 sysctl: cannot stat /proc/sys/vm/dropcaches: No such file or directory root@dailyblackcoin:~# sysctl -w vm.dropcaches=3 or echo 3 > /proc/sys/vm/dropcaches -bash: /proc/sys/vm/dropcaches: No such file or directory root@dailyblackcoin:~# echo 3 > /proc/sys/vm/dropcaches -bash: /proc/sys/vm/dropcaches: No such file or directory
Get paid to write technical tutorials and select a tech-focused charity to receive a matching donation.
Full documentation for every DigitalOcean product.
The Wave has everything you need to know about building a business, from raising funding to marketing your product.
Stay up to date by signing up for DigitalOcean’s Infrastructure as a Newsletter.
New accounts only. By submitting your email you agree to our Privacy Policy
Scale up as you grow — whether you're running one virtual machine or ten thousand.
Sign up and get $200 in credit for your first 60 days with DigitalOcean.*
*This promotional offer applies to new accounts only.