内射老阿姨1区2区3区4区_久久精品人人做人人爽电影蜜月_久久国产精品亚洲77777_99精品又大又爽又粗少妇毛片

apache啟動報錯httpd:apr怎么解決-創(chuàng)新互聯(lián)

本篇內(nèi)容介紹了“apache啟動報錯httpd: apr怎么解決”的有關(guān)知識,在實際案例的操作過程中,不少人都會遇到這樣的困境,接下來就讓小編帶領(lǐng)大家學(xué)習(xí)一下如何處理這些情況吧!希望大家仔細閱讀,能夠?qū)W有所成!

成都創(chuàng)新互聯(lián)公司專注于企業(yè)成都營銷網(wǎng)站建設(shè)、網(wǎng)站重做改版、平魯網(wǎng)站定制設(shè)計、自適應(yīng)品牌網(wǎng)站建設(shè)、成都h5網(wǎng)站建設(shè)、商城網(wǎng)站建設(shè)、集團公司官網(wǎng)建設(shè)、成都外貿(mào)網(wǎng)站建設(shè)、高端網(wǎng)站制作、響應(yīng)式網(wǎng)頁設(shè)計等建站業(yè)務(wù),價格優(yōu)惠性價比高,為平魯?shù)雀鞔蟪鞘刑峁┚W(wǎng)站開發(fā)制作服務(wù)。

httpd: Could not reliably determine the server’s fully qualified domain name, using 127.0.0.1 for ServerName
重啟apache:
service httpd restart
雖然重啟成功,但卻給出如下的提示信息:
httpd: apr_sockaddr_info_get() failed for hoteel
httpd: Could not reliably determine the server’s fully qualified domain name, using 127.0.0.1 for ServerName

究其原因是因為在配置DNS的時候hostname hoteel造成的,重新hostname localhost就可以了。

1、在啟動 httpd 時出現(xiàn)
Starting httpd: httpd: apr_sockaddr_info_get() failed for MYHOST
httpd: Could not reliably determine the server’s fully qualified domain name, using 127.0.0.1 for ServerName.
這個問題應(yīng)該是沒有在 /etc/httpd/conf/httpd.conf 中設(shè)定 ServerName 所以它會用主機上的名稱來取代,首先會去找 /etc/hosts 中有沒有主機的定義。
所以要解決這個問題可以設(shè)定 ServerName 或者在 /etc/hosts 中填入自己的主機名稱 MYHOST,像這樣:

vi /etc/hosts
127.0.0.1 localhost.localdomain localhost MYHOST

2、在Linux下安裝完Apache 2.2.6,啟動HTTP服務(wù)報錯
[root@linux http]# ./apachectl start
httpd: apr_sockaddr_info_get() failed for linux(在BSD上是apr_sockaddr_info_get() failed for freebsdla)
httpd: Could not reliably determine the server’s fully qualified domain name, using 127.0.0.1 for ServerName

經(jīng)分析發(fā)現(xiàn)是apache的conf目錄下的配置文件httpd.conf中關(guān)于hostname設(shè)置和/etc/sysconfig/network中的HOSTNAME設(shè)置不統(tǒng)一導(dǎo)致的,修改成統(tǒng)一的主機名即可解決該問題。

注:/etc/sysconfig/network 默認主機名是:HOSTNAME=localhost.localdomain

PS:網(wǎng)上有這種辦法,似乎是沒用的,因為我認為apache在編譯安裝過程中會編譯ARP的,因此下述操作有點多余。

apr 和apr-util包含在Apache httpd的發(fā)行源代碼中,并且在絕大多數(shù)情況下使用都不會出現(xiàn)問題。當然,如果apr或apr-util的1.0或1.1版本已經(jīng)安裝在你的系統(tǒng)中了, 則必須將你的apr/apr-util升級到1.2版本,或者將httpd單獨分開編譯。要使用發(fā)行源代碼中自帶的apr/apr-util源代碼進行安 裝,你必須手動完成:

復(fù)制代碼 代碼如下:

編譯和安裝 apr 1.2

apr
./configure --prefix=/x/httpd/apr
make
make install
apr-util
./configure --prefix=/x/httpd/apr_util --with-apr=/x/httpd/apr
make
make install
apache
./configure --prefix=/x/httpd/apache2 
–enable-so 
–enable-cgi 
–enable-rewrite 
–enable-mods-shared=all 
–with-apr=/x/httpd/apr 
–with-apr-util=/x/httpd/apr_util 
LDFLAGS="-L/usr/lib64 -L/lib64"

本機正確設(shè)定說明 必須為同一的
[root@spring ~]# nl /etc/hosts
1 # Do not remove the following line, or various programs
2 # that require network functionality will fail.
3 127.0.0.1 localhost.localdomain spring  http://www.iis7.com/a/lm/ftp/

[root@spring ~]# nl /etc/sysconfig/network
1 NETWORKING=yes
2 NETWORKING_IPV6=no
3 HOSTNAME=spring
4 #GATEWAY=192.168.8.1

[root@spring ~]# less /etc/httpd/conf/httpd.conf|grep ServerName

“apache啟動報錯httpd: apr怎么解決”的內(nèi)容就介紹到這里了,感謝大家的閱讀。如果想了解更多行業(yè)相關(guān)的知識可以關(guān)注創(chuàng)新互聯(lián)-成都網(wǎng)站建設(shè)公司網(wǎng)站,小編將為大家輸出更多高質(zhì)量的實用文章!

當前名稱:apache啟動報錯httpd:apr怎么解決-創(chuàng)新互聯(lián)
URL分享:http://www.rwnh.cn/article8/ccsiip.html

成都網(wǎng)站建設(shè)公司_創(chuàng)新互聯(lián),為您提供小程序開發(fā)、網(wǎng)站收錄手機網(wǎng)站建設(shè)、品牌網(wǎng)站設(shè)計、做網(wǎng)站動態(tài)網(wǎng)站

廣告

聲明:本網(wǎng)站發(fā)布的內(nèi)容(圖片、視頻和文字)以用戶投稿、用戶轉(zhuǎn)載內(nèi)容為主,如果涉及侵權(quán)請盡快告知,我們將會在第一時間刪除。文章觀點不代表本網(wǎng)站立場,如需處理請聯(lián)系客服。電話:028-86922220;郵箱:631063699@qq.com。內(nèi)容未經(jīng)允許不得轉(zhuǎn)載,或轉(zhuǎn)載時需注明來源: 創(chuàng)新互聯(lián)

h5響應(yīng)式網(wǎng)站建設(shè)
泸溪县| 淳化县| 巴南区| 惠水县| 东台市| 金山区| 杭州市| 漾濞| 东兰县| 玉田县| 和林格尔县| 平定县| 大邑县| 武宁县| 仲巴县| 文化| 张家口市| 准格尔旗| 宜都市| 洛浦县| 都匀市| 丹阳市| 沅江市| 丹凤县| 定日县| 巴林右旗| 友谊县| 马尔康县| 鄂托克旗| 剑川县| 东乌| 凤冈县| 邵东县| 龙门县| 博白县| 纳雍县| 象州县| 绥德县| 南充市| 汤原县| 交城县|