Evil PHP script crashed a friends server! Advice please?
Ok, a friend of mine owns a server and he gets some guy to admin it. Somehow a PHP script with the following content:$times = 10000000000;
$x = 0;
while ($x < $times) {
echo $x;
++$x;
}
was run, effectively killing the server. Apache went down and the /tmp 'partition' became full. The server came back up after a few minutes and apache began working again with 5 restarts.
The admin has told him that because of this script, the logs are now stuffed up, the filesystem has 'cache bugs' in it and the kernel now needs to be fixed.
My friend came to me and wanted to know whether that script would really cause all those problems, but im not really sure, so im asking you all, does this sound right to you guys?
Thanks!