Ask Ubuntu is a question and answer site for Ubuntu users and developers. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I'm running a virtualMachine on ESXi -- Ubuntu as a webserver -- (apache2 with nginx as his proxy, php, mysql) and services keeps hanging/freezing causing the whole server to be unresponsive. It's not possible to connect to it by ssh, basicly it requires a reboot from vSphere to come back online.

Description: Ubuntu 10.04.1 LTS Release: 10.04 Codename: lucid

at vSphere I see this message when my server is unreachable:: INFO: task: apache2 (or mysql or nginx) blocked for more than 120 seconds. "echo 0 > /proc/sys/kernel/hung_task_sys_timeout_secs" disables this message

i think that likely it happens in high traffic on my sites what could i do?!


share|improve this question
any idea pro guys??! – m mov Oct 22 '12 at 7:27
I think it is probably Apache its self hanging. Do you have any syslog entries related to the problem, or from around the hang? – Bailey S Oct 23 '12 at 23:34

You are hitting a hung task time out, while your system is waiting for some resources (maybe I/O to complete) to complete which are not presently available. I would recommend first collecting some data checking with any sar data or using tools like iostats and vmstat to identify the loads and the times the freeze/hang occurs. You could possibly write a small cron job for this.

ex: sar -A 1 30 > /tmp/sar_-A.out.txt & vmstat 1 30 > /tmp/vmstat.out.txt & iostat -tkx 1 30 > /tmp/iostat_-x.out.txt & ps aufx > /tmp/ps_aux.out.txt &

Also get a kernel thread dump using: "echo t | sudo tee /proc/sysrq-trigger" as this would help in determining to some extent what the apache process is waiting for.

Alternatively, you could get configure crashdump when your system is in a hung state and obtain a vmcore file, if you are more adventurous to do a dump analysis.

share|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.