PhpMyAdmin is a free and open-source administration tool for MySQL and MariaDB. Assuming you have already installed MariaDB or MySQL on your Ubuntu VPS, this guide will walk you through the process of setting up PhpMyAdmin.

Step 1: Update Package Index

  • First, update your package list:

    sudo apt update

Step 2: Install PhpMyAdmin

  • Install PhpMyAdmin and its dependencies:

    sudo apt install phpmyadmin php-mbstring php-zip php-gd php-json php-curl

Step 3: Configure Database for PhpMyAdmin

  • During the installation, you'll be prompted to choose a web server to configure. Select the appropriate option (e.g., Apache).

  • When asked to configure the database for PhpMyAdmin with dbconfig-common, select 'Yes'.

  • Enter your database password when prompted to secure your PhpMyAdmin installation.

Step 4: Enable PHP Extensions

  • Enable necessary PHP extensions:

    sudo phpenmod mbstring sudo systemctl restart apache2

Step 5: Accessing PhpMyAdmin

  • Access PhpMyAdmin through your web browser by navigating to your server's domain name or IP address followed by '/phpmyadmin'. For example:

    http://your_server_ip/phpmyadmin

Step 6: Log in to PhpMyAdmin

  • Use your MariaDB/MySQL username and password to log in.

Securing PhpMyAdmin

  • It’s recommended to secure your PhpMyAdmin instance. Consider setting up an .htaccess file or configuring HTTPS to encrypt your data.

Conclusion

With PhpMyAdmin installed on your Ubuntu VPS, you can easily manage your MariaDB or MySQL databases through a web interface. Remember to keep your PhpMyAdmin installation updated and secure your setup to protect sensitive database information.

Was this answer helpful? 0 Users Found This Useful (0 Votes)