Follow Us on Google+
Follow Us on Twitter
Like us on Facebook
Subscribe to our RSS Feed

How to Create a MySQL Database in cPanel, Plesk, and DirectAdmin

How to Create a MySQL Database in cPanel, Plesk, and DirectAdmin
Posted by on May 20, 2013 in Tutorials.
 

As a webmaster or developer, one of the most common tasks that you will perform is database creation. Nowadays, creating a MySQL database is a relatively easy task, as most web hosting control panels provide you with a wizard that will guide you through the process.

In this tutorial, you will see how to create a MySQL database using the three most popular control panels: cPanel, Plesk, and DirectAdmin.

How to Create a MySQL Database Using cPanel

cPanel is the industry’s leading control panel and is used by major web hosting providers such as Bluehost, Justhost and Hostgator. To create a MySQL database with cPanel, follow these steps:

  1. Log in to your cPanel account (which is usually located at http://www.yourwebsite.com/cpanel).
  2. Type “mysql” in the Find box and click the MySQL Database Wizard icon:
    cPanel MySQL Database Wizard
  3. On the next screen, enter the name for your database and click Next Step. The full database name will include a prefix that is automatically inserted by your web hosting provider (usually your username):
    cPanel MySQL Database Creation
  4. To access the new MySQL database, you must create a user. Enter your preferred username and password and click Create User. As with the database name, your cPanel username will be used as the MySQL username prefix.
  5. On the next screen, you will be prompted to specify the access rights for the new MySQL user. Unless you want to restrict access to the database for any particular reason, check All Privileges and click Next Step to complete the creation of the database.
  6. If you wish to access your database remotely (from your desktop or from another website for instance), go back to the main page of your cPanel and click Remote MySQL. Enter the remote IP address and click on Add.

Your new MySQL database is now ready to use. To configure your web applications to use it, you will need to enter the full database name and username (including the prefix that was inserted automatically by cPanel).

With most cPanel web hosts, the MySQL hostname can be set to “localhost.” If that doesn’t work, contact your hosting provider to get the IP address of your database server. 

How to Create a MySQL Database Using Plesk

Creating a MySQL database in Plesk is just as easy as it is to create in cPanel:

  1. Log in to your Plesk control panel (usually located https://www.yourwebsite.com:8443)
  2. Select the Websites & Domains tab at the top.
  3. Click on Databases and then on Add New Database.
  4. Enter the name for the new database name and click OK:
    Plesk MySQL Database Creation
  5. Once the database is created, you must add a new MySQL user. Click on Add New Database User:
    Plesk MySQL User Creation
  6. Enter the name and password for the MySQL user account and click OK:
    mysql-plesk-3

How to Create a MySQL Database Using DirectAdmin

While DirectAdmin is bit less popular than cPanel and Plesk, it is a quite efficient control panel. Creating a MySQL database using DirectAdmin is easy:

  1. Log in to your DirectAdmin control panel (usually located http://www.yourwebsite.com:2222).
  2. Click on MySQL Management:
    DirectAdmin MySQL Management
  3. Click on Create new Database at the top.
  4. Enter the new database name, the MySQL user name, and password and click Create.
    DirectAdmin MySQL Database

Alternately, if you have root access to your web server, you can always opt to create your MySQL databases manually.

 
Tags: cpanel, directadmin, mysql, plesk

About Stephane Brault

Stephane is a web developer and system administrator with over 18 years of experience. Specialized in PHP programming and Linux server administration, he also provided development and consulting services to SMBs for several years before becoming an online entrepreneur.

0 responses so far ↓

There are no comments yet...Kick things off by filling out the form below.

Leave a Comment




Bluehost
MaxCDN - Speed Up Your Website