From ArchWiki
Jump to: navigation, search

deny from all (.htaccess for phpmyadmin)

Commenting out 'deny from all' as the article states will allow everyone access. Wouldn't a safer way to do this be:

deny from all
allow from localhost
allow from

Or something to this extent? Axanon 06:54, 19 June 2011 (EDT)

A note addresses your issue in the meantime. Dinghy (Talk) 20:57, 15 January 2016 (UTC)

Helpful info regarding config file, open_basedir, and a sample Nginx "sub-folder"

I ran into some issues while configuring. It took me a really long time to realize why my file wasn't being read after updating it.

The Wiki page currently states:

Update open_basedir in /etc/php/php.ini and add "/usr/share/webapps/".

It should emphasize that /etc/webapps is needed. This is very important and I spent a lot of time debugging.

The wiki page should mention that the configuration file is located in /etc/webapps/phpmyadmin (unless it already does. Maybe I overlooked it?)

Also, here is a sample configuration for using PHPMyAdmin as a sub-folder instead of a document root. It assumes PHPMyAdmin is linked at /srv/http/phpmyadmin. This may not be perfect but it is working for me. It follows the current configuration instructions and doesn't stray away from them as far as I can tell.

server {
   location /phpmyadmin {
       root           /srv/http/;
       index          index.php;
   location ~ ^/phpmyadmin.+.php$ {
       root           /srv/http/; # Assumes PHPMyAdmin is linked at /srv/http/phpmyadmin
       fastcgi_pass   unix:/var/run/php-fpm/php-fpm.sock;
       fastcgi_index  index.php;
       fastcgi_param  SCRIPT_FILENAME  $document_root$fastcgi_script_name;
       include        fastcgi_params;

--Kurtis (talk) 00:24, 6 May 2013 (UTC)

This works for me. The main page wiki method gets me "not found". Thanks--Xan (talk) 14:51, 29 January 2015 (UTC)
The PHP section now says "You need to make sure that PHP can access /etc/webapps. Add it to open_basedir in /etc/php/php.ini if necessary:...". Did you do that? Lonaowna (talk) 17:25, 29 January 2015 (UTC)
If I recall well, I encountered this problem at some point. But this is fixed by default now that open_basedir is not set anymore. Dinghy (Talk) 21:03, 15 January 2016 (UTC)

I tried setting open_basedir "open_basedir=/etc/webapps" it caused a server error (500), we should add something about leaving it as is. Chrisfryer78 (talk) 00:12, 20 January 2016 (UTC)


When http://localhost/phpmyadmin/setup/ work properly but

http://localhost/phpmyadmin/ start with "The mysqli/mysql extension is missing"

please check on php.ini "mysqli.allow_persistent = On" and uncomment.

Restart httpd.

—This unsigned comment is by Tinosezc (talk) 13:05, 5 December 2014‎ . Please sign your posts with ~~~~!

mysqli.allow_persistent = On is the default, not sure if this needs to be mentioned in PhpMyAdmin#PHP. -- Lahwaacz (talk) 13:19, 5 December 2014 (UTC)
It is the default, probably came from a mangled configuration after port/update/edit. Dinghy (Talk) 21:00, 15 January 2016 (UTC)

Reason of last config


What's the purpose of this section? whem I login in with 'pma' user, I can't create databases (not enough privileges). Is not correct?--Xan (talk) 12:14, 1 February 2015 (UTC)

Yes, that's correct, 'pma' is the username under which PhpMyAdmin gathers statistics and informations about relationships beyond what is built into MySQL. Dinghy (Talk) 00:11, 8 January 2016 (UTC)