

Install as well the security related program haveged, and make sure it starts at system boot together with Tomcat yum install havegedĪdd the exception on your firewall zone (trusted on my example) to access port 8080 firewall-cmd -zone=trusted -permanent -add-port=8080/tcpĪt this stage, you should be able to open Apache Tomcat from the loopback IP address at the CentOS server: You need to setup as well a system unit file for Apache Tomcat service vi /etc/systemd/system/rviceĭescription=Apache Tomcat Web Application ContainerĮnvironment=CATALINA_PID=/opt/tomcat/temp/tomcat.pidĮnvironment='CATALINA_OPTS=-Xms512M -Xmx1024M -server -XX:+UseParallelGC'Įnvironment='JAVA_OPTS=true =file:/dev/./urandom' Set the proper permissions before running the service chgrp -R tomcat confĬhown -R tomcat logs/ temp/ webapps/ work/ **by using the "-stript-components 1" you're untaring the. Tar -zxvf apache-tomcat-8.5.28.tar.gz -C /opt/tomcat -strip-components 1

While on the /opt/ folder, download Apache Tomcat (we are going to be using version 8.5.25) from this link: wget Useradd -s /bin/nologin -g tomcat -d /opt/tomcat tomcat Run the following commands to update your system and install Java if needed yum -y updateĬreate the location from where Apache Tomcat will run (/opt/tomcat/, also called Catalina's home) and also create a dedicate non-root user for the service mkdir /opt/tomcat The steps that I cover are the following:
#Apache tomcat 7 install how to
In this article I describe in a nutshell how to install Apache Tomcat on CentOS 7 Linux box, the version of Apache is 8.5.24.
