Results 1 to 18 of 18
  1. #1

    High load everyday on the midnight :(

    Hi everybody

    I have a dedicated server with many websites on it. The problem is that I got very high load every day in the midnight I checked all "my" crontab and they are all fine. I even stopped them but nothing changed. My backup time is not the midnight, it's about 6 AM.

    I tried everything I could but everything still like before high load every night.

    I know you can help me and I really appreciate it.

    Thanks

  2. #2
    Join Date
    Mar 2003
    Location
    Canada
    Posts
    9,072
    Next time you notice the high load, take a look at ps aux and see what processes are running.

    How high does the load get?
    RACK911 Labs | Penetration Testing | https://www.RACK911Labs.ca

    www.HostingSecList.com - Security Notices for the Hosting Community.

  3. #3
    I will try it next time.

    I get around 32 - 48 It goes between these numbers for almost 50 minutes.

    Thanks

  4. #4
    Join Date
    Nov 2004
    Location
    Switzerland
    Posts
    1,307
    Your machine calculates every midnight all the quota of the day. So the stats (quote/BW) are updated on your control panel. If you hosts many websites on this server, it takes an hour or so to finish. Normally it doesn't hurt.
    Enterprise Consultant
    CCNP Enterprise - CCNP Security
    .:. Travels From West to East .:.

  5. #5
    Join Date
    Mar 2003
    Location
    Canada
    Posts
    9,072
    Quote Originally Posted by edelweisshosting View Post
    Your machine calculates every midnight all the quota of the day. So the stats (quote/BW) are updated on your control panel. If you hosts many websites on this server, it takes an hour or so to finish. Normally it doesn't hurt.
    That shouldn't cause a high load, unless the quota databases are corrupt.

    In which case:

    rm /home/quota.user
    rm /home/quota.group
    /scripts/fixquotas

    (File names might be different under Linux...)

  6. #6
    That makes sense. Can you please tell me how can I change the time of this calculation. Because my website go down for almost 5- 10 minutes every night.

  7. #7
    Quote Originally Posted by Pat H View Post
    That shouldn't cause a high load, unless the quota databases are corrupt.

    In which case:

    rm /home/quota.user
    rm /home/quota.group
    /scripts/fixquotas

    (File names might be different under Linux...)

    I did what you told me and I will check if it got fixed.

    Thank you soo much friends

  8. #8
    Join Date
    Nov 2004
    Location
    Switzerland
    Posts
    1,307
    What kind of control panel are you using?

    You can find its cron and change it.
    Enterprise Consultant
    CCNP Enterprise - CCNP Security
    .:. Travels From West to East .:.

  9. #9
    Join Date
    Mar 2002
    Location
    Posts
    785
    Run "top" and see whats using the most cpu
    High Quality Web Hosting from Host Ultra
    Visit us online at www.hostultra.com

  10. #10
    Join Date
    Jun 2006
    Location
    NYC / Memphis, TN
    Posts
    1,454
    Quote Originally Posted by Pat H View Post
    That shouldn't cause a high load, unless the quota databases are corrupt.

    In which case:

    rm /home/quota.user
    rm /home/quota.group
    /scripts/fixquotas

    (File names might be different under Linux...)
    You are thinking file quota. The load is coming from WEB traffic quotas. It is analyzing all of the traffic logs for the past 24/12 hours and figuring up usage and such per domain. If this server gets quite a bit of traffic then that load is valid.
    PeakVPN.Com | Complete Privacy VPN | Cloud Hosting | Guaranteed Security | 1Gbps-10Gbps Unmetered
    PeakVPN | 31 VPN Servers | 17-Years Experience | Emergency 24/7 Support
    Visit us @ PeakVPN.Com (Coming SOON) | ASN: 3915

  11. #11
    Join Date
    May 2007
    Location
    Lancashire, UK
    Posts
    113
    Does a full backup affect a high load? As it may be that..?

  12. #12
    Join Date
    Jun 2006
    Location
    NYC / Memphis, TN
    Posts
    1,454
    Quote Originally Posted by beautiful mind View Post
    Hi everybody
    My backup time is not the midnight, it's about 6 AM.
    In his original post.
    PeakVPN.Com | Complete Privacy VPN | Cloud Hosting | Guaranteed Security | 1Gbps-10Gbps Unmetered
    PeakVPN | 31 VPN Servers | 17-Years Experience | Emergency 24/7 Support
    Visit us @ PeakVPN.Com (Coming SOON) | ASN: 3915

  13. #13
    Join Date
    Mar 2003
    Location
    United States
    Posts
    3,683
    Are you running cPanel? If so, are you running automatic updates?

  14. #14
    Quote Originally Posted by edelweisshosting View Post
    What kind of control panel are you using?

    You can find its cron and change it.
    I am running WHM 11.2.0 cPanel 11.6.0-R15076.
    I have commented all of the crontab by using 'crontab -e' and the problem still like it's.


    Quote Originally Posted by CrazyTech View Post
    Are you running cPanel? If so, are you running automatic updates?
    yes I am running automatic updates and I also disabled it for few days but it's still the same


    I am still waiting for midnight to check the solution that Pat H gave me.


    Thank you all

  15. #15
    Join Date
    Mar 2003
    Location
    Canada
    Posts
    9,072
    Quote Originally Posted by beautiful mind View Post
    I am still waiting for midnight to check the solution that Pat H gave me.
    My solution shouldn't work... I misread someone else's suggestion.

    However, what you can do is run ps aux or top to see what processes are eating up the CPU when the load spikes again.

  16. #16
    Join Date
    Feb 2002
    Location
    New York, NY
    Posts
    4,618
    Quote Originally Posted by beautiful mind View Post
    I have commented all of the crontab by using 'crontab -e' and the problem still like it's.
    The "crontab -e" command will only edit your user-specific crontab. You also need to edit the /etc/crontab file, and also make sure other users don't have their own crontabs (usually somewhere like /var/cron).
    Scott Burns, President
    BQ Internet Corporation
    Remote Rsync and FTP backup solutions
    *** http://www.bqbackup.com/ ***

  17. #17
    Join Date
    Aug 2007
    Posts
    57
    tail -f /var/log/cron

    Run that prior to midnight, it will show you everything that is appended to the file (which is where cron logs all the jobs it's running).

    There's several possible things that could be kicking off at midnight, including tasks in /etc/cron.daily/, and /etc/crontab (the main system crontab file). 'slocate' (or 'mlocate') comes to mind.

    There would be two questions that come to mind. Why is it generating high load, and what can you do to make the system better able to handle the load?

    If what's running is malfunctioning, then the answer is to stop it from malfunctioning... but if it's just generating more load than the server can handle, well, that could be due to an increase in regular web traffic 6 months from now, so fixing it to handle it is a better solution.

    And do run top prior to/at midnight... watch how the numbers change, see what starts up and is using high CPU % and memory % during the entire time. Watch the numbers up top, like the swap and memory usage. Does the "%cpu" go up, or is it the "%iowait" (or %wa)? What is getting hit?

  18. #18
    Join Date
    Jun 2006
    Location
    NYC / Memphis, TN
    Posts
    1,454
    Agreed.
    Code:
    more /etc/crontab
    See if there is anything running at midnight.
    PeakVPN.Com | Complete Privacy VPN | Cloud Hosting | Guaranteed Security | 1Gbps-10Gbps Unmetered
    PeakVPN | 31 VPN Servers | 17-Years Experience | Emergency 24/7 Support
    Visit us @ PeakVPN.Com (Coming SOON) | ASN: 3915

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •