apache服務報錯Could not reliably determine the server's fully qualified domain name

在對apache服務進行各種操作時都會提示錯誤,但不影響使用:
apache2: Could not reliably determine the server's fully qualified domain name, using XXX.XXX.XXX.XXX. Set the 'ServerName' directive globally to suppress this message

解決方法:
在apache配置文件中添加一行:
ServerName localhost:80

不同服務器配置文件路徑和文件名都有區別,我的配置文件是:/etc/apache2/apache2.conf

發表評論
所有評論
還沒有人評論,想成為第一個評論的人麼? 請在上方評論欄輸入並且點擊發布.
相關文章