Fortunately, the VPS Control Panel with the simple shell can also be used, the input df -h
View disk occupancy, the result is 100% occupancy, df -sh *
and then all the way to locate the past found in the MySQL directory full (DF- h to see which directory full, and then cut to the directory after the Df-sh * to continue tracking ), the original is installed LNMP when the default opened the MySQL log, and then full of mysql-bin.* log files.
Sure enough, the/var catalogue exploded.
root@slyar:/usr/local/mysql/var# ll--BLOCK-SIZE=MB
Total 504MB
-RW-RW----1 MySQL mysql 26MB June mysql-bin.000011
-RW-RW----1 MySQL mysql 5MB June mysql-bin.000012
-RW-RW----1 MySQL mysql 27MB Aug 8 mysql-bin.000013
-RW-RW----1 mysql mysql 43MB Aug mysql-bin.000014
-RW-RW----1 mysql mysql 270MB Feb 9 17:05 mysql-bin.000020
-RW-RW----1 mysql mysql 115MB Apr 12:27 mysql-bin.000021
-RW-RW----1 mysql mysql 1MB Feb 12:07 mysql-bin.index
-RW-RW----1 mysql mysql 0MB Apr 12:34 mysql-bin.~rec~
Basically, it's all over the stuff. mysql manual found that these things are not useful, direct deletion (this operation is best done when the MySQL service is stopped, because the current log can not be used to delete, and may cause some other problems, but with Mysql>reset The Master command can empty the log directly.
root@slyar:/usr/local/mysql/var# rm-f mysql-bin.* shut down MySQL's log-bin log function directly to prevent such a situation from recurring.
VIM/ETC/MY.CNF Find:
Log-bin=mysql-bin
Binlog_format=mixed in front Plus # comment out,: Wq save exit.
At last:
/etc/init.d/mysql Restart start MySQL service, everything is OK.
Supplementary: Other questions
First, delete the Ngnix log after Ngnix can not be restarted
Fixing this problem is simple, just turn off the Ngnix log record. Find the Ngnix installation directory editor conf file, the log record that line to "Access_log/dev/null" and then try to start Ngnix, no accident Ngnix can be successfully started.
In fact, the correct steps to clear the Ngnix log should be to close the Ngnix, then the MV Rename log file, and then start Ngnix, this will automatically generate the log file, no problem can be directly deleted log files
Second, the Nginx boot occurs when the port is occupied hint problem
Take a look at what is occupied, or you can use NETSTAT-NTPL to see who occupies, and then kill off the occupied PID
Then remove the process via kill-9
Finally/etc/init.d/nginx start is OK.