httpd服务基于IP

  • Post author:
  • Post category:其他



vim /usr/local/apache2/conf/extra/httpd-vhosts.conf


wKiom1j0XRaynfhMAABF04AY8PM521.png

/usr/local/apache2/bin/apachectl -t

/usr/local/apache2/bin/apachectl restart



/usr/local/apache2/bin/apachectl -t


提示[Mon Apr 17 14:15:21 2017] [warn] NameVirtualHost *:80 has no VirtualHosts


vim /usr/local/apache2/conf/extra/httpd-vhosts.conf



改成以下截图就可以了




wKioL1j0YazyE4UOAABKSfBlaXU084.png





[root@Test-BBR ~]# /usr/local/apache2/bin/apachectl restart

[root@Test-BBR ~]# /usr/local/apache2/bin/apachectl -t

Syntax OK








wKioL1j0X9Xg6wtCAABqLNknkeE977.png


本文转自 15816815732 51CTO博客,原文链接:http://blog.51cto.com/68686789/1916659