源代码编译安装apache启动报错

源代码编译安装apache启动报错


问题1:

httpd:apr_sockaddr_info_get()failedforcrushlinux1.com

httpd:Couldnotreliablydeterminetheserver'sfullyqualifieddomainname,using127.0.0.1forServerName

httpdnotrunning,tryingtostart


[root@crushlinux1local]#cd/usr/local/httpd/conf/

[root@crushlinux1conf]#vihttpd.conf

97#ServerNamewww.example.com:80

98ServerNamelocalhost:80


重新启动apache

[root@crushlinux1conf]#/usr/local/httpd/bin/apachectlstart

[root@crushlinux1conf]#ps-aux|grephttpd

[root@crushlinux1conf]#netstat-anptu|grep"httpd"


问题2:

/usr/local/apache/bin/httpd:errorwhileloadingsharedlibraries:libiconv.so.2:cannotopensharedobjectfile:Nosuchfileordirectory

有很多so模块在/usr/local/lib目录下,所以在/etc/ld.so.conf中加入/usr/local/lib这一行


[root@crushlinux1conf]#vi/etc/ld.so.conf

/usr/local/lib

[root@crushlinux1conf]#/sbin/ldconfig-v

现在您已经将Apach安装在/usr/local/apache。本安装支持可装载模块

和标准的MPMprefork。之后,可以使用如下命令启动Apache服务器:

[root@crushlinux1conf]#/usr/local/httpd/bin/apachectlstart

本文出自 “梦想的出发点” 博客,谢绝转载!

你可能感兴趣的:(源代码编译安装apache启动报错)