Connect to a database with a temporary MySQL hostname

Overview

You can access your database while the DNS of your primary site is not pointed to DreamHost. This requires three steps:

  1. Create a new dreamhosters.com subdomain (for example: example.dreamhosters.com).
  2. Using that subdomain, create a MySQL hostname.
  3. Use this MySQL hostname to access your database via phpMyAdmin.
 

Step 1 — Adding a dreamhosters.com subdomain

Add a free dreamhosters.com subdomain (for example: example.dreamhosters.com) that mirrors your primary domain on the Hosted Domains page.

For more detailed instructions about this process, please view the following article:

Step 2 — Adding a MySQL hostname

To add a hostname for your new subdomain:

  1. Navigate to the MySQL Databases page.
    The MySQL Databases page opens:
    Accessing your Database add hostname.fw.png
  2. Click the Add New Hostname button.
    The ‘Add a MySQL Hostname’ page opens:
    Accessing your Database add hostname.fw.png

    In the above example:

    • The primary domain is “example.dreamhosters.com”.
    • The MySQL hostname is “mysql.example.dreamhosters.com”.
  3. Enter the hostname prefix of your choice (commonly "mysql"), and then select the new subdomain using the dropdown menu.
  4. Click the Create this MySQL hostname now! button to finish.

Step 3 — Accessing your database with phpMyAdmin

Once the DNS changes propagate (which may take anywhere from 4 to 24 hours), you are then able to access the phpMyAdmin MySQL management utility using the mysql hostname you just created. In the example above, it would be mysql.example.dreamhosters.com.

If you try to access phpMyAdmin before the MySQL hostname's DNS records are updated, DreamHost's phpMyAdmin interface is unable to recognize your login information.

For further information about phpMyAdmin and how to log in, please view the following article:

See also

Did this article answer your questions?

Article last updated PST.

Still not finding what you're looking for?