How to Install Phpmyadmin in Ubuntu Server?

By Hardik Savani November 5, 2023 Category : Ubuntu Server

Hi,

I am going to show you example of how to install phpmyadmin in ubuntu. This tutorial will give you simple example of install phpmyadmin ubuntu 20.04 apache2. This article will give you simple example of ubuntu server install phpmyadmin. i explained simply step by step phpmyadmin install linux ubuntu. Let's see bellow example ubuntu server 18.04 install phpmyadmin.

Here, i will give you list of commands step by step, how to install phpmyadmin in ubuntu 21.10, ubuntu 21.04, ubuntu 20.04, ubuntu 18.04 and ubuntu 16.04. So let's see following command and install phpmyadmin.

Install MySQL on Ubuntu

Update Local Package:

sudo apt update

Install MySQL Server:

sudo apt install mysql-server

Install Phpmyadmin:

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

Create User on MySQL:

you can create new user for mysql by using following query:

mysql -u root -p

CREATE USER 'root_new'@'localhost' IDENTIFIED BY 'rootnewpassword';

GRANT ALL PRIVILEGES ON * . * TO 'root_new'@'localhost';

FLUSH PRIVILEGES;

Now you can go to your browser and open IP or localhost then you will found bellow layout:

http://localhost/localhost/phpmyadmin

http://your_domain_or_IP/phpmyadmin

Output:

Solved Error: the requested url was not found on this server. phpmyadmin

IF it's still not open and you found following error:

"the requested url was not found on this server. phpmyadmin"

Then you can do it following step:

Open apache.conf file:

sudo nano /etc/apache2/apache2.conf

Then add following line to the end of file.

Include /etc/phpmyadmin/apache.conf

Restart Apache:

sudo /etc/init.d/apache2 restart

Now it will works.

I hope it can help you...

Tags :
Shares