I want to understand this scenario:
My server suddenly became busy and stopped doing anything new that I tell it to do: ls, vi, nothing works, its frozen. But I can browse through already open vim file. Why so?
Could be all sorts of things, this assumes you can't do anything at all other than use your existing vim. You can't ssh in, you can't open a new shell, nothing. If you can open a new shell but can't run anything in that shell, then it could be all sorts of different things, for instance your PATH could refer to a directory on a network share that's down (try running "/bin/ls" so PATH is not searched) and you have to wait for it to time out before it will look in the other directories ... Here are some things to try:
In the order of "least likely to cause vim to crash", start by getting vim to open /proc/loadavg (
The first three numbers are your load average (same as uptime command) the 2/176 says there are two processes currently runnable out of 176 total processes. If the total processes are in the tens of thousands then a forkbomb or something similar may be consuming all of your resources. You can probably read
If the first three numbers from /proc/loadavg are really high (eg 10.0+, depending on # cpus/cores) then it could be a runaway process taking up all your CPU time (in which case your commands should execute... eventually. But then vim should be slow too). Otherwise it's possible that there is an IO problem, which can increase load numbers without using the CPU (eg failed harddrive). If you have sysfs mounted (typically
If the drive does not have errors, then it might be safe to try reading from the drive: if you have permission try opening