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.

Server Load Very High and alot of connections to httpd

Discussion in 'General Discussion' started by Homie2, Nov 24, 2005.

  1. Homie2

    Homie2 Well-Known Member

    Joined:
    Dec 16, 2004
    Messages:
    91
    Likes Received:
    0
    Trophy Points:
    6
    Hi,

    last two weeks i've been getting high server load and i don't know why. I noticed i have around 70 httpd dsl connections on my server and would like if someone could help me fix this

    Ss Nov19 0:00 xinetd -stayalive -pidfile /var/run/xinetd.pid
    root 3768 0.0 0.1 11436 1640 ? S Nov19 0:00 chkservd
    mailnull 3795 0.0 0.0 9160 988 ? SNs Nov19 0:00 /usr/sbin/exim -bd -q60m
    mailnull 3799 0.0 0.0 7828 820 ? SNs Nov19 0:00 /usr/sbin/exim -tls-on-connect -bd -oX 465
    root 3811 0.0 0.0 3824 996 ? S Nov19 0:06 antirelayd
    root 3830 0.0 0.1 24260 2044 ? SNs Nov19 0:01 /usr/bin/spamd -d --allowed-ips=127.0.0.1 --pidfile=/var/run/
    root 3851 0.0 0.0 4860 644 ? Ss Nov19 0:00 crond
    root 3993 0.0 1.0 17172 11148 ? SN Nov19 0:30 cpanellogd - sleeping for logs
    nobody 4011 0.0 0.0 4068 920 ? S Nov19 0:00 entropychat
    nobody 4015 0.0 0.0 1672 356 ? SN Nov19 0:00 /usr/local/cpanel/bin/startmelange
    root 4024 0.0 0.3 10008 3280 ? SN Nov19 0:04 cppop - accepting on port 110
    dbus 4042 0.0 0.0 12768 556 ? Ssl Nov19 0:00 dbus-daemon-1 --system
    root 4056 0.0 0.1 7168 1516 ? Ss Nov19 0:00 hald
    root 4081 0.0 0.0 1476 400 ? Ss Nov19 0:00 /usr/sbin/portsentry -tcp
    root 4122 0.0 0.0 4284 504 ? S Nov19 0:00 /bin/sh /usr/bin/mysqld_safe --datadir=/var/lib/mysql --pid-f
    mysql 4163 0.0 0.7 37444 7932 ? SN Nov19 0:02 /usr/sbin/mysqld --basedir=/ --datadir=/var/lib/mysql --user=
    mysql 4204 0.0 0.7 37444 7932 ? SN Nov19 0:02 /usr/sbin/mysqld --basedir=/ --datadir=/var/lib/mysql --user=
    mysql 4205 0.0 0.7 37444 7932 ? SN Nov19 0:00 /usr/sbin/mysqld --basedir=/ --datadir=/var/lib/mysql --user=
    mysql 4206 0.0 0.7 37444 7932 ? SN Nov19 0:00 /usr/sbin/mysqld --basedir=/ --datadir=/var/lib/mysql --user=
    mysql 4207 0.0 0.7 37444 7932 ? SN Nov19 0:00 /usr/sbin/mysqld --basedir=/ --datadir=/var/lib/mysql --user=
    mysql 4208 0.0 0.7 37444 7932 ? SN Nov19 0:00 /usr/sbin/mysqld --basedir=/ --datadir=/var/lib/mysql --user=
    mysql 4209 0.0 0.7 37444 7932 ? SN Nov19 0:01 /usr/sbin/mysqld --basedir=/ --datadir=/var/lib/mysql --user=
    mysql 4210 0.0 0.7 37444 7932 ? SN Nov19 0:01 /usr/sbin/mysqld --basedir=/ --datadir=/var/lib/mysql --user=
    mysql 4211 0.0 0.7 37444 7932 ? SN Nov19 0:00 /usr/sbin/mysqld --basedir=/ --datadir=/var/lib/mysql --user=
    mysql 4212 0.0 0.7 37444 7932 ? SN Nov19 0:00 /usr/sbin/mysqld --basedir=/ --datadir=/var/lib/mysql --user=

    named 4949 0.0 0.2 38680 2644 ? Ssl Nov19 0:06 /usr/sbin/named -u named
    root 3511 0.0 0.1 7044 1240 ? SNs Nov19 0:00 pure-ftpd (SERVER)
    root 3514 0.0 0.0 7300 548 ? SN Nov19 0:00 /usr/sbin/pure-authd -s /var/run/ftpd.sock -r /usr/sbin/purea
    cpanel 25144 0.0 0.1 35120 1580 ? SNs Nov19 0:02 /usr/bin/stunnel-4.04local /usr/local/cpanel/etc/stunnel/defa
    root 25167 0.0 0.2 11532 2900 ? SN Nov19 0:01 cpsrvd - waiting for connections
    root 31952 0.0 0.1 9672 1184 ? Ss 04:02 0:00 cupsd
    root 11061 0.0 0.8 20536 8788 ? SNs 12:51 0:02 /usr/local/apache/bin/httpd -DSSL
    nobody 13167 0.2 1.1 22984 11792 ? SN 16:20 0:02 /usr/local/apache/bin/httpd -DSSL
    nobody 13168 0.3 1.2 24124 13028 ? SN 16:20 0:04 /usr/local/apache/bin/httpd -DSSL
    nobody 13169 0.4 1.2 24136 12864 ? SN 16:20 0:04 /usr/local/apache/bin/httpd -DSSL
    nobody 13170 0.4 1.2 23620 12492 ? SN 16:20 0:05 /usr/local/apache/bin/httpd -DSSL
    nobody 13171 0.2 1.2 24320 12952 ? SN 16:20 0:03 /usr/local/apache/bin/httpd -DSSL
    nobody 13177 0.3 1.0 22336 11088 ? SN 16:20 0:04 /usr/local/apache/bin/httpd -DSSL
    nobody 13178 0.3 1.3 25616 14336 ? SN 16:20 0:03 /usr/local/apache/bin/httpd -DSSL
    nobody 13179 0.3 1.5 26576 15424 ? SN 16:20 0:04 /usr/local/apache/bin/httpd -DSSL
    nobody 13182 0.4 1.4 26212 15100 ? SN 16:20 0:05 /usr/local/apache/bin/httpd -DSSL
    nobody 13183 0.6 1.3 24976 13732 ? SN 16:20 0:07 /usr/local/apache/bin/httpd -DSSL
    nobody 13184 0.2 1.1 22752 11364 ? SN 16:20 0:02 /usr/local/apache/bin/httpd -DSSL
    nobody 13185 0.5 1.2 24268 12868 ? SN 16:20 0:06 /usr/local/apache/bin/httpd -DSSL
    nobody 13188 0.5 1.2 24572 13256 ? SN 16:20 0:06 /usr/local/apache/bin/httpd -DSSL
    nobody 13189 0.4 1.4 26512 15360 ? SN 16:20 0:05 /usr/local/apache/bin/httpd -DSSL
    nobody 13190 0.3 1.3 24724 13464 ? SN 16:20 0:04 /usr/local/apache/bin/httpd -DSSL
    nobody 13191 0.3 1.5 27112 15844 ? SN 16:20 0:03 /usr/local/apache/bin/httpd -DSSL
    nobody 13192 0.4 1.2 24504 13240 ? SN 16:20 0:04 /usr/local/apache/bin/httpd -DSSL
    nobody 13193 0.6 1.3 25124 13868 ? SN 16:20 0:07 /usr/local/apache/bin/httpd -DSSL
    nobody 13194 0.4 1.1 23060 11912 ? SN 16:20 0:05 /usr/local/apache/bin/httpd -DSSL
    nobody 13195 0.3 1.0 22308 11128 ? SN 16:20 0:04 /usr/local/apache/bin/httpd -DSSL
    nobody 13198 0.4 1.5 27104 15956 ? SN 16:20 0:04 /usr/local/apache/bin/httpd -DSSL
    nobody 13199 0.2 1.1 22504 11324 ? SN 16:20 0:02 /usr/local/apache/bin/httpd -DSSL
    nobody 13201 0.3 1.2 24300 12940 ? SN 16:20 0:03 /usr/local/apache/bin/httpd -DSSL
    nobody 13202 0.3 1.0 22320 11140 ? SN 16:20 0:04 /usr/local/apache/bin/httpd -DSSL
    nobody 13206 0.7 1.5 27216 15968 ? SN 16:20 0:08 /usr/local/apache/bin/httpd -DSSL
    root 13521 0.0 0.2 8120 2348 ? S<s 16:23 0:00 sshd: root@pts/0
    root 13523 0.0 0.1 6072 1436 pts/0 S<s 16:23 0:00 -bash
    nobody 10198 0.4 1.6 28020 16868 ? SN 16:26 0:03 /usr/local/apache/bin/httpd -DSSL
    nobody 10442 0.3 1.2 24212 12812 ? SN 16:27 0:02 /usr/local/apache/bin/httpd -DSSL
    nobody 11093 0.4 1.5 26600 15444 ? SN 16:30 0:02 /usr/local/apache/bin/httpd -DSSL
    nobody 11220 0.9 1.5 26616 15460 ? SN 16:31 0:05 /usr/local/apache/bin/httpd -DSSL
    nobody 11221 0.4 1.2 24396 13080 ? SN 16:31 0:02 /usr/local/apache/bin/httpd -DSSL
    nobody 11222 0.5 1.2 23656 12516 ? SN 16:31 0:02 /usr/local/apache/bin/httpd -DSSL
    nobody 11426 1.2 1.0 22448 11244 ? SN 16:32 0:05 /usr/local/apache/bin/httpd -DSSL
    benyous 11450 0.0 0.1 7152 1588 ? SN 16:32 0:00 pure-ftpd (UPLOAD)
    nobody 11455 0.3 1.0 22116 10884 ? SN 16:32 0:01 /usr/local/apache/bin/httpd -DSSL
    nobody 11505 0.3 1.5 27308 16140 ? SN 16:33 0:01 /usr/local/apache/bin/httpd -DSSL
    nobody 11514 0.1 1.0 22340 11084 ? SN 16:33 0:00 /usr/local/apache/bin/httpd -DSSL
    nobody 11516 0.3 1.2 24544 13204 ? SN 16:33 0:01 /usr/local/apache/bin/httpd -DSSL
    nobody 12333 0.2 0.8 20808 9216 ? SN 16:38 0:00 /usr/local/apache/bin/httpd -DSSL
    nobody 12343 0.1 0.8 20808 9164 ? SN 16:38 0:00 /usr/local/apache/bin/httpd -DSSL
    nobody 12354 0.1 0.8 20676 9136 ? SN 16:38 0:00 /usr/local/apache/bin/httpd -DSSL
    nobody 12357 0.1 0.8 20808 9200 ? SN 16:38 0:00 /usr/local/apache/bin/httpd -DSSL
    nobody 12358 0.1 0.9 20808 9248 ? SN 16:38 0:00 /usr/local/apache/bin/httpd -DSSL
    nobody 12359 0.1 0.8 20808 9232 ? SN 16:39 0:00 /usr/local/apache/bin/httpd -DSSL
    nobody 12360 0.1 0.8 20808 9160 ? SN 16:39 0:00 /usr/local/apache/bin/httpd -DSSL
    nobody 12362 0.2 1.0 22020 10764 ? SN 16:39 0:00 /usr/local/apache/bin/httpd -DSSL
    nobody 12363 0.1 0.8 20808 9232 ? SN 16:39 0:00 /usr/local/apache/bin/httpd -DSSL
    nobody 12364 0.1 0.8 20808 9208 ? SN 16:39 0:00 /usr/local/apache/bin/httpd -DSSL
    nobody 12365 1.0 1.3 24908 13748 ? SN 16:39 0:00 /usr/local/apache/bin/httpd -DSSL
    nobody 12367 0.5 0.9 20948 9460 ? SN 16:39 0:00 /usr/local/apache/bin/httpd -DSSL
    nobody 12368 0.1 0.8 20672 9140 ? SN 16:39 0:00 /usr/local/apache/bin/httpd -DSSL
    nobody 12369 0.1 0.8 20676 9152 ? SN 16:39 0:00 /usr/local/apache/bin/httpd -DSSL
    nobody 12370 0.9 1.2 24232 12796 ? SN 16:39 0:00 /usr/local/apache/bin/httpd -DSSL
    nobody 12371 0.2 1.0 21572 10356 ? SN 16:39 0:00 /usr/local/apache/bin/httpd -DSSL
    nobody 12372 1.3 1.2 24184 12812 ? SN 16:39 0:00 /usr/local/apache/bin/httpd -DSSL
    nobody 12373 0.7 0.9 21220 9936 ? SN 16:39 0:00 /usr/local/apache/bin/httpd -DSSL
    nobody 12374 0.1 0.8 20672 9140 ? SN 16:39 0:00 /usr/local/apache/bin/httpd -DSSL
    nobody 12377 0.5 1.3 24560 13400 ? SN 16:39 0:00 /usr/local/apache/bin/httpd -DSSL
    nobody 12378 0.0 0.8 20672 9140 ? SN 16:39 0:00 /usr/local/apache/bin/httpd -DSSL
    nobody 12385 0.6 0.0 0 0 ? ZN 16:39 0:00 [httpd] <defunct>
    nobody 12406 0.6 0.8 20812 9180 ? SN 16:39 0:00 /usr/local/apache/bin/httpd -DSSL
    fanwire 12434 0.0 0.4 10004 4668 ? RN 16:40 0:00 cppop - serving IP Now SHOWN! - UPDATE - dahlia@ftyytryr.com
    root 12435 0.0 0.0 2324 756 pts/0 R<+ 16:40 0:00 ps -aux
    root@ [~]#
     
  2. DigitalSurgeon

    DigitalSurgeon Well-Known Member

    Joined:
    Aug 13, 2005
    Messages:
    134
    Likes Received:
    0
    Trophy Points:
    16
    Usually the services that cause heavy load on the server are HTTP,MySQL,Exim.So if you see that the server is under high load then you can temporarily stop the services and then give a minute and then start them.
     
  3. Homie2

    Homie2 Well-Known Member

    Joined:
    Dec 16, 2004
    Messages:
    91
    Likes Received:
    0
    Trophy Points:
    6
    I've been doing that and it just goes backup.

    How do i stop and start mysql and exim? I already know how to do httpd
     
  4. DigitalSurgeon

    DigitalSurgeon Well-Known Member

    Joined:
    Aug 13, 2005
    Messages:
    134
    Likes Received:
    0
    Trophy Points:
    16
    service exim stop/start
    service mysql stop/start
     
  5. Homie2

    Homie2 Well-Known Member

    Joined:
    Dec 16, 2004
    Messages:
    91
    Likes Received:
    0
    Trophy Points:
    6
    Is there any other ways to get rid of all those connections?
     
  6. DigitalSurgeon

    DigitalSurgeon Well-Known Member

    Joined:
    Aug 13, 2005
    Messages:
    134
    Likes Received:
    0
    Trophy Points:
    16
    The best way is continuous monitoring of logs and the Apache status and try to figure out that which user is causing this much load on the server.You can then temporarily suspend that account in order to stabilize the server.
     
  7. Homie2

    Homie2 Well-Known Member

    Joined:
    Dec 16, 2004
    Messages:
    91
    Likes Received:
    0
    Trophy Points:
    6
    well where do i get the logs?
     
  8. DigitalSurgeon

    DigitalSurgeon Well-Known Member

    Joined:
    Aug 13, 2005
    Messages:
    134
    Likes Received:
    0
    Trophy Points:
    16
    You can check Apache status from WHM >> Server Status >> Apache Status and the apache access_log is at /usr/local/apachelogs/access_log.Read man pages for "top" command as it shows the real time processes consuming the CPU usage.
     
  9. aby

    aby Well-Known Member

    Joined:
    May 31, 2005
    Messages:
    638
    Likes Received:
    0
    Trophy Points:
    16
    Location:
    India
    You can check the apache status from WHM. Also you can find the apache logs
    /usr/local/apache/logs/

    you can tail the access log and see if a particular domain is under attack. But if you are unable to find out yourself, i 'd suggest you getting somebody to have a look into it and see what actually is the issue.
     
  10. Homie2

    Homie2 Well-Known Member

    Joined:
    Dec 16, 2004
    Messages:
    91
    Likes Received:
    0
    Trophy Points:
    6
    OK i there are tons of diffrent logs in there. There is one called access log is that the one i need to look at?
     
  11. aby

    aby Well-Known Member

    Joined:
    May 31, 2005
    Messages:
    638
    Likes Received:
    0
    Trophy Points:
    16
    Location:
    India
    That will give you some idea.. about the apache access
     
  12. Homie2

    Homie2 Well-Known Member

    Joined:
    Dec 16, 2004
    Messages:
    91
    Likes Received:
    0
    Trophy Points:
    6
    I'm looking at it and i see this like 50 times in a row with the same ip


    IP NOT SHOWN - - [19/Oct/2005:23:00:34 -0400] "GET /forum/viewtopic.php?t=612&start=0&sid=769484d2c287c9e78fe2f865475b896d HTTP/1.0" 404 279
     
  13. DigitalSurgeon

    DigitalSurgeon Well-Known Member

    Joined:
    Aug 13, 2005
    Messages:
    134
    Likes Received:
    0
    Trophy Points:
    16
    This is normal becasue it is just showing that the page that is viewed.
     
  14. DigitalSurgeon

    DigitalSurgeon Well-Known Member

    Joined:
    Aug 13, 2005
    Messages:
    134
    Likes Received:
    0
    Trophy Points:
    16
    Go to WHM >> Server Status >> CPU/Memory/MySQL Usage, If any site is consuming getting a large number of HTTP hits then it will be marked red and it will also show you the site name or other processes that is causing the load.
     
  15. timdorr

    timdorr Well-Known Member
    PartnerNOC

    Joined:
    Jul 9, 2002
    Messages:
    93
    Likes Received:
    0
    Trophy Points:
    6
    Location:
    Atlanta, GA
    Block their IP address from the command line:

    route add -host IPADDRESS reject

    That will null-route it and keep them from connecting. You can remove the block later on with:

    route del -host IPADDRESS reject
     
Loading...

Share This Page