Ubuntu 12.04 MySQL改utf-8 启动不了
default-character-setutf8
报错
start mysql. The restart(8) utility is also available.
start: Job failed to start
这么写OK了
On MySQL 5.5 I have in my.cnf
[mysqld]
init_connectSET collation_connection utf8_unicode_ci
init_connectSET NAMES utf8
character-set-serverutf8
collation-serverutf8_unicode_ci
skip-character-set-client-handshake
Result is
mysql> show variables like "%character%";show variables like "%collation%";
------------------------------------------------------
| Variable_name | Value |
------------------------------------------------------
| character_set_client | utf8 |
| character_set_connection | utf8 |
| character_set_database | utf8 |
| character_set_filesystem | binary |
| character_set_results | utf8 |
| character_set_server | utf8 |
| character_set_system | utf8 |
| character_sets_dir | /usr/share/mysql/charsets/ |
------------------------------------------------------
8 rows in set (0.00 sec)
---------------------------------------
| Variable_name | Value |
---------------------------------------
| collation_connection | utf8_unicode_ci |
| collation_database | utf8_unicode_ci |
| collation_server | utf8_unicode_ci |
---------------------------------------
3 rows in set (0.00 sec)
【出处:阜宁网站开发公司 http://www.1234xp.com/funing.html 网络转载请说明出处】