• Folks, for a variety of reasons (which include being infected by malware multiple times), I decided to migrate my wordpress installation from MediaTemple’s grid server to a dedicated virtual server. What I’m looking to do is this:

    1. Install a clean version of WordPress (so that any infections or errors in the site due to subsequent malware cleanup) may be avoided
    2. Transfer all my site data (posts, pages, comments, likes etc.) to the new server – while retaining the same URL

    Based on a lot of reading (and a steep learning curve!) what I’ve done so far is this:
    1. Clean install of WP in new server
    2. Backed up and transferred the SQL database to the new server
    3. Zipped /wp-content from the old server and unzipped it (while overwriting) the mostly blank /wp-content in the new server
    4. Changed wp-config.php settings (database name, user and password) within the new WP server

    Having done so, I now note that when I try to login – all my posts and pages are missing. What am I doing wrong? My understanding was that posts / pages are contained in the database, and not in /wp-content or any of the other WP folders. Do I need to transfer ALL the files and folders in my existing WP installation – thereby nullifying the benefits of a fresh install in the new server?

    Apologies for the long post – but any help would be much appreciated. I’m not a tech guy, and have been doing a lot of reading up on how to do this! Much thanks in advance ??

Viewing 3 replies - 1 through 3 (of 3 total)
  • Do your posts and pages show up in the database that you exported and imported into your VPS? You should be able to look through phpMyAdmin or something similar to see the wp_posts table.

    Thread Starter arjunkartha

    (@arjunkartha)

    Hello John – thanks for helping out ??

    Yes, while exporting my database (from the original website) – I selected the entire database and all tables within it, which I’m assuming contained the POSTS and other tables. While importing it into the new server, they all seemed to come back. I can try again – but just to confirm my question: To transfer wordpress, is it sufficient to ONLY copy the /wp-content folder to the new server (in addition to the database?).

    Many thanks!

    When you move a site, you must replace the old URLs and paths with the new ones. Some of these are stored in the database in ‘serialized’ form where the string length is stored along with the string. You must use special tools to search and replace the old values with the new ones.

    If you replace an old URL with a new one of a different length, it will break the serialization, causing many different problems.

    If the old site is still available, you can use the steps shown in this article to copy the site: https://wordpress.mcdspot.com/2012/08/22/migrating-a-wordpress-site-step-by-step/

    If the old site is not available, and you still have a copy of the database from that site, you should be able to use this tool to make the changes: https://interconnectit.com/products/search-and-replace-for-wordpress-databases/

    Then to answer your original question, it is usually sufficient to copy the wp-contents folder and the updated database. However, there are some plugins that store things outside wp-contents, so you should keep a full backup of the original site just in case.

Viewing 3 replies - 1 through 3 (of 3 total)
  • The topic ‘WP migration to new server – questions’ is closed to new replies.