在Yosemite上重启后无法启动mysql

时间:2015-09-17 12:20:01

标签: mysql homebrew yosemite my.cnf mysql.sock

我遇到了一个看似相当平常的问题,虽然已经阅读并尝试了许多解决方案,但我对这里发生的事情感到很困惑。问题的症结在于,我在安装MySQL后重新启动Mac(在OS X Yosemite 10.10.3上运行)时无法连接,启动或运行,并显示以下消息ERROR 2002 (HY000): Can't connect to local MySQL server through socket '/tmp/mysql.sock' (2)

我使用brew安装了MySQL,它位于/usr/local/Cellar/mysql/5.6.26/。当我从这里运行mysqld_safe时,它每次都退出,无法启动。我查看了错误文件,这些是错误消息:

2015-09-16 10:43:27 7fff77882300  InnoDB: Operating system error number 2 in a file operation.
InnoDB: The error means the system cannot find the path specified.
InnoDB: If you are installing InnoDB, remember that you must create
InnoDB: directories yourself, InnoDB does not create them. 
2015-09-16 10:43:27 1421 [ERROR] InnoDB: Could not find a valid tablespace file for 'bespokedb/concept_terms'. See http://dev.mysql.com/doc/refman/5.6/en/innodb-troubleshooting-datadict.html for how to resolve the issue.
2015-09-16 10:43:27 1421 [ERROR] InnoDB: Tablespace open failed for '"bespokedb"."concept_terms"', ignored.
2015-09-16 10:43:27 7fff77882300  InnoDB: Operating system error number 2 in a file operation.
InnoDB: The error means the system cannot find the path specified.
InnoDB: If you are installing InnoDB, remember that you must create
InnoDB: directories yourself, InnoDB does not create them.
2015-09-16 10:43:27 1421 [ERROR] InnoDB: Could not find a valid tablespace file for 'bespokedb/terms'. See http://dev.mysql.com/doc/refman/5.6/en/innodb-troubleshooting-datadict.html for how to resolve the issue.
2015-09-16 10:43:27 1421 [ERROR] InnoDB: Tablespace open failed for '"bespokedb"."terms"', ignored.
2015-09-16 10:43:27 1421 [Note] InnoDB: 128 rollback segment(s) are active.
2015-09-16 10:43:27 1421 [Note] InnoDB: Waiting for purge to start
2015-09-16 10:43:27 1421 [Note] InnoDB: 5.6.26 started; log sequence number 12730080990
Warning: World-writable config file './auto.cnf' is ignored /usr/local/Cellar/mysql/5.6.26/bin/mysqld: Error on delete of './auto.cnf' (Errcode: 13 - Permission denied)
2015-09-16 10:43:27 1421 [Warning] World-writable config file './auto.cnf' has been removed.

Warning: World-writable config file './auto.cnf' is ignored
2015-09-16 10:43:27 1421 [Warning] No existing UUID has been found, so we assume that this is the first time that this server has been started. Generating a new UUID: 617f6dd0-5c57-11e5-a7aa-9c9a2e17ea50.

我试过制作mysql数据目录(在/usr/local/var/mysql中)文件夹和文件读,写和可执行(我知道有点顽皮)。我也尝试在/var/mysql/中为mysql.sock创建一个sim链接。除此之外,我已经多次卸载并重新安装了mysql,并在网上详细介绍了如何删除/添加启动项的许多例程。总而言之,对于在广泛使用的操作系统上使用非常广泛的套件而言,这似乎非常复杂。如果有人非常友好地在这里详细讨论这些问题可能会如何产生/为什么这个过程并不简单,那将是非常棒的。我只想学习!

谢谢,

0 个答案:

没有答案