markdown 从Mac OSX中完全删除MySQL

Posted

tags:

篇首语:本文由小常识网(cha138.com)小编为大家整理,主要介绍了markdown 从Mac OSX中完全删除MySQL相关的知识,希望对你有一定的参考价值。

# Remove MySQL completely

1. Open the Terminal
2. Use `mysqldump` to backup your databases
3. Check for MySQL processes with: `ps -ax | grep mysql`
4. Stop and kill any MySQL processes
5. Analyze MySQL on HomeBrew: 
        
    ```
    brew remove mysql
    brew cleanup
    ```

6. Remove files: 

    ```
    sudo rm /usr/local/mysql
    sudo rm -rf /usr/local/var/mysql
    sudo rm -rf /usr/local/mysql*
    sudo rm ~/Library/LaunchAgents/homebrew.mxcl.mysql.plist
    sudo rm -rf /Library/StartupItems/MySQLCOM
    sudo rm -rf /Library/PreferencePanes/My*
    ```

7. Unload previous MySQL Auto-Login: 
        
    ```
    launchctl unload -w ~/Library/LaunchAgents/homebrew.mxcl.mysql.plist
    ```
        
8. Remove previous MySQL Configuration: 

    ```
    subl /etc/hostconfig` 
    # Remove the line MYSQLCOM=-YES-
    ```
        
9. Remove previous MySQL Preferences: 
    
    ```
    rm -rf ~/Library/PreferencePanes/My*
    sudo rm -rf /Library/Receipts/mysql*
    sudo rm -rf /Library/Receipts/MySQL*
    sudo rm -rf /private/var/db/receipts/*mysql*
    ```
    
10. Restart your computer just to ensure any MySQL processes are killed
11. Try to run mysql, **it shouldn't work**

以上是关于markdown 从Mac OSX中完全删除MySQL的主要内容,如果未能解决你的问题,请参考以下文章

从 Mac OSX Lion 完全卸载 PostgreSQL 9.0.4?

Mac OSX文件权限有'@' - 如何删除'@' [关闭]

markdown 如何在Mac OSX中重命名文件?

如何在mac osx下启用mysql(转载)

Glut 窗口 - MAC OSX 中的菜单栏

markdown 从mac os系统首选项中删除Boom Device。