1
ozp11
My server gets overloaded
  • 2008/6/5 19:10

  • ozp11

  • Just popping in

  • Posts: 74

  • Since: 2003/6/2 1


Hello xoopers!

I ask for help because Iam having bad problems with my server and I dont know what to do anymore.

I have a dedicated pentium dual core 1 GB ram running XOOPS and other apps. MySQL is hosted in that server.
The server is managed by the data center company

We have this server for over 1 year and it was good until some months ago

The problem is that sometimes the server gets overloaded and apache, MySQL or the entire machine has to be rebooted

This problem got more frequent some weeks ago.

I dont know if this is a XOOPS problem or a server problem. The data center says de machine is ok. (but who knows?)

I am almost sure that the problem is XOOPS related

because XOOPS is the main app on the server (about 6000 unique visitors a day)

because that we moved the XOOPS database to another server and the problem got less frequent (but still happening)

Also the patern of the problem is not related to visitor load. It happens very fast and not related to busiest hours

Here is a log of the uptime command (yesterday)

10:45:01 up 14:51, 0 users, load average: 0.52, 0.61, 0.73
10:50:01 up 14:56, 0 users, load average: 0.63, 0.69, 0.73
10:55:01 up 15:01, 0 users, load average: 1.16, 0.70, 0.71
11:00:15 up 15:06, 0 users, load average: 22.05, 7.62, 3.18
11:06:25 up 15:12, 0 users, load average: 144.09, 70.53, 30.28
11:14:52 up 15:21, 0 users, load average: 103.97, 166.19, 104.47
11:16:38 up 15:23, 0 users, load average: 52.75, 129.90, 98.01
11:20:02 up 15:26, 0 users, load average: 6.56, 71.23, 81.21
11:25:01 up 15:31, 0 users, load average: 0.05, 26.53, 59.09
11:30:01 up 15:36, 0 users, load average: 0.03, 9.58, 42.55
11:35:01 up 15:41, 0 users, load average: 0.05, 3.60, 30.97


I wonder if this is a server bug (hardware or software), a XOOPS or XOOPS modules bug or an attack


I dont know that to do now, because we have looked on everything that we can and found nothing

My XOOPS is a bit modified and I use a lot of modules
I have protector instaled (not latest version)

My XOOPS is 2.0.16


Please give me a light on this issue

2
trabis
Re: My server gets overloaded
  • 2008/6/5 20:18

  • trabis

  • Core Developer

  • Posts: 2269

  • Since: 2006/9/1 1


It can be module related. Maybe a bad querie. What is the module most viewed in your site?

3
ozp11
Re: My server gets overloaded
  • 2008/6/5 20:55

  • ozp11

  • Just popping in

  • Posts: 74

  • Since: 2003/6/2 1


the most viewed modules are:

news 1.56
smartsections 2.13
mylinks 1.1


concursos (a module that we developed based on xdirectory that is based on mylinks)

divulgacao (a module that we developd based on c-jay contend)


PS: I noticed that somethimes that there are a lot of MySQL process being sleep and NULL running for a long time

4
trabis
Re: My server gets overloaded
  • 2008/6/5 20:59

  • trabis

  • Core Developer

  • Posts: 2269

  • Since: 2006/9/1 1


Olá de novo, se usas paginação (noticia anterior - noticia seguinte) no news então o melhor é retirar. Caso tenhas um grande número de noticias(10000 ou assim) a querie feita por esse módulo esgota-te os recursos.

De resto não posso ajudar em nada.

5
avtx30
Re: My server gets overloaded
  • 2008/6/5 21:19

  • avtx30

  • Not too shy to talk

  • Posts: 181

  • Since: 2006/10/12


I don't think it is a XOOPS (and its modules) problem.

Do you think you are being DOS?

Can you provide Apache log?

6
gediminasbyt
Re: My server gets overloaded

From your output I guess it's linux/unix server. I'd make sure there are system packages installed and monitor ps output, top, do strace on these processes etc. Logs must tell what was running during the time load jumped. If this is only mysql/php/apache server most likely one of these processes started to gobble down the server. You mentioned MySQL server was moved to different host. How about connection to that host? Any problems with DNS? Try updating from hostname to an IP address to eliminate DNS from the loop. Basically you have to find out what causes the load and then troubleshoot it.

Good luck.

7
kerkyra
Re: My server gets overloaded
  • 2008/6/6 8:24

  • kerkyra

  • Just can't stay away

  • Posts: 553

  • Since: 2005/2/14


perhaps you are being ddosed or you have a malicious or bad written script running on the server mate! You need to see what script is causing this overload from your servers log files, you could tell the hosting company's support team to identify that for you!

Can you open your webpage while this happens? If not you most likely are getting ddos attacks.
whttp://www.guidemap.gr - Beta is out...

8
ozp11
Re: My server gets overloaded
  • 2008/6/6 14:02

  • ozp11

  • Just popping in

  • Posts: 74

  • Since: 2003/6/2 1


Trabis said that if the site has 10000+ news so I should turn off the "next" "previous" links on news module (I did that now)

avtx30 - I wonder if this is a DOS attack. Protector always say that users are doing DoS and CRAWLER. But this happens since Ive installed it.
I have the appache LOG from that day.
The error log has 2 mb and the access log has 50 mb.
For what I could find, on the moment that the problem was happening there were just a few access compared on the others time of the day.

I can upload the LOG (just from 10:50 AM from 11:20 AM) for you to take a look if you want (this way the file will be much smaller)


gediminasbyt - MySQL was moved to another host within the same network. The other computer is a lot more powerfull and we did this because the problem was happening everyday and more than once a day.
After we moved the problem did not happend so often, but still happening.
We did that because the host said that we were having too much users and we should upgrade the server (I did not agree on that).
So we moved to test if this was really a issue or not
Since the server is managed by the host company we dont have much "powers" to do much.
But there is no problem on the web-mysql servers relationship.


kerkyra - the host company said that they found a probable cause for the problem
The makepdf on smartsection at least on one particular item.

I tried to generate PDF on that particular article and the server begin to overload (from less than one to 5 on load average)

All the other articles generate PDF fine, but this one dont.

PS: we use FCKeditor on all text areas and we have a trainee (student) that help users on article format (users copy paste from word and make a mess)
I wonder if this trashed html code could be the cause of this nightmare

9
tzvook
Re: My server gets overloaded
  • 2008/6/6 16:04

  • tzvook

  • Just can't stay away

  • Posts: 875

  • Since: 2003/2/1 2


@ ozp11
Try to turn on MySQL debug, go to the Mylinks module (user side) - If you have more then a few categories , you might find out that it's a mysql-query-bomb - you can use the new weblinks module instead - it can also convert the MyLinks data for you.
(MyLinks or the ols Weblinks modules are doubling your category number in the queries they pull in each block or data request - I had about 500 categories and about 1000 queries in the module or each page with module block).
Harden your module-cache and blocks-cache preferences. - it will take a lot of disk space - but will save a lot of cpu.

Ask the data center ppls to make a system-file-check - Linux or windows - if there are issues - it slows your server

Login

Who's Online

378 user(s) are online (277 user(s) are browsing Support Forums)


Members: 0


Guests: 378


more...

Donat-O-Meter

Stats
Goal: $100.00
Due Date: Nov 30
Gross Amount: $0.00
Net Balance: $0.00
Left to go: $100.00
Make donations with PayPal!

Latest GitHub Commits