Apache bremst - bzw. frisst sich voll

  • Thread starter Thread starter Deleted member 856
  • Start date Start date
D

Deleted member 856

Guest
Servus :)

Ich hab nen VServer bei Vanager - wo der apache ziemlich langsam is. Umso länger das Ding läuft, umso mehr Ram brauche ich auch.
Zeige mir den Ram mit vzfree an, hat mir mein Provider geschickt.
Society hier ausm Board hat sich das ganze auch schon angeschaut, er meint es liegt einfach daran, dass es ein Vserver ist... Einen dedizierten kann ich mir jedoch nicht leisten.

Also stoppe ich das Ding:


Code:
VPS Speichernutzung:
Momentan genutzt:       165.238 MB
Zugesichert:            196 MB
Maximal nutzbar:        588 MB


Wenn ich den apache dann starte

Code:
VPS Speichernutzung:
Momentan genutzt:       187.457 MB
Zugesichert:            196 MB
Maximal nutzbar:        588 MB

und das Momentan genutzt geht von Minute zu Minute hoch....
Es is echt ätzend, und auf dem Vserver läuft nur apache,psybnc und teamspeak.

ps aux:

Code:
USER       PID %CPU %MEM   VSZ  RSS TTY      STAT START   TIME COMMAND
root         1  0.0  0.0  1396  472 ?        Ss   Jul03   5:25 ini
root     10640  0.0  0.0  1456  564 ?        Ss   Jul03   1:36 /sbin/syslogd
root     10643  0.0  0.0  1400  380 ?        Ss   Jul03   0:00 /sbin/klogd
nobody   23266  0.0  0.0  1608  588 ?        Ss   Jul03   0:00 /usr/sbin/oidentd
root     27008  0.0  0.0  2868 1068 ?        Ss   Jul03   2:52 /usr/lib/postfix/
root     28321  0.0  0.0  3652  864 ?        Ss   Jul03   0:14 /usr/sbin/sshd
daemon   28514  0.0  0.0  1396  508 ?        Ss   Jul03   1:20 /usr/sbin/uptimed
nobody   29153  0.0  0.0  3968  804 ?        Ss   Jul03   3:40 proftpd: (accepti
root     29248  0.0  0.0  1664  704 ?        Ss   Jul03   0:44 /usr/sbin/cron
irc       8994  0.0  0.0  6016 3084 ?        S    Jul03  66:09 ./psybnc
irc      25127  0.0  0.0 29820 2048 ?        SN   Jul06   1:02 ./server_linux -P
irc      31648  0.0  0.0 29820 2052 ?        S    Jul06   1:40 ./server_linux -P
irc       5888  0.0  0.0 29820 2052 ?        S    Jul06 111:37 ./server_linux -P
irc       5922  0.0  0.0 29820 2052 ?        S    Jul06 112:26 ./server_linux -P
irc       7362  0.0  0.0 29820 2052 ?        S    Jul06   8:18 ./server_linux -P
irc        356  0.0  0.0 29820 2052 ?        S    Jul06   2:42 ./server_linux -P
irc        388  0.0  0.0 29820 2052 ?        S    Jul06  78:21 ./server_linux -P
irc        418  0.0  0.0 29820 2052 ?        S    Jul06  78:44 ./server_linux -P
irc        448  0.0  0.0 29820 2052 ?        S    Jul06   8:51 ./server_linux -P
irc       5731  0.0  0.0  2932  988 ?        S    Jul06   7:47 ./ventrilo_srv
irc      31265  0.1  0.0 29820 2052 ?        S    Jul15 122:50 ./server_linux -P
irc      31362  0.1  0.0 29820 2052 ?        S    Jul15 160:34 ./server_linux -P
irc      31909  0.0  0.0 29820 2052 ?        S    Jul15  61:42 ./server_linux -P
clamav    5952  0.0  0.0  4420  888 ?        Ss   Aug21   0:02 /usr/bin/freshcla
clamav   18593  0.0  0.0 34064 1956 ?        Ss   Aug21   8:18 /usr/sbin/clamd
clamav   15073  0.0  0.0 34064 1960 ?        S    Aug21   0:46 /usr/sbin/clamd
root     27489  0.0  0.0  6848  964 ?        Ss   Sep13   0:00 /usr/sbin/saslaut
root     27520  0.0  0.0  6848  964 ?        S    Sep13   0:00 /usr/sbin/saslaut
root     27552  0.0  0.0  6848  964 ?        S    Sep13   0:00 /usr/sbin/saslaut
root     27585  0.0  0.0  6848  964 ?        S    Sep13   0:00 /usr/sbin/saslaut
root     27616  0.0  0.0  6732  836 ?        S    Sep13   0:00 /usr/sbin/saslaut
irc      26881  0.0  0.0 17372  632 ?        S    Sep15   1:16 ./sc_serv
irc      27042  0.0  0.0 17372  632 ?        S    Sep15   0:12 ./sc_serv
irc      27073  0.2  0.0 17372  632 ?        S    Sep15  51:00 ./sc_serv
irc      27108  0.1  0.0 17372  632 ?        S    Sep15  25:25 ./sc_serv
irc      27136  0.2  0.0 17372  632 ?        S    Sep15  51:30 ./sc_serv
root     13714  0.0  0.0  1432  480 ?        Ss   Sep25   0:00 /usr/sbin/inetd
root     15584  0.0  0.0  3532 1000 ?        S    Sep25   0:00 /bin/sh /usr/bin/
mysql    27010  0.0  0.2 80708 17408 ?       S    Sep25   0:00 /usr/sbin/mysqld
root     27041  0.0  0.0  2568  480 ?        S    Sep25   0:00 logger -p daemon.
mysql     4066  0.0  0.2 80708 17408 ?       S    Sep25   0:02 /usr/sbin/mysqld
mysql     4128  0.0  0.2 80708 17408 ?       S    Sep25   0:00 /usr/sbin/mysqld
mysql     4160  0.0  0.2 80708 17408 ?       S    Sep25   0:00 /usr/sbin/mysqld
mysql     4230  0.0  0.2 80708 17408 ?       S    Sep25   0:00 /usr/sbin/mysqld
mysql     4257  0.0  0.2 80708 17408 ?       S    Sep25   0:00 /usr/sbin/mysqld
mysql    32325  0.0  0.2 80708 17408 ?       S    Sep25   0:27 /usr/sbin/mysqld
mysql    32358  0.0  0.2 80708 17408 ?       S    Sep25   0:22 /usr/sbin/mysqld
mysql      928  0.0  0.2 80708 17408 ?       S    Sep25   0:00 /usr/sbin/mysqld
mysql     4800  0.0  0.2 80708 17408 ?       S    Sep25   0:00 /usr/sbin/mysqld
postfix    484  0.0  0.0  2916 1152 ?        S    Sep25   0:00 qmgr -l -t fifo -
postfix  10853  0.0  0.0  2884 1168 ?        S    16:42   0:00 pickup -l -t fifo
root      7395  0.0  0.0  6412 1904 ?        Ss   17:15   0:00 sshd: root@pts/0
root     25667  0.0  0.0  6412 1904 ?        S    17:15   0:00 sshd: root@pts/0
root     15841  0.0  0.0  3840 1744 pts/0    Ss   17:15   0:00 -bash
root     23713  0.1  0.1 19800 9160 pts/0    S    18:02   0:00 /usr/sbin/apache
root     23748  0.0  0.0  4404 1452 pts/0    S    18:02   0:00 /usr/bin/perl /ro
www-data 23780  0.0  0.1 20068 9684 pts/0    S    18:02   0:00 /usr/sbin/apache
www-data 23810  0.0  0.1 20068 9684 pts/0    S    18:02   0:00 /usr/sbin/apache
www-data 23843  0.0  0.1 20068 9684 pts/0    S    18:02   0:00 /usr/sbin/apache
www-data 24224  0.3  0.2 26732 16392 pts/0   R    18:02   0:00 /usr/sbin/apache
www-data 24391  0.0  0.1 19800 9168 pts/0    S    18:02   0:00 /usr/sbin/apache
www-data 24419  0.0  0.1 19800 9168 pts/0    S    18:02   0:00 /usr/sbin/apache
mysql     7522  0.0  0.2 80708 17408 ?       S    18:03   0:00 /usr/sbin/mysqld
root      7621  0.0  0.0  2384  856 pts/0    R+   18:03   0:00 ps aux


Apache in Version 1.3 und MYSQL sowie PHP laufen in Version5

Grüße
 
Was läuft denn auf dem Apache?
Und für mich sieht es so aus, als würde nicht der Apache, sondern der MySQL den meisten Speicher benötigen.
 
Was läuft denn auf dem Apache?
Und für mich sieht es so aus, als würde nicht der Apache, sondern der MySQL den meisten Speicher benötigen.

PHP5 läuft da - und nen paar Webseiten mit... Gallery2 zB. Confixx is noch drauf.
im und wie behebe ich das nun?

Code:
root:~> vzfree
VPS Speichernutzung:
Momentan genutzt:       344.125 MB
Zugesichert:            196 MB
Maximal nutzbar:        588 MB

so siehts zB atm aus - das is doch nich zum aushalten
 
Last edited by a moderator:
so siehts zB atm aus - das is doch nich zum aushalten
Dann zeig doch nochmal den Output von "ps faxv" zu dem Zeitpunkt, zu dem es nicht mehr auszuhalten ist.
Und eine Status-Page (Extended Status) vom Apache wäre auch nicht schlecht.
 
Code:
root:~> ps faxv
  PID TTY      STAT   TIME  MAJFL   TRS   DRS  RSS %MEM COMMAND
    1 ?        Ss     5:27    349    26  1369  472  0.0 ini
10640 ?        Ss     1:37    674    24  1431  600  0.0 /sbin/syslogd
10643 ?        Ss     0:00     29    18  1381  380  0.0 /sbin/klogd
23266 ?        Ss     0:00    453    43  1564  544  0.0 /usr/sbin/oidentd -mf -P
27008 ?        Ss     2:54    419    22  2845 1068  0.0 /usr/lib/postfix/master
  484 ?        S      0:01    351    37  2878 1156  0.0  \_ qmgr -l -t fifo -u
 6914 ?        S      0:00    292     6  2869 1160  0.0  \_ pickup -l -t fifo -u
28321 ?        Ss     0:15   2900   274  3377  868  0.0 /usr/sbin/sshd
 8421 ?        Ss     0:00    209   274  6137 1904  0.0  \_ sshd: root@pts/2
23714 ?        S      0:00      0   274  6137 1904  0.0      \_ sshd: root@pts/2
24609 pts/2    Ss     0:00    359   588  2611 1680  0.0      \_ -bash
 8450 pts/2    R+     0:00    162    61  2122  704  0.0          \_ ps faxv
28514 ?        Ss     1:21     40     9  1386  508  0.0 /usr/sbin/uptimed
29153 ?        Ss     3:43    672   524  3443  780  0.0 proftpd: (accepting conn
29248 ?        Ss     0:44    111    24  1639  700  0.0 /usr/sbin/cron
25127 ?        SN     1:03     90   825 28994 1340  0.0 ./server_linux -PID=tsse
31648 ?        S      1:42      0   825 28994 1344  0.0  \_ ./server_linux -PID=
 5888 ?        S    113:11     57   825 28994 1344  0.0      \_ ./server_linux -
 5922 ?        S    113:59      5   825 28994 1344  0.0      \_ ./server_linux -
 7362 ?        S      8:28      8   825 28994 1344  0.0      \_ ./server_linux -
  356 ?        S      2:45      0   825 28994 1344  0.0      \_ ./server_linux -
  388 ?        S     79:54     29   825 28994 1344  0.0      \_ ./server_linux -
  418 ?        S     80:17      4   825 28994 1344  0.0      \_ ./server_linux -
  448 ?        S      9:00    254   825 28994 1344  0.0      \_ ./server_linux -
31265 ?        S    124:28  10174   825 28994 1344  0.0      \_ ./server_linux -
31362 ?        S    162:16    210   825 28994 1344  0.0      \_ ./server_linux -
31909 ?        S     62:00   1070   825 28994 1344  0.0      \_ ./server_linux -
 5731 ?        S      8:04   2849   168  2763  720  0.0 ./ventrilo_srv
 5952 ?        Ss     0:02   2535    35  4384  892  0.0 /usr/bin/freshclam -d --
18593 ?        Ss     8:22  45801    39 34028  732  0.0 /usr/sbin/clamd
15073 ?        S      0:47     19    39 34028  736  0.0  \_ /usr/sbin/clamd
27489 ?        Ss     0:00    435    68  6779  964  0.0 /usr/sbin/saslauthd -a s
27520 ?        S      0:00    132    68  6779  964  0.0  \_ /usr/sbin/saslauthd
27552 ?        S      0:00    349    68  6779  964  0.0  \_ /usr/sbin/saslauthd
27585 ?        S      0:00    345    68  6779  964  0.0  \_ /usr/sbin/saslauthd
27616 ?        S      0:00      0    68  6663  836  0.0  \_ /usr/sbin/saslauthd
26881 ?        S      1:27    144   119 17252  684  0.0 ./sc_serv
27042 ?        S      0:14      1   119 17252  684  0.0  \_ ./sc_serv
27073 ?        S     57:12      3   119 17252  684  0.0      \_ ./sc_serv
27108 ?        S     28:55      0   119 17252  684  0.0      \_ ./sc_serv
27136 ?        R     57:49    138   119 17252  684  0.0      \_ ./sc_serv
13714 ?        Ss     0:00    107    17  1414  524  0.0 /usr/sbin/inetd
23713 ?        S      0:05   3472   250 19549 1572  0.0 /usr/sbin/apache
25890 ?        S      0:00    593   994  3413 1328  0.0  \_ /usr/bin/perl /root/
 9284 ?        S      0:30   1792   250 30465 16492  0.2  \_ /usr/sbin/apache
23748 ?        S      0:47   2762   250 30369 16632  0.2  \_ /usr/sbin/apache
19459 ?        S      0:39   1824   250 30949 17156  0.2  \_ /usr/sbin/apache
 8709 ?        S      0:28   1502   250 30357 16620  0.2  \_ /usr/sbin/apache
14560 ?        S      0:17   1360   250 29625 15744  0.2  \_ /usr/sbin/apache
20450 ?        S      0:06    790   250 29357 15472  0.2  \_ /usr/sbin/apache
28931 ?        S      0:28   1404   250 31041 17212  0.2  \_ /usr/sbin/apache
27169 ?        S      0:04    736   250 30793 16928  0.2  \_ /usr/sbin/apache
 6053 ?        S      0:19    682   250 29341 15416  0.2  \_ /usr/sbin/apache
 6081 ?        S      0:13   1075   250 31049 17128  0.2  \_ /usr/sbin/apache
30210 ?        S      0:07    821   250 29801 15800  0.2  \_ /usr/sbin/apache
28962 ?        S      0:22    201   730  3357 1876  0.0 ./psybnc
15489 ?        S      0:00    285   588  2319  996  0.0 /bin/sh /usr/bin/mysqld_
23621 ?        S      0:00   1026  4806 68177 10796  0.1  \_ /usr/sbin/mysqld --
32066 ?        S      0:00      1  4806 68177 10796  0.1  |   \_ /usr/sbin/mysql
32102 ?        S      0:00      4  4806 68177 10796  0.1  |       \_ /usr/sbin/m
32129 ?        S      0:00      0  4806 68177 10796  0.1  |       \_ /usr/sbin/m
32167 ?        S      0:00      0  4806 68177 10796  0.1  |       \_ /usr/sbin/m
32193 ?        S      0:00      0  4806 68177 10796  0.1  |       \_ /usr/sbin/m
14272 ?        S      0:09      1  4806 68177 10796  0.1  |       \_ /usr/sbin/m
14304 ?        S      0:07      1  4806 68177 10796  0.1  |       \_ /usr/sbin/m
14562 ?        S      0:00     17  4806 68177 10796  0.1  |       \_ /usr/sbin/m
16449 ?        S      0:00      1  4806 68177 10796  0.1  |       \_ /usr/sbin/m
11622 ?        S      0:00      0  4806 68177 10796  0.1  |       \_ /usr/sbin/m
20098 ?        S      0:00     10  4806 68177 10796  0.1  |       \_ /usr/sbin/m
 4896 ?        S      0:00      0  4806 68177 10796  0.1  |       \_ /usr/sbin/m
23044 ?        S      0:00      0  4806 68177 10796  0.1  |       \_ /usr/sbin/m
15617 ?        S      0:00      0  4806 68177 10796  0.1  |       \_ /usr/sbin/m
29988 ?        S      0:00      0  4806 68177 10796  0.1  |       \_ /usr/sbin/m
23681 ?        S      0:00    130     5  1918  464  0.0  \_ logger -p daemon.err

Code:
root:~> apachectl fullstatus

                                   Not Found

   The requested URL /server-status was not found on this server.
     _________________________________________________________________


    Apache/1.3.33 Server at localhost Port 80
 
Code:
root:~> apachectl fullstatus

                                   Not Found

   The requested URL /server-status was not found on this server.
     _________________________________________________________________


    Apache/1.3.33 Server at localhost Port 80

Einfach in der httpd.config nach "status" grepen, das steht (normalerweise) irgendwo da schon drin uns ist nur auskommentiert.

BTW: Dein Apache hat eigentlich nicht unverschämt viele Childs gestartet. Könnte schon sein, dass der Server zu klein ist.
Evtl. könntest du versuchen, weniger spare Worker stehen zu lassen und die Requests per Child herunter zu nehmen.
 
Last edited by a moderator:
Mhm ein paar Webseiten. Wie viele Besucher haben die? Vielleicht hast du inperformante Scripte laufen? Hast du dir schon einmal die Statusvariablen deines MySQL Server angeschaut? Geht ganz einfach in PMA.

Just My 2 Cents
 
Back
Top