Author Topic: High MySQL Cpu Usage  (Read 25407 times)

0 Members and 1 Guest are viewing this topic.

Offline
*
High MySQL Cpu Usage
« on: July 25, 2019, 10:44:28 AM »
Hello, I Am Facing Problem With My Cwppro.

My MySql Is Using 90%+ Cpu Of My Vps. By That My Site Is Not Working Properly. I Check The Process List, MySql Usage Is High. It Is Always On Top. You Can See In Image :https://imgur.com/FmtVG6n.

Please Help Me.

Offline
*
Re: High MySQL Cpu Usage
« Reply #1 on: July 25, 2019, 06:00:14 PM »
you may want to make some edits in your mycnf file in the etc directory

This is just an example one and may need to be edited for your server.

example:  google it for changes

# This group is read both both by the client and the server
# use it for options that affect everything
#
[client-server]
[mysqld]
default-storage-engine=MyISAM
innodb_file_per_table=1
max_allowed_packet=268435456
open_files_limit=10000
innodb_buffer_pool_size=134217728
query_cache_size = 268435456
query_cache_type=1
query_cache_limit=1048576
max_connections=250
join_buffer_size=8388608
thread_cache_size=16
local-infile=1

#
# include all files from the config directory
#
!includedir /etc/my.cnf.d


Offline
*
Re: High MySQL Cpu Usage
« Reply #2 on: July 26, 2019, 07:44:38 AM »
you should check with your system admin what is causing this high cpu usage

mysqladmin pr will show running queries.
VPS & Dedicated server provider with included FREE Managed support for CWP.
http://www.studio4host.com/

*** Don't allow that your server or website is down, choose hosting provider with included expert managed support for your CWP.

Offline
*
Re: High MySQL Cpu Usage
« Reply #3 on: August 03, 2019, 05:47:25 AM »
Hey Thanks For Reply. You Mean I Have To Look For Mysql Queries Or What? I Am Not Advance, Will You Please Explain Little Bit More. I Will Be Very Thankful For Your Help.

Offline
*****
Re: High MySQL Cpu Usage
« Reply #4 on: August 09, 2019, 08:44:24 AM »
You can open a ticket https://support.centos-webpanel.com/ for checking by sysadmins
Please note: there is paid support service.
You can ask me to solve any problem with your server for some money in pm  ;)
Services Monitoring & RBL Monitoring
http://centos-webpanel.com/services-monitor
Join our Development Team and get paid !
http://centos-webpanel.com/develope-modules-for-cwp

Installation Instructions
http://centos-webpanel.com/installation-instructions
Get Fast Support Here
http://centos-webpanel.com/support-services

Offline
**
Re: High MySQL Cpu Usage
« Reply #5 on: August 15, 2019, 08:03:03 PM »
Why should users who already PAY for CWP Pro version be also paying again for help from support?

I have to think that things in CWP are intentionally cocked up in order to force users to pay for support all the time.

You really have to stop doing that all eventually you will lose your client base to other more honest panel developers like Virtualmin. That would be a real shame because cwp is a nice looking panel.
Instead of paid support for CWP Pro, just increase yearly fee a bit...I would be quite happy to pay a little extra upfront for included support...but not $8 every time a cockup you make needs rectifying!

Offline
*
Re: High MySQL Cpu Usage
« Reply #6 on: August 16, 2019, 04:31:03 AM »
Please read my reply here http://forum.centos-webpanel.com/centos-7-problems/mysql-high-cpu-all-my-websites-are-down/msg25146/#msg25146 before accusing CWP.

The my.cnf file you posted is not properly optimizing mysql.

Offline
**
Re: High MySQL Cpu Usage
« Reply #7 on: August 17, 2019, 10:33:55 AM »
 :in 3 years of running virtualmin, do you know how many times I have alterred/edited the myconf file?

Zero

And that is my point.

