例题2 配置基于域名的虚拟主机
[root@localhost htdocs]# echo "192.168.0.1 http://www.77cn.com.cn" >> /etc/hosts [root@localhost htdocs]# echo "192.168.0.1 http://www.77cn.com.cn" >> /etc/hosts
[root@localhost htdocs]# mkdir -p /var/www/vhosts/olabs.{org,net}/{htdocs,logs,conf,cgi-bin} [root@localhost htdocs]# echo "http://www.77cn.com.cn"> /var/www/vhosts/http://www.77cn.com.cn/htdocs/index.html [root@localhost htdocs]# echo "http://www.77cn.com.cn"> /var/www/vhosts/http://www.77cn.com.cn/htdocs/index.html [root@localhost htdocs]#mkdir /etc/httpd/vhost.d
[root@localhost htdocs]#
vi /etc/httpd/vhosts.d/http://www.77cn.com.cn.conf
百度搜索“77cn”或“免费范文网”即可找到本站免费阅读全部范文。收藏本站方便下次阅读,免费范文网,提供经典小说教育文库iptables防火墙配置教程及代码(6)在线全文阅读。
相关推荐: