{"id":279,"date":"2012-06-18T13:09:55","date_gmt":"2012-06-18T05:09:55","guid":{"rendered":"http:\/\/rmohan.com\/?p=279"},"modified":"2012-06-18T16:09:01","modified_gmt":"2012-06-18T08:09:01","slug":"change-tomcat-default-port-to-80-and-443","status":"publish","type":"post","link":"https:\/\/mohan.sg\/?p=279","title":{"rendered":"Change Tomcat default port to 80 and 443"},"content":{"rendered":"<p><strong>Change Tomcat default port to 80 and 443 <\/strong><\/p>\n<p>Tomcat by default runs on port number 8080, However there is high chance get a port conflict with others program. Sometime we just need to change the Tomcat port number.<br \/>\nSteps of changing the Tomcat Port<\/p>\n<p>1) Locate server.xml in {Tomcat installation folder}\\ conf \\<\/p>\n<p>2) Find following similar statement<\/p>\n<p> Define a non-SSL HTTP\/1.1 Connector on port 8180<br \/>\n     Connector port=&#8221;8080&#8243; maxHttpHeaderSize=&#8221;8192&#8243;<br \/>\n               maxThreads=&#8221;150&#8243; minSpareThreads=&#8221;25&#8243; maxSpareThreads=&#8221;75&#8243;<br \/>\n               enableLookups=&#8221;false&#8221; redirectPort=&#8221;8443&#8243; acceptCount=&#8221;100&#8243;<br \/>\n               connectionTimeout=&#8221;20000&#8243; disableUploadTimeout=&#8221;true&#8221; <\/p>\n<p>or<\/p>\n<p>    A &#8220;Connector&#8221; represents an endpoint by which requests are received<br \/>\n         and responses are returned. Documentation at :<br \/>\n         Java HTTP Connector: \/docs\/config\/http.html (blocking &#038; non-blocking)<br \/>\n         Java AJP  Connector: \/docs\/config\/ajp.html<br \/>\n         APR (HTTP\/AJP) Connector: \/docs\/apr.html<br \/>\n         Define a non-SSL HTTP\/1.1 Connector on port 8080<\/p>\n<p>     Connector port=&#8221;8080&#8243; protocol=&#8221;HTTP\/1.1&#8243;<br \/>\n               connectionTimeout=&#8221;20000&#8243;<br \/>\n               redirectPort=&#8221;8443&#8243;<\/p>\n<p>3) About Tomcat\u2019s server.xml file cites it\u2019s runs on port 8080. Change the Connector port=\u201d8080? port to any other port number.<\/p>\n<p>For example<\/p>\n<p>  Connector port=&#8221;80&#8243; protocol=&#8221;HTTP\/1.1&#8243;<br \/>\n               connectionTimeout=&#8221;20000&#8243;<br \/>\n               redirectPort=&#8221;8443&#8243; <\/p>\n<p>Above statement instruct Tomcat server runs on port 80 and 443.<\/p>\n<p>4) Edit and save the server.xml file. Restart Tomcat. Done  <\/p>\n","protected":false},"excerpt":{"rendered":"<p>Change Tomcat default port to 80 and 443 <\/p>\n<p>Tomcat by default runs on port number 8080, However there is high chance get a port conflict with others program. Sometime we just need to change the Tomcat port number. Steps of changing the Tomcat Port<\/p>\n<p>1) Locate server.xml in {Tomcat installation folder}\\ conf \\<\/p>\n<p>2) [&#8230;]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[21],"tags":[],"_links":{"self":[{"href":"https:\/\/mohan.sg\/index.php?rest_route=\/wp\/v2\/posts\/279"}],"collection":[{"href":"https:\/\/mohan.sg\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/mohan.sg\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/mohan.sg\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/mohan.sg\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=279"}],"version-history":[{"count":4,"href":"https:\/\/mohan.sg\/index.php?rest_route=\/wp\/v2\/posts\/279\/revisions"}],"predecessor-version":[{"id":303,"href":"https:\/\/mohan.sg\/index.php?rest_route=\/wp\/v2\/posts\/279\/revisions\/303"}],"wp:attachment":[{"href":"https:\/\/mohan.sg\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=279"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/mohan.sg\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=279"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/mohan.sg\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=279"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}