Having a said that, the innodb buffer size seems rather large for one site on the server.
In relation to the rest of that file...The question is, how did it end up like that in the first place if the O.P didn't change it himself?(If he did fair enough, but if not, then how did it end up messed up in the first place?)

Don't get me wrong, I love this panel...it's a beautiful interface, unfortunately I just don't trust it enough for production websites at present. One example of why is little things like this thread. Another is the built in file manager still cannot list files in alphabetical order which doesnt inspire a great degree of faith in its programmers...If you cannot program the file manager interface to list files alphabetically what else can't you do???
« Last Edit: August 17, 2019, 10:45:05 AM by adamjedgar »

Offline
*
Re: High MySQL Cpu Usage
« Reply #8 on: August 17, 2019, 11:27:40 AM »
Hi, are you using a single website or multiple websites?
You should look for two perspectives: MYSQL configurations and the codes being executed.
Try to figure out the proceses of those users who are active when your CPU is eaten up heavily. They might be trying too many queries and may not be closing the connections well in time.
Also, on your part, you can impose some limitations like number of allowed connections to MYSQL, buffer size of MYSQL Enginer like innoDB, etc. Imposing some limitations might help you out.
I hope this will help.

Offline
*
Re: High MySQL Cpu Usage
« Reply #9 on: August 17, 2019, 12:06:01 PM »
Thanks For The Reply. Is There Any Guide On Internet You Mention..............


And I Am Using Only One Website......
« Last Edit: August 17, 2019, 12:08:13 PM by thelearner2019 »

Offline
**
Re: High MySQL Cpu Usage
« Reply #10 on: September 08, 2019, 03:30:40 PM »
Why should users who already PAY for CWP Pro version be also paying again for help from support? ...

CWP PRO is different from CWP Support. We pay CWP PRO in order to support CWP. The support of CWP team is fast and great. I trust them over 3 years for One Time support tickets or monthly requests. It depends on the project.

If you have a site with load issues (as many of us face it) then a server specialist has to diagnose What is causing that. That is the service you need. CWP One time support ticket will definitely help you.
You may use our FREE SMTP Newsletter APP at https://www.emailbat.com

Offline
*
Re: High MySQL Cpu Usage
« Reply #11 on: September 12, 2019, 07:21:45 PM »
when someone makes a new account on my page, not every time I find in mysql this error, it is always the same, you can tell me what I can do, mysql falls in time out, and the page no longer works

what can i do to get rid of this error, can anyone help me?


thanks


[root@id ~]# mysqladmin pr
+------+------------------+-----------+------------------+---------+------+------------+----------------------------------------------------------------------------------                                                                    --------------------+----------+
| Id   | User             | Host      | db               | Command | Time | State      | Info                                                                                                                                                                     | Progress |
+------+------------------+-----------+------------------+---------+------+------------+----------------------------------------------------------------------------------                                                                    --------------------+----------+
| 1865 | adultwor_5u6476w | localhost | adultwor_adultwo | Query   | 165  | statistics | SELECT `u`.`id`, `u`.`username`, `u`.`userurl`, `u`.`unique_code`, `u`.`email`, `                                                                    u`.`data_nasterii`, | 0.000    |
| 1889 | adultwor_5u6476w | localhost | adultwor_adultwo | Sleep   | 144  |            |                                                                                                                                                                          | 0.000    |
| 1897 | adultwor_5u6476w | localhost | adultwor_adultwo | Sleep   | 144  |            |                                                                                                                                                                          | 0.000    |
| 1899 | adultwor_5u6476w | localhost | adultwor_adultwo | Sleep   | 143  |            |                                                                                                                                                                          | 0.000    |
| 1900 | root             | localhost |                  | Query   | 0    | init       | show processlist                                                                                                                                                         | 0.000    |
+------+------------------+-----------+------------------+---------+------+------------+----------------------------------------------------------------------------------                                                                    --------------------+----------+