MySQL Workbench“正在获取..." -无法浏览数据库 [英] MySQL Workbench "fetching..." -- cannot browse DB

查看:168
本文介绍了MySQL Workbench“正在获取..." -无法浏览数据库的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

最近以来,我一直遇到很多问题,基本上是自上次升级OSX的XAMPP(v1.7.3)和/或我的MySQL GUI工具以来.使用 MySQL Workbench (v5.2.44),我可以很好地连接到在XAMPP中运行的数据库,但是尝试浏览在表/视图/等目录下的任何数据库,它仅显示正在获取...",而从不显示其他任何内容.我实际上可以查询表,这很有趣,但是实际上我无法以任何有意义的方式管理数据库.

I've been having a lot of issues lately, basically since the last time I upgraded XAMPP for OSX (v1.7.3) and/or my MySQL GUI tools. Using MySQL Workbench (v5.2.44), I can connect to the DB running in XAMPP just fine, but trying to browse any database, under tables/views/etc it only shows "Fetching..." and never shows anything else. I can actually query tables, which is interesting, but I can't actually manage the databases in any meaningful way.

Google,其他报告说,运气很好mysql_upgrade在命令行上运行正常,但没有解决我的问题.

Googling, others reported having luck running mysql_upgrade on the command line, which ran fine but did not fix my issue.

推荐答案

上面到mysql_upgrade的链接不能直接解决我的问题,但是确实导致我检查了我的mysql错误文件,最终导致我找到了解决方案.我在错误文件(位于[xampp root]/var/mysql/[dbname].err中)中注意到了几行这样的内容:

The link above to mysql_upgrade did not solve my problem directly, but it did lead me to examine my mysql error file, which ultimately led me to the solution. I noticed several lines like this in the error file (located at [xampp root]/var/mysql/[dbname].err):

/Applications/XAMPP/xamppfiles/sbin/mysqld: Can't create/write to file 
    '/var/folders/y2/37h93r_931sdfpcr7vnc83380000gn/T/ibigNFFi' (Errcode: 13)

这导致我在此页面中MySQL文档指出您应为MySQL明确设置temp文件夹.我仔细检查了配置文件([xampp root]/etc/my.cnf)并看到了它,看起来不错:

That led me to this page in the MySQL docs which states that you should explicitly set the temp folder for MySQL. I double-checked my config file ([xampp root]/etc/my.cnf) and saw this, which looked fine:

[mysqld]
tmpdir = /Applications/XAMPP/xamppfiles/temp/

但是,回顾错误日志,我也注意到了这一点:

However, looking back at the error log, I also noticed this:

Warning: World-writable config file '/Applications/XAMPP/xamppfiles/etc/my.cnf' is ignored

Du.配置文件被忽略,因此配置的临时文件夹没有被使用(我不知道为什么文件是世界可写的...).我编辑了my.cnf文件的权限,该文件为777,并简单地删除了所有人|写"权限(现在为775/-rwxrwxr-x),重新加载了所有内容,现在一切正常.

Duh. The config file was getting ignored, so the configured temp folder was not getting used (I have no clue why the file was world-writeable...). I edited permissions on the my.cnf file which was 777 and simply removed the "Everyone|write" permission (now 775 / -rwxrwxr-x), reloaded everything, and now everything works.

最终解决方案不是很直观的症状,因此希望对其他人有所帮助.

Not a very intuitive symptom for the ultimate fix, so hopefully this helps someone else.

这篇关于MySQL Workbench“正在获取..." -无法浏览数据库的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