PhpMyAdmin 错误 500 PHP-GETTEXT

标签 php mysql phpmyadmin open-basedir php-gettext

我今天更新了我的服务器,实际上当我访问 mywebsite.com/phpmyadmin/=> 时,我收到了错误 500

错误日志:

PHP Warning:  require_once(): open_basedir restriction in effect. File(/usr/share/php/php-php-gettext/gettext.inc) is not within the allowed path(s): (/usr/share/phpmyadmin/:/etc/phpmyadmin/:/var/lib/phpmyadmin/:/usr/share/php/php-php-gettext/:/usr/share/javascript/:/usr/share/php/tcpdf/:/usr/share/doc/phpmyadmin/:/usr/share/php/phpseclib/) in /usr/share/phpmyadmin/libraries/common.inc.php on line 77

PHP Warning:  require_once(/usr/share/php/php-php-gettext/gettext.inc): failed to open stream: Operation not permitted in /usr/share/phpmyadmin/libraries/common.inc.php on line 77

PHP Fatal error:  require_once(): Failed opening required '/usr/share/php/php-php-gettext/gettext.inc' (include_path='.') in /usr/share/phpmyadmin/libraries/common.inc.php on line 77

我的 apache.conf:

http://pastebin.com/YZRXGmas

我的 php.ini:

http://pastebin.com/Mt8uE0P9

我的/usr/share/php:

drwxr-xr-x   2 root root  4096 févr.  1 00:29 php-gettext
drwxr-xr-x   2 root root  4096 févr.  1 00:16 php-php-gettext

在/usr/share/php/php-gettext 中:

lrwxrwxrwx  1 root root   30 janv. 29 16:13 gettext.inc -> ../php-php-gettext/gettext.inc
lrwxrwxrwx  1 root root   30 janv. 29 16:13 gettext.php -> ../php-php-gettext/gettext.php
lrwxrwxrwx  1 root root   30 janv. 29 16:13 streams.php -> ../php-php-gettext/streams.php

在/usr/share/php/php-php-gettext 中:

lrwxrwxrwx  1 root root   30 janv. 29 16:13 gettext.inc -> ../php-php-gettext/gettext.inc
lrwxrwxrwx  1 root root   30 janv. 29 16:13 gettext.php -> ../php-php-gettext/gettext.php
lrwxrwxrwx  1 root root   11 févr.  1 00:16 php-gettext -> php-gettext
lrwxrwxrwx  1 root root   30 janv. 29 16:13 streams.php -> ../php-php-gettext/streams.php

我的 PHP-GetText 版本:

php-mbstring is already the newest version (1:7.0+49).
php-gettext is already the newest version (1.0.12-0.1).
php7.0-mbstring is already the newest version (7.0.15-1).

我测试了很多东西,但对我的服务器没有任何作用:\有人可以帮助我吗?

真诚的,

最佳答案

将/usr/share/php/php-php-gettext 添加到/etc/apache2/conf-enabled/phpmyadmin.conf 中的 open_basedir 设置

关于PhpMyAdmin 错误 500 PHP-GETTEXT,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/41969973/

相关文章:

php - 如何连接列中某些值相同的两个表

php - 在 MySQL 中以逗号分隔的文本字段中查找值?

mysql - 如何将 csv-import 西里尔文本导入 PhpMyAdmin 中的 latin1-swedish-ci 编码表中?

php - 如何使用 bitnami/linux 终端更改我的 php 应用程序的 php 版本

mysql - phpmyadmin 中的 `Virtuality` 是什么?

javascript - 从外部页面查找 javascript 错误,将结果输出到文件

mysql - 更新多个表中的值时复制记录

mysql - 使用 Foreign KEY 执行 SQL 时出错

php - 从 MYSqL 数据库获取数据时出错

javascript - php 中表单类型范围 undefined index