Report this

What is the reason for this report?

Phpmyadmin problem with Nginx

Posted on July 17, 2014

I followed this tutorial to install and configure phpmyadmin on a LEMP stack: https://www.digitalocean.com/community/tutorials/how-to-install-phpmyadmin-on-a-lemp-server.

But when I try to access it, I’m getting a 404 error. Do I need to create a server block for phpmyadmin? The symbolic link is in /var/www pointing to /usr/share/phpmyadmin so I’m confused about whats going on.

Any help would be appreciated.

Thanks, Rickey



This textbox defaults to using Markdown to format your answer.

You can type !ref in this text area to quickly search our full set of tutorials, documentation & marketplace offerings and insert the link!

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.

That guide is the most annoying way to do phpmyadmin. Download and place phpmyadmin in your root dir for the vhost e.g root /var/www; Then goto domain.com/phpmyadmin

Vhost example phpmyadmin dowload

If your vhost is missing the php socket location here.

        location ~ \.php$ {
                try_files $uri =404;
                fastcgi_split_path_info ^(.+\.php)(/.+)$;
                fastcgi_pass unix:/var/run/php5-fpm.sock;
                fastcgi_index index.php;
                include fastcgi_params;
        }

I did as you suggested and simply downloaded phpmyadmin into /var/www/phpmyadmin and all my problems were resolved. As you said, sometimes doing something in a simple and straightforward way is better.

Anyway, thanks for your help; it’s much appreciated.

The developer cloud

Scale up as you grow — whether you're running one virtual machine or ten thousand.

Get started for free

Sign up and get $200 in credit for your first 60 days with DigitalOcean.*

*This promotional offer applies to new accounts only.