I can access my site via ports 8443 and 8080 but not via 443 and 80 (Tomcat)
Solution 1
The answer is very simple! The ports 80 and 443 were blocked on the Firewall. I unblocked them by using the following [deprecated] commands from the command line:
netsh firewall set portopening tcp 80 smb enable
netsh firewall set portopening tcp 443 smb enable
Solution 2
Are you running IIS on the same machine? Could be that IIS is consuming TCP ports 80 and 443. You can view all open TCP ports via CMD command: "netstat -at"
Related videos on Youtube
gordon613
Updated on September 18, 2022Comments
-
gordon613 over 1 year
I am using Tomcat7 on Windows Server 2008
My Server.xml is set up as follows:
<Connector port="80" protocol="HTTP/1.1" connectionTimeout="20000" redirectPort="443" compression="on" compressableMimeType="text/html,text/xml, text/plain,text/javascript, text/jsp,text/css"/ <Connector port="443" maxThreads="200" protocol="HTTP/1.1" scheme="https" secure="true" SSLEnabled="true" keystoreFile="C:\program files\java\jre7\bin\tomcat.keystore" keystorePass="password" clientAuth="false" sslProtocol="TLS"/> <Connector port="8009" protocol="AJP/1.3" redirectPort="443" />
However when I go to http://www.example.com or https://www.example.com then no page is displayed.
If I do a search and replace, changing port "80" for "8080" and port "443" for "8443" then my website works perfectly, although I need to access it via http://www.example.com:8080 and https://www.example.com:8443
I would like access to the site to be without having to specify the port numbers!
-
gordon613 about 12 yearsComment to Sven: Thank you... IIS is not installed on the server, and nothing else seems to be using using ports 80 or 443. (after checking with netstat -at)
-
gordon613 about 12 yearsI neglected to mention that this machine is a cloud server. Is it possible the cloud mechanism is getting in the way somehow?