Take the 2-minute tour ×
Server Fault is a question and answer site for system and network administrators. It's 100% free, no registration required.

I've installed Nginx for optimizing the speed of Apache requests. For some weeks everything was fine, all my sites had started to fly indeed. BUT, I've decided to install passenger, and has broken my Apache. It's not starting... So, I think it's because the port 80 already in use by Nginx
netstat shows such situation:
tcp 0 0 0.0.0.0:80 0.0.0.0:* LISTEN 3932/nginx.conf
The error when trying to start Apache is saying:
(98)Address already in use: make_sock: could not bind to address 0.0.0.0:80 no listening sockets available, shutting down Unable to open logs
So, how can I fix my apache to work it again? BTW I've recompiled it to be as prefork :-D
Any help would be appreciated. Thanks a lot, Alex

share|improve this question

1 Answer 1

You have to use another port. Try to search in /etc/apache2 directory in some configuration file directive 'Listen' and change it in this way, for example:

Listen 81
share|improve this answer
    
Yes, you are right, I've looked to vhosts directory and saw that after recompiling apache for prefork it has created the file 00_default_vhost.conf with 80 port. So I've just marked it as .bak and everything is working well now. Thanks! –  Cfyzz Feb 16 '12 at 9:41

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.