2

I run a CentOS vps to host a few websites with cPanel/WHM but every now and then, my websites stop working because it can't establish a connection to the mysql database.

Looking at the messages log, it shows the following:

Oct 16 04:03:07 s97-74-228-8 kernel: [54180237.755824] Out of memory in UB 88299: OOM killed process 413 (spamd child) score 0 vm:232540kB, rss:100696kB, swap:0kB Oct 16 04:03:08 s97-74-228-8 kernel: [54180237.863552] Out of memory in UB 88299: OOM killed process 1060 (spamd child) score 31 vm:231516kB, rss:99536kB, swap:0kB Oct 16 04:03:08 s97-74-228-8 kernel: [54180237.888621] Out of memory in UB 88299: OOM killed process 1061 (spamd) score 31 vm:231516kB, rss:99160kB, swap:0kB Oct 16 04:03:08 s97-74-228-8 kernel: [54180237.898954] Out of memory in UB 88299: OOM killed process 25084 (spamd) score 0 vm:231516kB, rss:100204kB, swap:0kB Oct 16 04:03:08 s97-74-228-8 kernel: [54180238.007397] Out of memory in UB 88299: OOM killed process 29642 (mysqld) score 0 vm:7849012kB, rss:62860kB, swap:0kB Oct 16 04:03:08 s97-74-228-8 kernel: [54180238.165135] Out of memory in UB 88299: OOM killed process 29450 (named) score 0 vm:1786256kB, rss:31192kB, swap:0kB Oct 16 04:03:11 s97-74-228-8 kernel: [54180241.036672] Out of memory in UB 88299: OOM killed process 1191 (mysqld) score 0 vm:1662420kB, rss:42300kB, swap:0kB Oct 16 04:03:12 s97-74-228-8 kernel: [54180242.761161] Out of memory in UB 88299: OOM killed process 1362 (mysqld) score 0 vm:807072kB, rss:40124kB, swap:0kB Oct 16 04:03:16 s97-74-228-8 kernel: [54180246.167647] Out of memory in UB 88299: OOM killed process 1434 (mysqld) score 0 vm:2188788kB, rss:43808kB, swap:0kB Oct 16 04:03:31 s97-74-228-8 kernel: [54180261.056050] Out of memory in UB 88299: OOM killed process 1562 (mysqld) score 0 vm:7980592kB, rss:59692kB, swap:0kB

After my site goes down, I ssh in but I only see at most about 446MB/3072MB used.

Not really sure what to try to be honest, any help would be greatly appreciated :)

Alex

  • 4GB in an email+anti-spam+vhost for customers+BIND+SQL server in the same box evidently is not enough. I bet you also have webmail there...It would be easier besides giving RAM temporarily to it, separate the services in more than one machine. – Rui F Ribeiro Oct 16 '16 at 13:30
0

You can create a custom my.cnf at https://tools.percona.com. I've had success in preventing OOM's by using their configuration wizard for MySQL. Be sure to allow enough RAM for the OS, CPanel and whatever else you have running on the system.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.