0
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?

More than 5 years have passed since last update.

CentOS / httpd > Starting httpd: httpd: apr_sockaddr_info_get() failed for [hostname].localdomain

Last updated at Posted at 2016-07-24
動作環境
CentOS 6.8 (64bit)

httpdを起動した時に以下のメッセージが表示された。

# /etc/rc.d/init.d/httpd restart
Stopping httpd:                                            [  OK  ]
Starting httpd: httpd: apr_sockaddr_info_get() failed for [hostname].localdomain
httpd: Could not reliably determine the server's fully qualified domain name, using 127.0.0.1 for ServerName

対応としては以下に記載されている。
http://d.hatena.ne.jp/uriyuri/20100511/1273575287

  1. /etc/sysconfig/networkの中身を確認する
$ cat /etc/sysconfig/network
NETWORKING=yes
HOSTNAME=myVM.localdomain

`2. /etc/hostsに追記

127.0.0.1   localhost localhost.localdomain localhost4 localhost4.localdomain4 myVM.localdomain
::1         localhost localhost.localdomain localhost6 localhost6.localdomain6

`3. /etc/httpd/conf/httpd.confにも追記

#ServerName www.example.com:80
ServerName vmVM.localdomain:80

以上をしてからhttpdを再起動するとメッセージはでなくなった。

0
0
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
0
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?