[英]Apache authentification error
I've installed Apache 2.2 on my Debian-based distr (kernel 3.2.0-27) and apache2.2-common package with default configs. 我已经在基于Debian的distr(内核3.2.0-27)和apache2.2-common软件包中使用默认配置安装了Apache 2.2。
Trying to run simple script info.php I got the error found in /var/log/apache2/error.log: 尝试运行简单的脚本info.php时,在/var/log/apache2/error.log中发现了错误:
[Wed Jul 16 09:17:08 2014] [crit] [client 127.0.0.1] configuration error: couldn't perform authentication. AuthType not set!: /info.php
I've searched for hours in the internet, but haven't found solution. 我已经在互联网上搜索了数小时,但没有找到解决方法。
Script info.php: 脚本info.php:
<?php
phpinfo();
?>
Config files: 配置文件:
/etc/apache2/apache2.conf: /etc/apache2/apache2.conf中:
...
Include httpd.conf
Include ports.conf
Include conf.d/
Include sites-enabled/
...
/etc/apache2/httpd.conf is clear. /etc/apache2/httpd.conf很清楚。
/etc/apache2/ports.conf: /etc/apache2/ports.conf:
...
NameVirtualHost *:80
Listen 80
...
/etc/apache2/conf.d/security: /etc/apache2/conf.d/security:
...
ServerSignature On
TraceEnable Off
...
/etc/apache2/sites-enabled/@000-default (link to /etc/apache2/sites-available/default): / etc / apache2 / sites-enabled / @ 000-default(链接到/ etc / apache2 / sites-available / default):
<VirtualHost *:80>
ServerAdmin webmaster@localhost
DocumentRoot /var/www
<Directory />
Options FollowSymLinks
AllowOverride None
</Directory>
<Directory /var/www/>
Options Indexes FollowSymLinks MultiViews
AllowOverride None
Order allow,deny
allow from all
</Directory>
ScriptAlias /cgi-bin/ /usr/lib/cgi-bin/
<Directory "/usr/lib/cgi-bin">
AllowOverride None
Options +ExecCGI -MultiViews +SymLinksIfOwnerMatch
Order allow,deny
Allow from all
</Directory>
ErrorLog ${APACHE_LOG_DIR}/error.log
# Possible values include: debug, info, notice, warn, error, crit,
# alert, emerg.
LogLevel warn
CustomLog ${APACHE_LOG_DIR}/access.log combined
</VirtualHost>
List of loaded modules (got by apache2ctl -M
): 加载的模块列表(由
apache2ctl -M
):
apache2: Could not reliably determine the server's fully qualified domain name, using 127.0.0.1 for ServerName
Loaded Modules:
core_module (static)
authn_file_module (static)
authn_default_module (static)
authz_default_module (static)
log_config_module (static)
logio_module (static)
mpm_prefork_module (static)
http_module (static)
so_module (static)
alias_module (shared)
authz_groupfile_module (shared)
authz_host_module (shared)
authz_user_module (shared)
autoindex_module (shared)
cgi_module (shared)
deflate_module (shared)
dir_module (shared)
env_module (shared)
mime_module (shared)
negotiation_module (shared)
reqtimeout_module (shared)
setenvif_module (shared)
status_module (shared)
Syntax OK
What changes should I make to make server work? 我应该进行哪些更改才能使服务器正常工作?
looks like you might not have the php mod loaded. 看起来您可能没有加载php mod。 uncomment or add the line "LoadModule php5_module path/to/the/file/libphp5.so" in httpd.conf, obv putting in the actual filepath
取消注释或在httpd.conf中添加“ LoadModule php5_module path / to / the / file / libphp5.so”行,然后输入实际的文件路径
Sorry, guys, I've found out that I work not with original Apache but with its custom build in which work without authorization is disabled. 抱歉,伙计们,我发现我不是使用原始Apache,而是使用其自定义构建,其中未经授权的工作被禁用。 Thanks for your comments.
感谢您的意见。
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.