debian apache2 apr_sockaddr_info_get() failed 错误的解决

在启动 apache2 时出现
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.

所以要解决这个问题可以设定 ServerName 或者在 /etc/hosts 中填入自己的主机名称 MYHOST,像这样:
>vi /etc/hosts
127.0.0.1 localhost.localdomain localhost ThinkPad