Foren

bind tomcat to port 80 on windows 2012

Jason Miller, geändert vor 10 Jahren.

bind tomcat to port 80 on windows 2012

New Member Beiträge: 2 Beitrittsdatum: 11.02.13 Neueste Beiträge
I've run Liferay a few times on Windows 2008, and I've had problems where Tomcat wouldn't bind to port 80 because of some other program using 80, so I resolved to only run Liferay on fairly pristine installs, which works fine. I tried the same thing on Windows 2012, but I can't get Tomcat to start if I bind it to port 80 via the server.xml file. It starts fine on 8080.

So I did a fresh install of 2012 and ran the usual gobs of Microsoft update patches. I figured one of them may have installed some little agent or something (even though port 80 is not mentioned in netstat). So I did another fresh install of windows standard 2012, didn't patch it or anything, unzipped the liferay-tomcat bundle, ran startup.bat, fires up just fine on 8080.. switch the server.xml to 80, and it gets hung up again on startup. It doesn't give an error or anything.

I've heard of extra requirements to bind to a port below 1024, or it could be a firewall issue (tried turning it off completely, still no luck). Any idea what might be necessary to get it to start up? I'm attaching the return from startup.bat up to the point it gets stuck, and I'm including the contents of netstat -bano while in this stuck state, because it seems to show java.exe bound to 80, just as it looks on windows 2008 with liferay running correctly on 80.

Thanks, any help is appreciated
--Jason Miller
thumbnail
Olaf Kock, geändert vor 7 Jahren.

RE: bind tomcat to port 80 on windows 2012

Liferay Legend Beiträge: 6403 Beitrittsdatum: 23.09.08 Neueste Beiträge
Jason Miller:
I've heard of extra requirements to bind to a port below 1024, or it could be a firewall issue (tried turning it off completely, still no luck). Any idea what might be necessary to get it to start up? I'm attaching the return from startup.bat up to the point it gets stuck, and I'm including the contents of netstat -bano while in this stuck state, because it seems to show java.exe bound to 80, just as it looks on windows 2008 with liferay running correctly on 80.


I know of the "< port 1024" requirement only from the *nix world, not sure about windows. Should be easy to try though, if you try binding to port 81, 1023 and 1025 in succession.

My personal preference is to have an Apache (or IIS, nginx etc) in front anyway. It adds flexibility, binds to port 80 perfectly (on the platforms of my choice) and allows me to to on-the-fly rewrite-fixes for whatever I see coming.