04. Creating and Managing MySQL Databases Print

  • 0

Creating and Managing MySQL Databases

Most modern websites (including WordPress, Magento, and Joomla) are database-driven. This means your text, settings, and user data aren't stored in files but in a MySQL Database. At Jiinubi, you can easily create and manage these databases through cPanel.


The 3-Step Process to Create a Database

To connect a website to a database, you need three things: the Database Name, a Database User, and Permissions to link them.

Step 1: Create the Database

  1. Log in to your Jiinubi Client Area and enter cPanel.
  2. Scroll to the Databases section and click MySQL Databases.
  3. Under Create New Database, enter a name (e.g., store).
  4. Click Create Database.
Note: Your database name will appear as username_store, where username is your cPanel account name.

Step 2: Create the Database User

  1. Scroll down to MySQL Users > Add New User.
  2. Enter a Username (e.g., dbuser).
  3. Enter a strong Password. Use the Password Generator for maximum security.
  4. Click Create User.

Step 3: Link the User to the Database

  1. Scroll down to Add User To Database.
  2. Select your User and Database from the dropdown menus.
  3. Click Add.
  4. On the next screen, check the box for ALL PRIVILEGES and click Make Changes.

Managing Data via phpMyAdmin

If you need to edit the data inside your tables (e.g., reset a WordPress password or change a URL), use phpMyAdmin:

  1. From the cPanel home screen, click phpMyAdmin.
  2. On the left sidebar, click the name of your database to see its tables.
  3. From here, you can Browse data, Search for specific entries, or Export the database as a backup.

Important Database Details

When your website's configuration file (like wp-config.php) asks for database details, use these:

  • Database Host: localhost
  • Database Name: username_databasename
  • Database User: username_dbuser
  • Password: The password you created in Step 2

Common Troubleshooting

Issue Solution
"Error Establishing a Database Connection" Double-check your username_ prefix. Many forget that the cPanel username is part of the database and user name.
"Access Denied" Ensure the password in your website's config file is correct, and that you linked the user to the database (Step 3).
Database is slow Shared Hosting has limited resources. Clean queries and optimized code improve speed; Jiinubi Cloud Hosting provides enhanced performance.

Backing Up Your Database

  1. Go to phpMyAdmin.
  2. Select your database.
  3. Click the Export tab at the top.
  4. Click Go to download a .sql file to your computer.

Was this answer helpful?

« Back