vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   Forum and Server Management (https://vborg.vbsupport.ru/forumdisplay.php?f=232)
-   -   Vbulleting forums + Cpanel backups = Havoc (https://vborg.vbsupport.ru/showthread.php?t=236947)

Jujimufu 02-26-2010 03:22 PM

Vbulleting forums + Cpanel backups = Havoc
 
The server my forum is fine during normal hours, but when cpanel does its backup and/or scheduled updates the whole server freaks out because the forums won't give the cpu a break. :(

It's a vicious cycle where the cpu load spikes and then the server feels the need to dispatch an email every second indicating which process has a high load, and since the forums always have about 15 or more running processes it sends about 15 emails a minute, which creates even higher cpu load...blah blah.

Long story short the server will just freeze. I can't login via SSH to kill the processes or anything when the load is so high (it times out) and I have to submit a reboot ticket to my hosting company because with the load so high it'll take 2 hours for cpanel to do its backup.

Does anybody know of a script I could run that would halt httpd while cpanel does its backups/updates and just display a message to users saying "Performing scheduled backups, hang tight" or something simple - no db queries or anything. That would probably work like a charm?

Or any other solution to this problem? I'm running VB 3.8.4.

Marco van Herwaarden 02-27-2010 09:59 AM

I would start by posting an optimization request on the vBulletin.com server configuration forum.

Paul M 02-27-2010 11:09 AM

If you halt httpd then there wont be anything running to give your users a message.

snakes1100 02-27-2010 11:26 AM

I would agree with Marco, you should look at what is actually causing the server to suck up all your resources during the backup time, log into the server via ssh before the cron starts and try to find out what pid (s) are doing the damage.

You could temporarily use this as well to do what you asked. You will need to place this in a file and set a cron to run it 15 seconds before the db dump starts, you will also have to make a dupe conf file so as Paul points out, your visitors get a message as to whats going on. Set the new conf file to point at default index.html for all calls to apache on the server.

Simple & crude, should work for your needs.

Code:

#!/bin/sh
/usr/local/apache/bin/apachectl stop
sleep 30
/usr/local/apache/bin/apachectl -f /usr/local/new.conf start
sleep 128000
/usr/local/apache/bin/apachect stop
sleep 30
/usr/local/apache/bin/apachectl start


final kaoss 03-01-2010 06:59 PM

I use mysql dumper instead of cpanel for backups & restores. It's alot more secure and efficient.


All times are GMT. The time now is 05:48 PM.

Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2025, vBulletin Solutions Inc.

X vBulletin 3.8.12 by vBS Debug Information
  • Page Generation 0.01101 seconds
  • Memory Usage 1,719KB
  • Queries Executed 10 (?)
More Information
Template Usage:
  • (1)ad_footer_end
  • (1)ad_footer_start
  • (1)ad_header_end
  • (1)ad_header_logo
  • (1)ad_navbar_below
  • (1)bbcode_code_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)post_thanks_navbar_search
  • (1)printthread
  • (5)printthreadbit
  • (1)spacer_close
  • (1)spacer_open 

Phrase Groups Available:
  • global
  • postbit
  • showthread
Included Files:
  • ./printthread.php
  • ./global.php
  • ./includes/init.php
  • ./includes/class_core.php
  • ./includes/config.php
  • ./includes/functions.php
  • ./includes/class_hook.php
  • ./includes/modsystem_functions.php
  • ./includes/class_bbcode_alt.php
  • ./includes/class_bbcode.php
  • ./includes/functions_bigthree.php 

Hooks Called:
  • init_startup
  • init_startup_session_setup_start
  • init_startup_session_setup_complete
  • cache_permissions
  • fetch_threadinfo_query
  • fetch_threadinfo
  • fetch_foruminfo
  • style_fetch
  • cache_templates
  • global_start
  • parse_templates
  • global_setup_complete
  • printthread_start
  • bbcode_fetch_tags
  • bbcode_create
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • printthread_post
  • printthread_complete