0
问题: 我想从IIS切换到Apache出于不同的原因,如我也想并行运行的其他东西我需要在一个配置了Apache不同于80的端口。我用一个IP运行多个域,所以我配置了虚拟主机。当我设置的80端口,一切工作正常,只要我切换到另一个端口,我不是只得到“默认”虚拟主机或在某些配置一个404阿帕奇2.4(win2k12)不接端口8080为虚拟主机
我试过/做过: - 防火墙配置为接受8080作为端口并允许httpd.exe本身。 - netstat仅在我尝试配置的端口上列出httpd.exe作为侦听器。 - IIS不再安装
下面是工作的配置,很好。 - 当我的每一个端口切换80到8080不起作用 - 当我删除了明确的IP公司在“听”到“听8080”是行不通
任何想法,为什么端口8080(我也试过8000 )不起作用?
感谢
etc/hosts中
127.0.0.1 localhost
::1 localhost
127.0.0.1 srv.mydomain.com
::1 srv.mydomain.com
的conf /额外/的httpd-vhosts.conf
<VirtualHost *:80>
DocumentRoot "c:/folder/htdocs/foo/www"
ServerName www.foo.com
ServerAlias foo.com
</VirtualHost>
<VirtualHost *:80>
DocumentRoot "c:/folder/htdocs/foo/www"
ServerName www.foo.net
ServerAlias foo.net
</VirtualHost>
<VirtualHost *:80>
DocumentRoot "c:/folder/htdocs/foo/static"
ServerName static.foo.com
</VirtualHost>
<VirtualHost *:80>
DocumentRoot "c:/folder/htdocs/foo/blog"
ServerName blog.foo.com
</VirtualHost>
<VirtualHost *:80>
DocumentRoot "c:/folder/htdocs/bar/www"
ServerName www.bar.net
ServerAlias bar.net *.bar.net
</VirtualHost>
的httpd.conf
Listen <ipv4>:80
Listen [<ipv6>]:80
ServerName srv.bar.net
DocumentRoot "c:/folder/htdocs"
<Directory "c:/folder/htdocs">
Options Indexes FollowSymLinks
AllowOverride All
Require all granted
</Directory>
Include conf/extra/httpd-vhosts.conf
这不能提供问题的答案。要批评或要求作者澄清,在他们的帖子下留下评论 - 你总是可以评论你自己的帖子,一旦你有足够的[声誉](http://stackoverflow.com/help/whats-reputation),你会能够[评论任何帖子](http://stackoverflow.com/help/privileges/comment)。 - [来自评论](/ review/low-quality-posts/11227894) – Teepeemm
恩,是的,这是一个问题的答案:因为那是他做错了。你在说我用疑问的声音“回答了”我的答案。这仍然是一个答案 – ConnerMan
在这种情况下,如果你没有提问语气的话,你的答案可能会更好地帮助其他人。 – Teepeemm