The Community Forums

Interact with an entire community of cPanel & WHM users!
  1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

CPU server overload all days in the same hour

Discussion in 'General Discussion' started by delalibera, Jan 2, 2017.

  1. delalibera

    delalibera Member

    Joined:
    Jan 6, 2014
    Messages:
    14
    Likes Received:
    0
    Trophy Points:
    1
    cPanel Access Level:
    Reseller Owner
    Please, I need help!

    My cpanel server has the following problem, every day at exactly in the same hour something is occurring on my server, the use of cpu increases greatly causing the server overload and several services like mysql, spamd, sshd appears to be down.

    This server has 4 cpus, all day the server works perfectly and the cpu usage is between 0.30 and 2.

    But every day at 7 o'clock in the morning out of nowhere the server starts to increase the use of cpu coming up to 36 where the server starts to drop and overturn the services.

    When it happens I just reboot the server that the problem is solved. But it's happening every day at exactly the same time at 7:01

    I can not figure out what's causing this, whether it's an attack or a problem on the server. If it was an attack I believe would happen at other times of the day, it seems to me to be some cronjob with problem that runs every day at 7 and generates the problem.

    Can anyone help me figure this out?

    Thank you.
     
  2. PenguinInternet

    PenguinInternet Well-Known Member
    PartnerNOC

    Joined:
    Jun 20, 2007
    Messages:
    158
    Likes Received:
    3
    Trophy Points:
    68
    Location:
    Cardiff, UK
    cPanel Access Level:
    DataCenter Provider
    Twitter:
    None of the cPanel cron jobs run at this time as standard, therefore you could check the crons for your hosted sites and see if anything is running at that time. The cron long will also be of use for this. You could also simply log into the server and run top just before this time and watch what processes are running - this should narrow it down almost immediately
     
  3. delalibera

    delalibera Member

    Joined:
    Jan 6, 2014
    Messages:
    14
    Likes Received:
    0
    Trophy Points:
    1
    cPanel Access Level:
    Reseller Owner
    What I think strange is that is occurring every day at the same hour.

    At this moment my use of cpu is
    Server Load 0.493164 (4 CPUs)

    It does not seem like an overhead on the server because otherwise it would happen during various times of the day.

    I execute the top but I do not see difference from when the server is with no overload.

    This problem also occurred on the New Year's sunday, I am sure that no one was to be accessing the server.

    If it was an attack, even restarting the server it should continue.

    Just send the reboot command to the server, that the cpu usage begins to drop until the server reboots and returns to normal.

    I have the server one year and only started this problem last month.

    I need help.
     
  4. delalibera

    delalibera Member

    Joined:
    Jan 6, 2014
    Messages:
    14
    Likes Received:
    0
    Trophy Points:
    1
    cPanel Access Level:
    Reseller Owner
    These are all the cronjobs

    0 6 * * * /usr/local/cpanel/scripts/exim_tidydb > /dev/null 2>&1
    30 5 * * * /usr/local/cpanel/scripts/optimize_eximstats > /dev/null 2>&1
    19 21 * * * /usr/local/cpanel/scripts/upcp --cron
    0 1 * * * /usr/local/cpanel/scripts/cpbackup
    0 2 * * * /usr/local/cpanel/bin/backup
    35 * * * * /usr/bin/test -x /usr/local/cpanel/bin/tail-check && /usr/local/cpanel/bin/tail-check
    45 */4 * * * /usr/bin/test -x /usr/local/cpanel/scripts/update_mailman_cache && /usr/local/cpanel/scripts/update_mailman_cache
    30 */4 * * * /usr/bin/test -x /usr/local/cpanel/scripts/update_db_cache && /usr/local/cpanel/scripts/update_db_cache
    30 */2 * * * /usr/local/cpanel/bin/mysqluserstore >/dev/null 2>&1
    15 */2 * * * /usr/local/cpanel/bin/dbindex >/dev/null 2>&1
    15 */6 * * * /usr/local/cpanel/scripts/autorepair recoverymgmt >/dev/null 2>&1
    */5 * * * * /usr/local/cpanel/scripts/dcpumon-wrapper >/dev/null 2>&1
    44 21 * * * /usr/local/cpanel/whostmgr/docroot/cgi/cpaddons_report.pl --notify
    4,19,34,49 * * * * /usr/local/cpanel/whostmgr/bin/dnsqueue > /dev/null 2>&1

    I now ran all the cronjobs and do not generated server overload.
     
  5. PenguinInternet

    PenguinInternet Well-Known Member
    PartnerNOC

    Joined:
    Jun 20, 2007
    Messages:
    158
    Likes Received:
    3
    Trophy Points:
    68
    Location:
    Cardiff, UK
    cPanel Access Level:
    DataCenter Provider
    Twitter:
    Given the time of day it happens (it not an unreasonable hour to monitor it manually) and the fact it is daily then I'd recommend actually watching it as it happens - just log in before 7am and watch top to see what processes are running and consuming resources as that should narrow it straight down.
     
  6. cPanelMichael

    cPanelMichael Forums Analyst
    Staff Member

    Joined:
    Apr 11, 2011
    Messages:
    37,094
    Likes Received:
    1,288
    Trophy Points:
    363
    cPanel Access Level:
    Root Administrator
Loading...

Share This Page