echo NameVirtualHost *:80>>/etc/httpd/conf/httpd.conf
1. 假设服务器有个IP地址为192.168.1.10,使用ifconfig在同一个网络接口eth0上绑定3个IP:[root@localhost root]# ifconfig eth0:1 192.168.1.11[root@localhost root]# ifconfig eth0:2 192.168.1.12[root@localhost root]# ifconfig eth0:3 192.168.1.13 2. 修改hosts文件,添加三个域名与之一一对应:192.168.1.11 www.aoolong.com192.168.1.12 www.aoolong.com192.168.1.13 www.aoolong.com 3. 建立虚拟主机存放网页的根目录,如在/www目录下建立test1、test2、test3文件夹,其中分别存放1.html、2.html、3.html/www/test1/1.html/www/test2/2.html/www/test3/3.html 需要虚拟主机租用可以看下,傲龙网络。
顶一下
(0)
0%
踩一下
(0)
0%
上一篇:虚拟主机支持ASP吗?
下一篇:虚拟机远程访问主机