redzsol
redzsol

Reputation: 143

Apache refused to open even changing port 80 and port 443

I've read some post and tried to change it but unfortunately no change happened.

Here's the error returned:

Error: Apache shutdown unexpectedly. This may be due to a blocked port, missing dependencies, improper privileges, a crash, or a shutdown by another method. Press the Logs button to view error logs and check the Windows Event Viewer for more clues If you need more help, copy and post this entire log window on the forums

I've tried to listen on port 80 and port 443, but can't open it.

What did I miss?

Upvotes: 0

Views: 1632

Answers (1)

CodeSpent
CodeSpent

Reputation: 1904

Open XAMPP Control Panel and select Config under Apache. Select your httpd.conf and locate the following line.

# 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 **xx**

Where you see xx change this to something like 8080 if it currently states 81. Port 81 is commonly used by a few applications, as well as 443 so I tend to always change to 8080 by default, but your network may be different. You may obviously use netstat to see what ports may be available to you.

Restart XAMPP entirely as Apache is very fussy, then try starting Apache again.

Upvotes: 0

Related Questions