Managing a MySQL database with phpMyAdmin


  • Applies to: Grid
    • Difficulty: Medium
    • Time Needed: 20
    • Tools Required: AccountCenter access, database user login
  • Applies to: DV
    • Difficulty: Medium
    • Time Needed: 20
    • Tools Required: Plesk administrator access, database user login
  • Applies to: DV 4.0
    • Difficulty: Medium
    • Time Needed: 20
    • Tools Required: Plesk administrator access, database user login
  • Applies to: WordPress
    • Difficulty: Medium
    • Time Needed: 20
    • Tools Required: AccountCenter access, database user login

CloudTech_ProductPage_217x57

CloudTech Can Help!

If you're having trouble with the steps in this article, additional assistance is available via CloudTech, our premium services division. Our expert engineers can assist in administering your MySQL environment for optimal performance. For more information on what CloudTech can do for you, please click here.

Overview

The following guide will show you how to access phpMyAdmin for your Grid and how to perform some basic operations on your databases. as the root MySQL user, "admin." This is necessary for performing higher-level database tasks, such as importing an SQL backup file or changing permissions on a database user.

Accessing phpMyAdmin for your Grid

You can access phpMyAdmin directly by visiting the following URL:

https://s00000.gridserver.com/.tools/phpMyAdmin/index.php

Log in with your database username and password. If you receive a login error, please try clearing your browser cache.

You can also access phpMyAdmin from the AccountCenter.

  1. Log into your AccountCenter.
  2. Select your primary domain name from the Domains tab.

    426_domains

  3.  Select Manage Databases from the Databases menu.

    426_managedb

  4. Click on the gear next to the database you wish to edit. phpMyAdmin will launch in a new window.

    426_manage_db

  5. Log into phpMyAdmin with your database username and password.

    Gs phpmyadmin login.png

    We recommend to create a new Database User. This way, you will not interfere with existing applications.

    NOTE:

    phpMyAdmin will often keep incorrect login information cached in your browser. If you get a login error, please try clearing your browser cache. See Errors logging into phpMyAdmin for details on this error. If you still receive an error, please reset your database password. Not sure how? Read: Changing the password for a Database User.

You will now be able to administer your databases through phpMyAdmin. Your session will time out after 30 minutes of inactivity.

Accessing phpMyAdmin for your DV server

Accessing phpMyAdmin for your DV

  1. Log into the Plesk Control Panel for your domain:

    If you log into Plesk with the admin user, you will be in the Server Administration Panel by default. To get to the Control Panel, click on Domains, then on the Control Panel link next to your domain.

    You can also create a user that will log into the Control Panel by default, which will save you a few clicks on day-to-day webmaster tasks. See Control Panel user.

  2. From the Home page, click on Websites & Domains.

  3. Click on Databases.

  4. Your databases are listed. Click on the name of the one you'd like to access phpMyAdmin. For this example, we select the database mynewdb.

  5. Click Webadmin. This will open phpMyAdmin in a new tab or window, depending on your browser preferences.

Accessing phpMyAdmin for your WordPress Hosting service

You can access phpMyAdmin directly from the SETTINGS panel of your WordPress Hosting site in the AccountCenter.

  1. Log into your AccountCenter.
  2. Select your primary domain name from the Domains tab.
  3. Click on the site you would like to access the database for.
  4. Click on the SETTINGS link from the menu to the left.
    131_wp_settings
  5. Click on the Login button for phpMyAdmin.
    phpmyadmin_button
  6. phpMyAdmin will then launch and you will have access to your database.

You will now be able to administer your databases through phpMyAdmin.

Basic operations

CAUTION:

Before making any changes to your database(s), please consider making a backup:

Here are some basic operations you can perform on your databases and tables in phpMyAdmin:

  1. Select the database you want to use from the list on the left.

  2. Select the tables you want to use. When optimizing or repairing, you should select Check All.

    Phpmyadmin check all.png

  3. In the "With selected" dropdown menu, select one of the following:

    Phpmyadmin dropdown repair.png

    CAUTION:

    The "Empty" and "Drop" actions will remove content from your database. Please do not do this unless you are sure you want to remove this content.

    • Empty - This will empty all data from the selected tables.
    • Drop - This will drop (delete) the selected tables.
    • Check Table - This will check the tables for errors.
    • Optimize Table - This will perform some basic table optimizations.
    • Repair Table - This will attempt to repair your tables.
    • Analyze Table - This will analyze your tables.

NOTE:

Exporting and then re-importing your database may improve its optimization. This article explains in detail how to export and import MySQL databases:

Troubleshooting

If you are having issues logging into phpMyAdmin:

If you have a crashed database table:

  1. Select any tables that are marked as "in use" in phpMyAdmin.
  2. In the "With selected" dropdown menu, select the "Repair table" option.
  3. MySQL will now attempt to repair the crashed table. The repair operation may take a while to complete, depending on the size of the table.