注册 登录  
 加关注
   显示下一条  |  关闭
温馨提示!由于新浪微博认证机制调整,您的新浪微博帐号绑定已过期,请重新绑定!立即重新绑定新浪微博》  |  关闭

Wei Ding blog

 
 
 

日志

 
 

【转载】apache安装 错误调试  

2016-11-18 10:37:33|  分类: apache & mysql |  标签: |举报 |字号 订阅

  下载LOFTER 我的照片书  |
本文转载自jefka1211《apache安装 错误调试》

原因一:80端口占用例如IIS,另外就是迅雷。我的apache服务器就是被迅雷害得无法启用!

原因二:软件冲突装了某些软件会使apache无法启动如Dr.com 你打开网络连接->TcpIp属性->高级->WINS标签 把netbios的lmhosts对勾去掉,禁用tcp/ip的netbios. 然后再启动应该就可以了。

原因三:httpd.conf配置错误如果apache的配置文件httpd.conf搞错了,在windows里启动它,会提示the requested operation has failed,这是比较郁闷的事,因为查错要看个半天。 其实可以用命令行模式启动apache,并带上参数,apache会提示你哪句有误,然后就可以针对性的解决。

检查错误方法:进入cmd 然后进入 Apache安装目录(具体为你自己的安装目录)\bin> httpd.exe -w -n "Apache2" -k start

一些常见报错

1。httpd: Syntax error on line 54 of /usr/local/webserver/apache2/conf/httpd.conf: module status_module is built-in and can't be loaded
      答:mod_status.so已经为内置了,注释掉就OK了。


2。 httpd: Syntax error on line 81 of /usr/local/webserver/apache2/conf/httpd.conf: Expected </IfModul> but saw </IfModule>
    答:这是因为</IfModul>没有匹配成对使用。 

3。Object not found    404  有可能地址被重定向,httpd-vhosts.conf注释掉。


Starting httpd: Syntax error on line 358 of /etc/httpd/conf/httpd.conf:
Invalid command ' Order ', perhaps mis-spelled or defined by a module not included
in the server configuration               
需添加:
LoadModule access_module /etc/httpd/modules/mod_access.so
LoadModule auth_module /etc/httpd/modules/mod_auth.so


Starting httpd: Syntax error on line 368 of /etc/httpd/conf/httpd.conf:
Invalid command 'UserDir ', perhaps mis-spelled or defined by a module not includ
ed in the server configuration
需添加: LoadModule userdir_module /etc/httpd/modules/mod_userdir.so


Starting httpd: Syntax error on line 396 of /etc/httpd/conf/httpd.conf:
Invalid command 'DirectoryIndex ', perhaps mis-spelled or defined by a module not
included in the server configuration 
需添加: LoadModule dir_module /etc/httpd/modules/mod_dir.so


Starting httpd: Syntax error on line 419 of /etc/httpd/conf/httpd.conf:
Invalid command 'TypesConfig ', perhaps mis-spelled or defined by a module not in
cluded in the server configuration
需添加: LoadModule mime_module /etc/httpd/modules/mod_mime.so


Starting httpd: Syntax error on line 491 of /etc/httpd/conf/httpd.conf:
Invalid command 'LogFormat ', perhaps mis-spelled or defined by a module not incl
uded in the server configuration                 
需添加: LoadModule log_config_module /etc/httpd/modules/mod_log_config.so


Starting httpd: Syntax error on line 555 of /etc/httpd/conf/httpd.conf:
Invalid command 'Alias ', perhaps mis-spelled or defined by a module not included
in the server configuration            
需添加: LoadModule alias_module /etc/httpd/modules/mod_alias.so


Starting httpd: Syntax error on line 582 of /etc/httpd/conf/httpd.conf:
Invalid command 'SetEnvIf ', perhaps mis-spelled or defined by a module not inclu
ded in the server configuration          
需添加: LoadModule setenvif_module /etc/httpd/modules/mod_setenvif.so


Starting httpd: Syntax error on line 636 of /etc/httpd/conf/httpd.conf:
Invalid command 'IndexOptions ', perhaps mis-spelled or defined by a module not i
ncluded in the server configuration
需添加: LoadModule autoindex_module /etc/httpd/modules/mod_autoindex.so


Starting httpd: Syntax error on line 784 of /etc/httpd/conf/httpd.conf:
Invalid command 'LanguagePriority ', perhaps mis-spelled or defined by a module n
ot included in the server configuration
需添加:LoadModule negotiation_module /etc/httpd/modules/mod_negotiation.so


http://jafy00.blog.51cto.com/2594646/759925

报错 : configuration error: couldn't check user

解决:
LoadModule authz_core_module modules/mod_authz_core.so

LoadModule authn_file_module modules/mod_authn_file.so

LoadModule authz_user_module  modules/mod_authz_user.so

LoadModule auth_basic_module  modules/mod_auth_basic.so

  评论这张
 
阅读(42)| 评论(0)
推荐 转载

历史上的今天

在LOFTER的更多文章

评论

<#--最新日志,群博日志--> <#--推荐日志--> <#--引用记录--> <#--博主推荐--> <#--随机阅读--> <#--首页推荐--> <#--历史上的今天--> <#--被推荐日志--> <#--上一篇,下一篇--> <#-- 热度 --> <#-- 网易新闻广告 --> <#--右边模块结构--> <#--评论模块结构--> <#--引用模块结构--> <#--博主发起的投票-->
 
 
 
 
 
 
 
 
 
 
 
 
 
 

页脚

网易公司版权所有 ©1997-2017