Finally solved last week's legacy MySQL can not start the problem, the reason is that the previous installation of two MySQL, and the path is different, there are other people's detailed solution: http://www.linuxidc.com/Linux/2011-05/35409.htm
Because I didn't know the problem, I re-installed a new Virtual Machine (64bit). I cannot make it before (for zlib problems, we need to set up 64 machines). After compilation and installation are successful, the following error occurs:
111128 01:39:59 mysqld_safe Logging to '/opt/mysql5/var/debian.err'.touch: cannot touch `/opt/mysql5/var/debian.err': No such file or directorychown: cannot access `/opt/mysql5/var/debian.err': No such file or directory111128 01:39:59 mysqld_safe Starting mysqld daemon with databases from /opt/mysql5/varbin/mysqld_safe: line 100: /opt/mysql5/var/debian.err: No such file or directorybin/mysqld_safe: line 137: /opt/mysql5/var/debian.err: No such file or directory111128 01:39:59 mysqld_safe mysqld from pid file /opt/mysql5/var/debian.pid endedbin/mysqld_safe: line 100: /opt/mysql5/var/debian.err: No such file or directory
I searched for half a day and did not find the cause. Finally, we found that it was only a small problem. First Run bin/mysql_install_db -- user = MySQL and start it again. The problem is solved!
Note that you must not forget these two statements before installing MYSQL:
Groupadd MySQL
Useradd-G MySQL
Next, we will continue to solve the MongoDB problem. It's really hard to build the environment!
In addition, the content of my. CNF is as follows:
[client]port = 3306socket = /tmp/mysql.sock[mysqld]port = 3306bind-address = 0.0.0.0socket = /tmp/mysql.sockskip-external-lockingkey_buffer_size = 16Mmax_allowed_packet = 1Mtable_open_cache = 64sort_buffer_size = 512Knet_buffer_length = 8Kread_buffer_size = 256Kread_rnd_buffer_size = 512Kmyisam_sort_buffer_size = 8Mserver-id = 1innodb_data_home_dir = /opt/mysql5/varinnodb_data_file_path = ibdata1:10M:autoextendinnodb_log_group_home_dir = /opt/mysql5/varinnodb_buffer_pool_size = 700Minnodb_additional_mem_pool_size = 2Minnodb_log_file_size = 5Minnodb_log_buffer_size = 8Minnodb_flush_log_at_trx_commit = 1innodb_lock_wait_timeout = 50[mysqldump]quickmax_allowed_packet = 16M[mysql]no-auto-rehash[myisamchk]key_buffer_size = 20Msort_buffer_size = 20Mread_buffer = 2Mwrite_buffer = 2M[mysqlhotcopy]interactive-timeout