如何配置Apache 多端口

2016-08-03 01:20:22 8246

配置httpd.conf 
监听多个端口 

代码如下:


# Listen: Allows you to bind Apache to specific IP addresses and/or 

# ports, instead of the default. See also the <VirtualHost> 

# directive. 

# Change this to Listen on specific IP addresses as shown below to 

# prevent Apache from glomming onto all bound IP addresses. 

#Listen 12.34.56.78:80 

Listen 8081 

Listen 8082 

Listen 8083 


#增加监听端口 

等以下内容都设置以后,可以通过netstat -n -a查看端口是否开启 

开启虚拟站点 

复制代码 代码如下:


# Virtual hosts 

#Include conf/extra/httpd-vhosts.conf 

#修改为 

# Virtual hosts 

Include conf/extra/httpd-vhosts.conf 


提交成功!非常感谢您的反馈,我们会继续努力做到更好!

这条文档是否有帮助解决问题?

非常抱歉未能帮助到您。为了给您提供更好的服务,我们很需要您进一步的反馈信息:

在文档使用中是否遇到以下问题: