nginx apache and port

Markus Jelsma markus.jelsma at
Wed May 26 21:35:33 MSD 2010



If you don't run it as a superuser, Nginx cannot listen on port 80 and therefore not intervene with your Apache. Also, compiling and running as superuser while Nginx is configured to listen at port 80 will not intervene with Apache as long as Apache was already running, only one process can claim a port at the same time.


I suggest you compile from source, deploy the binary and configurations and configure Nginx to run at port 8080, which many people do. Can't be a problem.


-----Original message-----
From: JCR <nginx-forum at>
Sent: Wed 26-05-2010 19:27
To: nginx at; 
Subject: nginx apache and port


I have a centos 5 box with apache running fine and listening to port 80. I'd like to try nginx on let's say port 5080 (or maybe there is a better port), without disturbing my apache setup. 

(1) If I compile nginx from source and do nothing, will my apache setup be disturbed?

(2) I am thinking that all the work to make sure nginx listens to port 5080 is to be done in the nginx.conf  file; is that right?


Posted at Nginx Forum:,90556,90556#msg-90556

nginx mailing list
nginx at
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <>

More information about the nginx mailing list