流浪的MySQL访问 [英] Vagrant MySQL Access

查看:69
本文介绍了流浪的MySQL访问的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

因此,我对这种无所事事的vm创建是陌生的(真的很喜欢).我正在使用puphpet进行配置.一切都很好.访问共享文件夹,ssh和访问网站(Apache服务器).

So I am new to this vagrant vm creation (and am really liking it). I am using puphpet to make the config. Everything is working great. Access to the shared folders, ssh and access to the website (Apache server).

我似乎无法弄清楚的最后一部分是数据库部分.当使用php时,我可以连接,但要在数据库上进行实际开发,我更喜欢使用sqldeveloper(我尝试过工作台).不管我输入什么,我似乎都无法建立联系.无论用户ip或名称如何,它都不会出现在任何地方.

The last piece I cannot seem to get figured out is the database part. When using php I can connect but to do the actual development on my database I prefer to use sqldeveloper (I have tried workbench). No matter what I enter I cannot seem to get a connection. No matter the user ip or name it does not go anywhere.

我尝试了127.0.0.1和192.168.56.100< = VM ip

I have tried 127.0.0.1 and 192.168.56.100 <= VM ip

端口为3306(据我所知),据我所知,我没有对其进行修改.

Port is 3306 (as far as I know) I did not modify this as far as I know.

我不确定这里有什么信息会有用,所以请告诉我.

I am not sure what information would be helpful here so please let me know.

我已经看到了有关更新my.cnf,绑定地址和更新用户特权的一些内容,但是我在其他几篇文章中对此进行了论证.

I have seen something about updating the my.cnf, binding addresses and updating user privileges but that was argued in a couple other articles I have seen.

只想检查一下,因为我也在制作将用于设置的文档.

Just want to check because I am also making the documentation that will be used for setup.

如果需要上述步骤,是否有自动化的方法?

If the above steps are needed is there anyway to automate it?

推荐答案

您必须转发在Puphpet中执行的端口,以便服务器可以与端口80进行通信.您必须对其他操作执行相同的操作.因此,要访问3306,您需要将其放在配置中.您可以使用任何编辑器打开现有配置.

You have to forward the port in Puphpet you had to do this so that your server can talk to port 80. You must do the same for anything else you do. So for you to access 3306 you need to have it foward inside the config. You can open up the existing config with any editors.

这篇关于流浪的MySQL访问的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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