首页 > 其他 > 详细

增加虚拟主机

时间:2015-06-09 11:34:41      阅读:224      评论:0      收藏:0      [点我收藏+]

1.查找  httpd.conf 文件

  find / -name "httpd.conf"

2.编辑 httpd.conf 文件

  vi /etc/httpd/conf/httpd.conf

3.section 3 增加虚拟机配置模块

  #--beginbylanhuan--
  NameVirtualHost *:80
  <VirtualHost *:80>
  ServerName www.18dian.cn
  serverAlias 18dian.cn *.18dian.cn
  DocumentRoot /var/www/html
  </VirtualHost>
  #--endbylanhuan--

 4.重启httpd

  service httpd restart

增加虚拟主机

原文:http://www.cnblogs.com/lanhuan/p/4562695.html

(0)
(0)
   
举报
评论 一句话评论(0
关于我们 - 联系我们 - 留言反馈 - 联系我们:wmxa8@hotmail.com
© 2014 bubuko.com 版权所有
打开技术之扣,分享程序人生!