这是我的Apache httpd.conf设置:
This is my Apache httpd.conf settings :
Listen 8012 ServerName localhost:8012我每次通过 XAMPP 启动Apache我看到这条消息:
Every time I start Apache via XAMPP I see this message:
Status Check OK Busy… Apache Started [Port 80]任何人,请帮助我我可以更改任何其他设置?
Anybody, please help me can I change any other settings ?
推荐答案要改变这里的XAMPP 阿帕奇服务器端口的过程:
To answer the original question :
To change the XAMPP Apache server port here the procedure :
看一看到所有使用用netstat 使用的端口(集成的 XAMPP )。
Take a look to all your used ports with Netstat (integrated to XAMPP).
这时你可以看到所有使用的端口在这里,我们看到 80 端口已使用的系统。
Then you can see all used ports and here we see that the 80port is already used by the System.
选择一个空闲的端口号( 8012 ,对于本例)。
Choose a free port number (8012, for this exemple).
这个文件应该在中找到C:\\ XAMPP的\\ apache的\\的conf 上的窗口的或斌/阿帕奇为的Linux 的
This file should be found in C:\xampp\apache\conf on Windows or in bin/apache for Linux.
找到以下行:
- 80收听
- 服务器名本地主机:80
- Listen 80
- ServerName localhost:80
通过替换它们:
- 收听8012
- 服务器名本地主机:8012
- Listen 8012
- ServerName localhost:8012.
保存文件。
访问:的http://本地主机:8012 的检查,如果它的工作
Access to : localhost:8012 for check if it's work.
如果没有,你穆斯托编辑 HTTP-ssl.conf中文件。 请参阅下面的步骤3 的
If not, you musto edit the http-ssl.conf file. See step 3 below.
这个文件应该在中找到C:\\ XAMPP的\\ apache的\\的conf \\额外上的窗口的或看到这个link为的的Linux 的
This file should be found in C:\xampp\apache\conf\extra on Windows or see this link for Linux.
找到以下行:
- 听443
- <虚拟主机_default_:443>
- 服务器名称www.example:443 或服务器名本地主机:433
- Listen 443
- <VirtualHost _default_:443>
- ServerName www.example:443 or ServerName localhost:433
通过替换为他们其他的端口号( 8013 在这个例子中):
Replace them by with a other port number (8013 for this example) :
- 收听8013
- &LT;虚拟主机_default_:8013&GT;
- 服务器名称www.example:8013 或服务器名本地主机:8013
- Listen 8013
- <VirtualHost _default_:8013>
- ServerName www.example:8013 or ServerName localhost:8013
保存文件。
重新启动Apache服务器。
Restart the Apache Server.
访问:的http://本地主机:8012 的检查,如果它的工作
Access to : localhost:8012 for check if it's work.
如果您要访问的本地主机,而不在URL中指定的端口号搜索的http://本地主机而不是的http://本地主机:8012
If your want to access localhost without specify the port number in the URL localhost instead of localhost:8012.
- 开启 XAMPP控制面板
- 转到配置►服务和端口设置►的Apache
- 替换主要港口和 SSL端口与选择的值( 8012 和 8013 在这个例子中)。
- 保存服务设置
- 保存控制面板配置
- 重新启动Apache服务器现在应该工作。
- Open Xampp Control Panel
- Go to Config ► Service and Port Settings ► Apache
- Replace the Main Port and SSL Port values with those chosen (8012 and 8013 for this example).
- Save Service settings
- Save Configuration of Control Panel
- Restart the Apache Server It should work now.
如果你仍然在控制面板控制台此消息:
If you still have this message in Control Panel Console :
Apache的入门[端口80]
Apache Started [Port 80]
- 找到 XAMPP-CONTROL.EXE 文件的位置
- 创建在该目录中的文件 XAMPP.INI (所以 XAMPP.ini 和 XAMPP-CONTROL.EXE 在同一个目录下)
-
把下面的 XAMPP.INI 文件:
- Find location of xampp-control.exe file
- Create a file XAMPP.INI in that directory (so XAMPP.ini and xampp-control.exe are in the same directory)
Put following lines in the XAMPP.INI file:
[端口] 阿帕奇= 8012
现在,你总是会得到:
阿帕奇开始[端口8012]
Apache started [Port 8012]
请注意,这是为展示目的只有。它有没有关系你的的httpd.conf 。
更多推荐
如何更改XAMPP Apache服务器端口?
发布评论