2010-05-11
Apacheのエラー:Could not reliably determine the server’s fully qualified domain name〜とメッセージが出たときの対応
httpd: Could not reliably determine the server’s fully qualified domain name, using 127.0.0.1 for ServerName
というエラーが出る場合がある。
これは、「ServerNameに127.0.0.1を使用した、FQDN(完全に適切なドメイン名)が確定できませんでした。」という意味だそうで、Apache自体は動くのだが、エラーをそのままにしておくのは気持ちが悪いし、あとあと問題を引き起こす可能性が高い。
このエラーは、「/etc/sysconfig/network」、 「/etc/hosts」 にlocalhost以外に自分で設定したホスト名が、Apacheの設定ファイルに定義されていないために発生する。
/etc/sysconfig/network例
NETWORKING=yes NETWORKING_IPV6=yes HOSTNAME=hoge.altqua.com
/etc/hosts例
# Do not remove the following line, or various programs # that require network functionality will fail. 127.0.0.1 hoge.altqua.com localhost.localdomain localhost
と書いた場合、/etc/httpd/conf/httpd.conf のServerNameの設定にも次のように書いておく。
/etc/httpd/conf/httpd.conf
# ServerName gives the name and port that the server uses to identify itself. # This can often be determined automatically, but we recommend you specify # it explicitly to prevent problems during startup. # # If this is not set to valid DNS name for your host, server-generated # redirections will not work. See also the UseCanonicalName directive. # # If your host doesn't have a registered DNS name, enter its IP address here. # You will have to access it by its address anyway, and this will make # redirections work in a sensible way. # #ServerName www.example.com:80 ServerName hoge.altqua.com:80
トラックバック - http://d.hatena.ne.jp/uriyuri/20100511/1273575287
リンク元
- 68 http://www.google.co.jp/search?sourceid=navclient&hl=ja&ie=UTF-8&rlz=1T4ADBF_jaJP245JP246&q=クリックしてもリンクが開かない
- 46 http://www.google.co.jp/search?hl=ja&lr=lang_ja&tbs=lr:lang_1ja&q=apache2+ubuntu+conf&aq=f&aqi=&aql=&oq=&gs_rfai=
- 37 http://www.google.co.jp/search?hl=ja&source=hp&q=winscp+コマンドライン&aq=6&aqi=g10&aql=&oq=winscp+&gs_rfai=
- 33 http://www.google.co.jp/search?q=winscp+コマンドライン&rls=com.microsoft:ja:IE-SearchBox&ie=UTF-8&oe=UTF-8&sourceid=ie7&rlz=1I7ADBR&redir_esc=&ei=1ZXoS7uLN4yK6gOuvLWuCA
- 26 http://www.google.co.jp/search?hl=ja&client=firefox-a&rls=org.mozilla:ja:official&q=winscp+コマンドライン&aq=6&aqi=g10&aql=&oq=winscp&gs_rfai=
- 25 http://www.google.co.jp/search?hl=ja&lr=lang_ja&client=firefox-a&rls=org.mozilla:ja:official&tbs=lr:lang_1ja&q=jquery+selected&btnG=検索&aq=f&aqi=g3g-m1&aql=&oq=&gs_rfai=
- 23 http://www.google.co.jp/search?hl=ja&safe=off&client=firefox-a&hs=Ihj&rls=org.mozilla:ja:official&q=vmware+ネットワーク+つながらない&aq=1r&aqi=g-r10&aql=&oq=VMware+?
- 21 http://www.google.co.jp/search?hl=ja&source=hp&q=vmware+ネットワーク+つながらない&aq=1r&aqi=g-r10&aql=&oq=vmware+ねっと&gs_rfai=
- 18 http://www.google.co.jp/search?client=firefox-a&rls=org.mozilla:ja:official&channel=s&hl=ja&source=hp&q=iptable+無効&lr=&btnG=Google+検索
- 18 http://www.google.co.jp/search?hl=&q=mysql+パスワード 変更&sourceid=navclient-ff&rlz=1B3GGGL_jaJP263JP263&ie=UTF-8