将 magento 站点从一台服务器移动到另一台服务器 [英] Moving magento site from one server to another server

查看:34
本文介绍了将 magento 站点从一台服务器移动到另一台服务器的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我有一个 magento 站点版本 1.4.1.1.

i have a magento site version 1.4.1.1.

然后我将站点升级到 1.7.0.2.

现在想将升级后的 magento 移动到另一台服务器.

Now want to move the upgraded magento into another server .

我该怎么做?

i planed to do this by downloading all files and upload it into new server.and import the database into the same databsae name.

如果我按照上述步骤操作时出现任何问题.

If there is any problem occur when i following the above steps.

或者是否有任何规则可以将 magento 站点从一台服务器移动到另一台服务器?

Or if there is any rules to move magento site from one server to another server?

推荐答案

如果您的站点不是 publick,那么只需移动文件和 db 并修复 db 上的 base_urls.

If your sites are not publick then just move the files and db and fix base_urls on db.

如果您的网站已上线,那么在移动网站时需要注意一两件事:

If your site is live then here's a thing or two to note down on moving sites:

代码:

这很简单,静态资产可以预先移动到新服务器

this is straightforward, static assets can be moved beforehand to new server

  • 很容易使用 rsync 或版本控制,甚至是普通的旧 ftp
  • 验证文件结构和权限

数据库:

这更复杂,因为您必须避免在切换到移动站点数据库后在旧服务器数据库上获得更多订单的差距,您需要在移动数据库时关闭我们的站点

this is more complicated as you have to avoid the gap of getting more orders on old server database after you have switched to move your site database you need to take our site down for the time you move your database

  • 第一步将数据库移动到新服务器进行测试,测试是否一切正常
  • 不包含您​​需要运行的所有查询以使其在新服务器上运行(基本网址等)
  • 当您关闭网站并打开另一个网站时重复此过程

代码和数据库的过程:

  • 在旧页面上添加一个带有正确 http 标头的维护页面
  • 当站点关闭时将数据库移动到新服务器
  • 打开你的新网站,并验证是否一切正常
  • 下一步是将域更改为指向新服务器

移动域名

再次移动域是一件有点棘手的事情,因为可能会出现 DNS 中断,一些客户会看到旧站点,而另一些客户会看到新站点.

again moving domains is a bit tricky thing as there is a possible DNS blackout that some clients will see the old site and some are seeing the new.

  • 更改域规则以指向新服务器
  • 未更改 DNS 的客户将看到维护页面
  • 已经拥有新 DNS 的客户最终会访问移动的站点

这样您就可以确保不会在两个站点上都收到订单.如果您的域完全更改,那么您还需要为每个搜索引擎重新映射您的 URL 到新域

this way you can ensure that you will not get orders on both sites. If your domain-changes completely then you also need to remap your URLS to new domains for every search engine

这篇关于将 magento 站点从一台服务器移动到另一台服务器的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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