歡迎您光臨本站 註冊首頁

求助:apache出現資源耗盡,導致宕機

←手機掃碼閱讀     火星人 @ 2014-03-04 , reply:0

求助:apache出現資源耗盡,導致宕機

redhat as 3 + php4

用了3年了,今天突然出現這樣的情況,啟動apache后,伺服器馬上資源被耗盡,幾乎沒有反應,關掉apache,之後系統就正常

error_log的日誌
(13)Permission denied: access to /~zbzxx/OTHER/JIAOSHI/cfol/source
/tools/Alarm Clock/sonar.wav denied, referer: http://202.108.23.172/index.html
File does not exist: /home/wenyuan/www/1-1.gif, referer: http://host.zdjw.gov.cn/~wenyuan/
File does not exist: /home/wenyuan/www/4-1.gif, referer: http://host.zdjw.gov.cn/~wenyuan/
File does not exist: /home/wenyuan/www/2-1.gif, referer: http://host.zdjw.gov.cn/~wenyuan/
File does not exist: /home/wenyuan/www/3-1.gif, referer: http://host.zdjw.gov.cn/~wenyuan/
File does not exist: /home/wenyuan/www/6-1.gif, referer: http://host.zdjw.gov.cn/~wenyuan/
File does not exist: /home/wenyuan/www/5-1.gif, referer: http://host.zdjw.gov.cn/~wenyuan/
File does not exist: /home/wenyuan/www/7-1.gif, referer: http://host.zdjw.gov.cn/~wenyuan/
File does not exist: /home/wenyuan/www/8-1.gif, referer: http://host.zdjw.gov.cn/~wenyuan/
File does not exist: /home/wenyuan/www/de_files/top2.jpg, referer
: http://host.zdjw.gov.cn/~wenyuan/
File does not exist: /home/wenyuan/www/de_files/itembg.gif, refer
er: http://host.zdjw.gov.cn/~wenyuan/
child process 1334 still did not exit, sending a SIGTERM
child process 1335 still did not exit, sending a SIGTERM
child process 1336 still did not exit, sending a SIGTERM
child process 1337 still did not exit, sending a SIGTERM
child process 1338 still did not exit, sending a SIGTERM
child process 1339 still did not exit, sending a SIGTERM
child process 1340 still did not exit, sending a SIGTERM
child process 1341 still did not exit, sending a SIGTERM
child process 1342 still did not exit, sending a SIGTERM
child process 1343 still did not exit, sending a SIGTERM
child process 1344 still did not exit, sending a SIGTERM
child process 1345 still did not exit, sending a SIGTERM
child process 1352 still did not exit, sending a SIGTERM
child process 1353 still did not exit, sending a SIGTERM
child process 1355 still did not exit, sending a SIGTERM
child process 1356 still did not exit, sending a SIGTERM
child process 1361 still did not exit, sending a SIGTERM
child process 1334 still did not exit, sending a SIGTERM
child process 1335 still did not exit, sending a SIGTERM
child process 1336 still did not exit, sending a SIGTERM
child process 1337 still did not exit, sending a SIGTERM
child process 1338 still did not exit, sending a SIGTERM
child process 1339 still did not exit, sending a SIGTERM
child process 1340 still did not exit, sending a SIGTERM
child process 1341 still did not exit, sending a SIGTERM
child process 1342 still did not exit, sending a SIGTERM
child process 1343 still did not exit, sending a SIGTERM
child process 1353 still did not exit, sending a SIGTERM
child process 1361 still did not exit, sending a SIGTERM

[ 本帖最後由 yu10101 於 2007-12-17 13:43 編輯 ]
《解決方案》

回復 #1 yu10101 的帖子

PID USER     PRI  NI  SIZE  RSS SHARE STAT %CPU %MEM   TIME CPU COMMAND
    7 root      20   0     0    0     0 SW   25.5  0.0   0:56   1 kswapd
    8 root      15   0     0    0     0 SW    6.6  0.0   0:13   1 kscand
1014 mysql     16   0 10436 1196   108 D     2.9  0.0   0:02   1 mysqld
1433 nobody    16   0     0    0     0 Z     2.3  0.0   0:01   1 httpd <defunct>
1443 nobody    16   0  130M 128M 16704 D     2.1  6.3   0:01   0 httpd
1447 nobody    16   0  127M 125M 15140 D     2.1  6.2   0:00   1 httpd
1440 nobody    16   0  130M 128M 16732 D     2.0  6.4   0:00   1 httpd
1417 nobody    16   0  167M  18M     4 D     1.9  0.9   0:01   1 httpd
1416 nobody    16   0  167M  18M     4 D     1.8  0.9   0:01   0 httpd
1422 nobody    15   0  167M  18M     4 D     1.8  0.9   0:01   1 httpd
1434 nobody    16   0  130M 128M 16812 D     1.8  6.4   0:00   0 httpd
1418 nobody    16   0  167M  19M     4 D     1.6  0.9   0:01   0 httpd
1428 nobody    16   0  168M  18M     4 D     1.6  0.9   0:01   0 httpd
1442 nobody    15   0  130M 128M 16764 D     1.6  6.4   0:00   1 httpd
1420 nobody    15   0  169M  21M     4 D     1.5  1.0   0:01   1 httpd
1425 nobody    15   0  167M  20M     8 D     1.5  1.0   0:01   1 httpd
1444 nobody    15   0  130M 128M 16704 D     1.5  6.3   0:00   0 httpd
1445 nobody    15   0  115M 114M  9328 D     1.5  5.6   0:00   0 httpd
1391 root      16   0   560  524   308 R     1.4  0.0   0:03   0 top
1419 nobody    15   0  168M  16M     4 D     1.4  0.8   0:01   1 httpd
1421 nobody    16   0  172M  22M     4 D     1.4  1.1   0:01   1 httpd
1424 nobody    16   0  167M  20M     4 D     1.4  1.0   0:01   1 httpd
1438 nobody    15   0  130M 129M 16856 D     1.4  6.4   0:00   1 httpd

top出現上述內容,覺得非常不正常
《解決方案》

同問一下,我也遇過這個問題。
top里看,我是swap用的相對多一些,所以出現這個情況。
《解決方案》

有人用syn攻擊你了?

你吧你的apache的maxclient減小,不要這樣不給自己留餘地嘛,這麼干是愚蠢的表現!

[ 本帖最後由 evil_knight 於 2007-12-17 22:07 編輯 ]
《解決方案》

找到原因了,是因為一個網站的的代碼有問題,謝謝大家
《解決方案》

兄弟 你管理的是百度的伺服器

[火星人 ] 求助:apache出現資源耗盡,導致宕機已經有494次圍觀

http://coctec.com/docs/service/show-post-33540.html