Skip to content

How-to Guides

Technical References

Prepare for Site Launch /

Migrate content: Databases

To migrate content onto VIP Go, we need two assets:

  1. The database file as a SQL dump, and
  2. The media as a compressed archive.

Files to import can be attached to a Zendesk ticket — or files larger than 20 MB can be transferred via sending us a web-accessible link to the files (eg https://www.mysite.com/uploads.tar.gz). You may also use Amazon S3, Dropbox, Box, WeTransfer, or another similarly secure service. Please also be sure to include the domain name of the VIP Go environment the import is for.

Exporting

To make your database available to VIP, you must first export a backup copy from your local or current, non-VIP production instance. Two such methods are using mysqldump from the command line, or via a third-party WordPress plugin such as WP Migrate DB Pro. Here is a sample mysqldump command:

mysqldump --add-drop-table --hex-blob --no-create-db --quote-names -h dbhost -u user -p dbname --default-character-set=utf8mb4 --result-file=dbname-full.sql

Other methods for exporting your database, including using phpMyAdmin, are detailed on WordPress.org.

Database formatting checklist

Once you have exported your database, please confirm:

  • Will domains need to be replaced on import? For instance, changing a domain used in a local environment (example.test) or running production instance (example.com) to the pre-launch VIP convenience domain (example.go-vip.net)?
  • Verify the tables prefixed with wp_.
  • Ensure that a DROP TABLE IF EXISTS statement is included before each CREATE TABLEstatement.
  • Remove all CREATE DATABASE or USE statements.
  • Exclude any unused tables, such as custom tables from plugins no longer in use.

You can use the VIP CLI command vip import validate-sql to verify the format of your SQL file.

In addition, for multisite

Are you importing into a Multisite Network? If so:

  • Your database needs to also be from a multisite.
  • If importing subsite tables, ensure the table prefixes match the intended destination site ID (e.g. tables prefixed wp_3_ will be imported to subsite 3).
  • If you are importing an entire multisite network, does your export have the wp_site and wp_blogs tables?
  • If you are importing only individual subsites, are those the only tables included in your export?

Submitting the database

Please open a new Zendesk ticket for each import. Your database can be attached to the Zendesk ticket; or, if it’s larger than 20 MB, it can be transferred via sending us a web-accessible link to the files (e.g. https://www.example.com/uploads.tar.gz). You may also use Amazon S3, Dropbox, Box, WeTransfer, or another similar service.

When you submit your database, please list domains included in the database and what you’d like them replaced with, if needed. If necessary, we will perform a search-replace to change these values to match your VIP environment. This is the only modification VIP expects to perform on your database; it will otherwise be imported as-is. All tables provided will be replaced.

If your SQL file includes the wp_users table, this will replace your VIP environment’s users table, meaning your username and login in our environment may change after the import.

QA

Once we confirm that your database has been imported into your VIP environment, you’ll want to perform some quality assurance testing to ensure it matches your expectations. Here are some ways to test your site.

Reference

WordPress core database description

Last updated: November 04, 2020