Mac下删除mysql

首先可以在System Preferences中的Other里MySQL设置,停止其服务,然后参照以下手工删除命令行。

apple$ sudo rm /usr/local/mysql
apple$ sudo rm -rf /usr/local/mysql*
apple$ sudo rm -rf /Library/StartupItems/MySQLCOM
apple$ sudo rm -rf /Library/PreferencePanes/My*
apple$ sudo rm -rf /Library/Receipts/mysql*
apple$ sudo rm -rf /Library/Receipts/MySQL*
apple$ sudo rm -rf /var/db/receipts/com.mysql.*

编辑/etc/hostconfig,删除其中的MYSQLCOM=-YES-这行

Tagged ,