Question

How to accesss phpMyAdmin on Debian?

Posted April 22, 2019 571 views
MySQLPHPDebianDatabases

I just installed phpMyAdmin on my Debian VPS, via apt-get.
Now how to access it?

Opening xxx.xxx.xxx.xxx/phpmyadmin on browser gives this:
The requested URL /phpmyadmin was not found on this server.

These answers are provided by our Community. If you find them useful, show some love by clicking the heart. If you run into issues leave a comment, or add your own answer to help others.

×
2 answers

KIndly reboot your server and try again,
if that dosnt work run this command
sudo apt-get update && apt-get upgrade -y

that should fix it

if not then read your error logs for a more detailed issue

  • Nope, didn’t work.
    Previously I installed phpMyAdmin with the same way (before destroying my old droplet), and it worked.
    If I remember it well, there’s no phpmyadmin related dir in /var/www/html.
    So it must be on another directory.

    Hmm let’s start digging…

Hello,

Did the reboot, suggested by @thousifme18 solve your problem? If not, here are some ideas:

  • Kindly note that usually URL is case sensitive. Ie. PhpMyAdmin folder’s name is phpMyAdmin but you are trying to access example.com/phpmyadmin

Firewall

  • Check *port 80 * on Firewall

    sudo iptables -A INPUT -p tcp --dport 80 -m conntrack --ctstate NEW,ESTABLISHED -j ACCEPT
    sudo iptables -A OUTPUT -p tcp --sport 80 -m conntrack --ctstate ESTABLISHED -j ACCEPT
    
  • Check if *port 3306 * inbound allowed on Firewall

sudo iptables -A INPUT -i eth1 -p tcp --dport 3306 -m conntrack --ctstate NEW,ESTABLISHED -j ACCEPT
sudo iptables -A OUTPUT -o eth1 -p tcp --sport 3306 -m conntrack --ctstate ESTABLISHED -j ACCEPT

More info available at https://www.digitalocean.com/community/tutorials/iptables-essentials-common-firewall-rules-and-commands

phpMyAdmin Config

Felipe

by Mitchell Anicas
Iptables is the software firewall that is included with most Linux distributions by default. This cheat sheet-style guide provides a quick reference to iptables commands that will create firewall rules are useful in common, everyday scenarios. This includes iptables examples of allowing and blocking various services by port, network interface, and source IP address.
Submit an Answer