Today on the Mac on the blind toss, the MySQL play bad, want to unload load, but found not find uninstall program, Baidu, the operation step back to this:
CD ~//usr/local/-rf/usr/local/mysql*-rf/library/startupitems/-rf/library/ preferencepanes/my*/etc/hostconfig and removed the line MYSQLCOM=-YES-RM-RF ~/library/preferencepanes/my* -rf/library/receipts/mysql*-rf/library/receipts/mysql*-rf/var/db/receipts/com.mysql .*
The tutorial of installing MySQL under Mac, can refer to the article of the friend of Http://www.cnblogs.com/macro-cheng/archive/2011/10/25/mysql-001.html
The version I installed is 5.6.25 Community Edition
Note: After re-installation, it is recommended to restart the machine, otherwise it is possible to start the failure, or can only be started in Safe mode (I re-installed two times before the discovery, it may be the individual phenomenon of my notebook)
It is worth mentioning that: MySQL default encoding is not UTF8, so the Chinese content after insert into the DB, garbled, the workaround:
Stop MySQL first, and then
sudo vi/usr/local/mysql/my.cnf find the [client] and [mysqld] nodes, refer to the following content to specify the encoding
[client]
Default-character-set=utf8
[Mysqld]
Character-set-server=utf8
Finally restart MySQL, after entering the MySQL command, enter status, you can view the results, verify:
Or enter show variables like '%char% '
How to uninstall MySQL under Mac