PMA 4.5.2.0 file_exists(): open_basedir restriction in effect

荒凉一梦 提交于 2019-12-11 01:52:31

问题


After installing phpMyAdmin on my Ubuntu server from PPA

https://launchpad.net/~nijel/+archive/ubuntu/phpmyadmin

I get a series of warnings. Thanks in advance!

Warning in ./libraries/Util.class.php#521 file_exists(): open_basedir restriction in effect. File(doc/html/index.html) is not within the allowed path(s): (/tmp/:/usr/share/phpmyadmin/:/etc/phpmyadmin/:/var/lib/phpmyadmin/:/usr/share/php/php-gettext/:/usr/share/javascript/:/usr/share/php/tcpdf/)

Backtrace

./libraries/Util.class.php#521: file_exists(string 'doc/html/index.html') ./libraries/sanitizing.lib.php#92: PMA_Util::getDocuLink( string 'faq', string 'faq3-11', ) PMA_replaceDocLink(array) ./libraries/sanitizing.lib.php#152: preg_replace_callback( string '/\[doc@([a-zA-Z0-9_-]+)\]/', string 'PMA_replaceDocLink', string 'Podría ser aproximado. Pulse en el número para obtener la cantidad exacta. Ver [doc@faq3-11]FAQ 3.11.', ) ./templates/database/structure/table_header.phtml#43: PMA_sanitize(string 'Podría ser aproximado. Pulse en el número para obtener la cantidad exacta. Ver [doc@faq3-11]FAQ 3.11[/doc].') ./libraries/Template.class.php#80: include(./templates/database/structure/table_header.phtml) ./libraries/controllers/DatabaseStructureController.class.php#224: PMA\Template->render(array) ./db_structure.php#54: PMA\Controllers\DatabaseStructureController->indexAction()


回答1:


Forget it, I found the answer!

In my Ubuntu Server 14.04, I edited the file /etc/phpmyadmin/apache.conf, and searched for the following line:

php_admin_value open_basedir /usr/share/phpmyadmin/:/etc/phpmyadmin/:/var/lib/phpmyadmin/:/usr/share/php/php-gettext/:/usr/share/javascript/:/usr/share/php/tcpdf/

And added :/usr/share/doc/phpmyadmin/ at the end and the warning went away!



来源:https://stackoverflow.com/questions/34212107/pma-4-5-2-0-file-exists-open-basedir-restriction-in-effect

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!