The recent configuration of the LNMP is still stable, secretly pleased, but from the beginning of last night, it was found that the CPU occupied by the server is too high, even to 100%. My memory is 1G, the normal occupancy rate should be below 5%, at most not exceeding 10%.
Aliyun Recent monitoring shows:
Use the top command to see that the php-fpm occupies too much memory and is not normal:
In accordance with the article "two process management methods and optimizations used by the Nginx php-fpm", I configure the following number of PHP-FPM processes:
After restarting the PHP-FPM, still did not solve the problem thoroughly, still can appear occupy more than 99, do not know which friend knows how to analyze and solve? Little brother for help!
Follow-up progress
Yesterday (March 29) to look for @ Rong elder brother Guidance check, and later found that eaccelerator components for some reason to occupy the CPU too high, open php.ini
Vi/usr/local/php/etc/php.ini
Remove Eaccelerator configuration information and restart LNMP
/ROOT/LNMP restart
But still did not completely solve the problem, a few hours later, I restarted the LNMP, incredibly found, seems to have been more and more stable.
Possible commands to use:
Top//view CPU, memory usage information, see which process is consuming CPU height and its PID
Ll/proc/pid number/fd///through the PID to find which file operation process, and then know the problem lies