如何将MySQL DB从本地主机移到生产环境 [英] How to move MySQL DB from localhost to Production Environment

查看:153
本文介绍了如何将MySQL DB从本地主机移到生产环境的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我已经在localhost上开发了一个网站,并且几乎已将所有数据输入到localhost环境中的MySQL DB中.现在,我已经购买了域名和托管空间.现在,我想将我的网站托管到生产环境.
问题是,我不知道如何将MySQL数据库数据从本地主机移到生产环境.


有人可以帮我吗?

I have developed a website in localhost and I have entered almost all the data to MySQL DB in localhost environment. Now, I have purchased the domain and hosting space. Now, I want to host my site to Production Environment.
The Problem is, I don''t know how to move the MySQL DB Data from localhost to Production Environment.


Can some one help me??

推荐答案

好吧,我认为一种方法是运行在localhost中使用的相同SQL脚本(如果您使用查询创建了数据库) )在您的生产环境中.我不确定MySQL是否具有SQL Server具有的功能,该功能是否可以从物理表生成SQL脚本.

或者,另一种方法是在本地主机中备份数据库,然后使用该备份文件实时还原它.看看是否有帮助: MySQL备份和还原 [ ^ ]

干杯....
well, i think the one way is run the same SQL scripts that you used in localhost (if you created your database using queries) on your production environment. I am not sure whether MySQL has something which SQL Server has which is an ability to generate SQL scripts from physical tables.

OR, the other way is take a backup of your database in localhost and then restore it on live using that backup file. See if this helps: MySQL Backup and Restore[^]

Cheers....


阅读以下有关该主题的内容:
mySql备份方法
Read the following on the subject :
mySql backup methods


您可以备份本地数据库并在生产环境中还原它.有关更多信息,请将其作为... mysql备份和还原进行谷歌搜索,您将有大量文章
you can backup your local database and restore it in the production environment. for more info please google it as ...mysql backup and restore, you will have plenty of articles


这篇关于如何将MySQL DB从本地主机移到生产环境的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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