How to replace a server on a PHP website

Source: Internet
Author: User
Tags php website

Server (host) is not only a search engine to determine the quality of one of the hard standards, but also the user experience can not be neglected in an important part. With high quality and good content, it is very important to be able to continue to show the user quickly and stably.
I used to be a virtual host, in the access speed, stability two aspects are not flattering, borrowed this server expires, replaced the Web site server, the replacement process is much the same, today with their own SEO blog as an example, the whole process of replacement to share to be replaced the server's friends.
To change the site server steps:
Pre-replacement preparation work:
first, back up the database files. First, go back to the Web site data you are using (PHPMYADMIN), export the database file in the current server, default format: SQL.

650) this.width=650; "id=" aimg_1243 "src=" http://bbs.dbfen.com/data/attachment/forum/201409/17/ 170356piynwiyit6nnxa5a.png "class=" Zoom "width=" 291 "style=" border:0px; "alt=" 170356piynwiyit6nnxa5a.png "/>

650) this.width=650; "id=" aimg_1242 "src=" http://bbs.dbfen.com/data/attachment/ Forum/201409/17/170356qyuspyy8y9snvv1f.jpg "class=" Zoom "width=" 305 "style=" border:0px; "alt=" 170356qyuspyy8y9snvv1f.jpg "/> 

II, Back up the Web program files. In the background of the server back up the pictures, programs, pages and other files, you can also use FTP to download all the files in the root directory.

start replacing the Web server:
one, Into the new host database, import the SQL file you just backed up into

650) this.width=650; "id=" aimg_1241 "src=" http://bbs.dbfen.com/data/attachment/forum/201409/17/ 170356oatwwvffrf99lvy8.png "class=" Zoom "width=" 314 "style=" border:0px; "alt=" 170356oatwwvffrf99lvy8.png "/>

Second, open the FTP tool, the same is just downloaded a good website program files uploaded to the root directory (www/root).
Third, modify the website program in the wp-config.php file, the new host database name, database user name, the database password is filled in sequence.

650) this.width=650; "id=" aimg_1239 "src=" http://bbs.dbfen.com/data/attachment/forum/201409/17/ 170355okvi77ijofkovvi6.png "class=" Zoom "width=" 246 "style=" border:0px; "alt=" 170355okvi77ijofkovvi6.png "/>

OK, as of this step, make sure your website is still running on the old server.
Four, the domain name resolution. In the domain management background, the domain name is resolved to the new server IP. The author uses a non-independent IP host in Hong Kong, directly to the domain name CNAME with www to the host's IP above, the use of independent IP friends do not forget a resolution.

650) this.width=650; "id=" aimg_1238 "src=" http://bbs.dbfen.com/data/attachment/forum/201409/17/ 170355a3zfn3dnsdndh6jd.png "class=" Zoom "width=" 148 "style=" border:0px; "alt=" 170355a3zfn3dnsdndh6jd.png "/>

V. Bind host domain name. Back to the host management panel of the new server, bind the domain name with www and without www to the host server at the same time.

650) this.width=650; "id=" aimg_1237 "src=" http://bbs.dbfen.com/data/attachment/forum/201409/17/ 170354yjne5xbb2lttb1nq.jpg "class=" Zoom "width=" 141 "style=" border:0px; "alt=" 170354yjne5xbb2lttb1nq.jpg "/>

six, the server replacement is complete. After a short wait, progress smoothly, the server should have migrated the new server host, open the Web site to check all the content of the page, sick log in the background, check the website plug-ins, themes, templates and other normal, if there is lost files, re-upload back.
Seven, finally in the new server host re-set 301 Redirect, pseudo-static, 404 pages and other operations.
the whole process is simple and fast, will not bring too much negative impact on the site, except the resolution time (the most external night resolution), to ensure that the site has been in an accessible state, in terms of users, it will not cause too much inconvenience, observe the site log, look at the status of the spider return, the latest day can return to normal.


Summary: If as an SEO, will not be a site to move is an unjustifiable and very embarrassing things, this kind of foundation but the operation of no reason not to master. In the process of operation, because of the omission and the server host and other various problems, it will inevitably occur when the replacement is unsuccessful, someone willing to help always warm heart.

Article sharing from multi-backup forum http://bbs.dbfen.com/thread-1940-1-1.html



This article is from the "Big Meatball" blog, please make sure to keep this source http://12478147.blog.51cto.com/9663367/1585007

How to replace a server on a PHP website

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.