macos - MariaDB Homebrew 安装错误

标签 macos homebrew mariadb

我刚刚在我的 Mac 上通过 Homebrew 软件安装了 MariaDB。安装结束时出现以下错误:

Warning: The post-install step did not complete successfully
You can try again using `brew postinstall mariadb`

如果我运行 brew postinstall mariadb 我得到:

==> /usr/local/Cellar/mariadb/5.5.34/bin/mysql_install_db --verbose --user=andrew --basedir=/usr/loca
MariaDB is hosted on launchpad; You can find the latest source and
email lists at http://launchpad.net/maria

Please check all of the above before mailing us!  And remember, if
you do mail us, you should use the /usr/local/Cellar/mariadb/5.5.34/scripts/mysqlbug script!

READ THIS: https://github.com/mxcl/homebrew/wiki/troubleshooting

这没有帮助!我遵循的教程告诉我运行unset TEMPDIR,然后运行mysql_install_db --user=mysql --basedir=$(brew --prefix mariadb);运行这些结果如下:

/usr/local/opt/mariadb/bin/my_print_defaults: Can't read dir of '/usr/local/etc/my.cnf.d' (Errcode: 2)
Fatal error in defaults handling. Program aborted
chown: ./data: Operation not permitted
Cannot change ownership of the database directories to the 'mysql'
user.  Check that you have the necessary permissions and try again.

我怀疑问题与 /usr/local/etc/my.cnf.d 文件夹有关。我在我尝试过的一些事情中看到了这一点,但它在我的机器上不存在。我尝试了在其他教程中找到的一些不同的 mysql_install_db 命令,但它们都会抛出(不同的)错误消息。

感谢您的帮助!

最佳答案

只需使用编辑器打开 /usr/local/etc/my.cnf 处的配置文件并注释掉以下行:

!includedir /usr/local/etc/my.cnf.d

关于macos - MariaDB Homebrew 安装错误,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/20448822/

相关文章:

mysql - yeoman 全栈生成器社交 Oauth 问题

macos - 操作系统 X : why does __LP64__ lead to pure virtual functions?

objective-c - 如何在 Cocoa 中创建别名?符号链接(symbolic link)足够好吗?

python - 在 MacOS Sierra 上安装 Pillow

python - ROCKSDB 由于 rocksdb_max_row_locks 而无法获取锁

mysql - 如何更正 MySql 表中递增值的重置

objective-c - 让 LLVM/Clang 16 位对齐

macos - 如何从 Homebrew 水龙头中删除所有内容?

xcode - 通过 Xcode 构建 boost cpp 工作,通过 brew 导致不兼容

PostgreSQL "Illegal Group Name"