How to install Apache Tomcat9.0.27 on opensuse15.1
- 00:29 java -version
- 00:36 cd /usr/local/
- 00:40 wget http://mirrors.estointernet.in/apache/tomcat/tomcat-9/v9.0.21/bin/apache-tomcat-9.0.21.zip
- 00:50 unzip apache-tomcat-9.0.27.zip
- 01:10 mv apache-tomcat-9.0.27 tomcat9
- 01:23 cd tomcat9/
- 01:36 echo "export CATALINA_HOME="/usr/local/tomcat9"" >> ~/.bashrc
- 02:21 source ~/.bashrc
- 02:37 chmod a+x catalina.sh startup.sh
- 03:04 ./startup.sh
Pre-requisites:
Java
Download link :
Installation procedure:
Use the below command to check the installed version of java
LinuxHelp:~ # java -version
openjdk version "11.0.3" 2019-04-16
OpenJDK Runtime Environment (build 11.0.3+7-suse-lp151.2.1-x8664)
OpenJDK 64-Bit Server VM (build 11.0.3+7-suse-lp151.2.1-x8664, mixed mode)
Change the specified Directory to Download and Install the Apache Tomcat
LinuxHelp:~ # cd /usr/local/
Download the Apache Tomcat Zip file using the below URL
LinuxHelp:/usr/local # wget http://mirrors.estointernet.in/apache/tomcat/tomcat-9/v9.0.21/bin/apache-tomcat-9.0.21.zip
--2019-10-20 22:58:26-- http://mirrors.estointernet.in/apache/tomcat/tomcat-9/v9.0.21/bin/apache-tomcat-9.0.21.zip
Resolving mirrors.estointernet.in (mirrors.estointernet.in)... 103.123.234.254, 2403:8940:2::f
Connecting to mirrors.estointernet.in (mirrors.estointernet.in)|103.123.234.254|:80... connected.
Length: 11589581 (11M) [application/zip]
Saving to: ‘apache-tomcat-9.0.27.zip’
apache-tomcat-9.0.27.zip 100%[====================================================================================================>] 11.05M 1.18MB/s in 10s
2019-10-20 22:59:56 (1.07 MB/s) - ‘apache-tomcat-9.0.27.zip’ saved [11589581/11589581]
Long list Directory to check the Downloaded Zip file
LinuxHelp:/usr/local # ll
total 11320
drwxr-xr-x 1 root root 124 Oct 20 22:59 .
drwxr-xr-x 1 root root 104 Mar 13 2019 ..
-rw-r--r-- 1 root root 11589581 Oct 7 15:51 apache-tomcat-9.0.27.zip
drwxr-xr-x 1 root root 0 Mar 11 2019 bin
drwxr-xr-x 1 root root 0 Mar 11 2019 games
drwxr-xr-x 1 root root 0 Mar 11 2019 include
drwxr-xr-x 1 root root 0 Mar 11 2019 lib
drwxr-xr-x 1 root root 0 Mar 11 2019 lib64
drwxr-xr-x 1 root root 80 Oct 20 22:05 man
drwxr-xr-x 1 root root 0 Mar 11 2019 sbin
drwxr-xr-x 1 root root 0 Mar 11 2019 share
drwxr-xr-x 1 root root 0 Mar 11 2019 src
Then unzip the Downloaded Zip file from the Directory
LinuxHelp:/usr/local # unzip apache-tomcat-9.0.27.zip
Archive: apache-tomcat-9.0.27.zip
creating: apache-tomcat-9.0.27/
creating: apache-tomcat-9.0.27/bin/
creating: apache-tomcat-9.0.27/conf/
List the contents of the following directory
LinuxHelp:/usr/local # ll
total 11320
drwxr-xr-x 1 root root 164 Oct 20 23:00 .
drwxr-xr-x 1 root root 104 Mar 13 2019 ..
drwxr-xr-x 1 root root 204 Oct 7 10:59 apache-tomcat-9.0.27
-rw-r--r-- 1 root root 11589581 Oct 7 15:51 apache-tomcat-9.0.27.zip
drwxr-xr-x 1 root root 0 Mar 11 2019 bin
drwxr-xr-x 1 root root 0 Mar 11 2019 games
drwxr-xr-x 1 root root 0 Mar 11 2019 include
drwxr-xr-x 1 root root 0 Mar 11 2019 lib
drwxr-xr-x 1 root root 0 Mar 11 2019 lib64
drwxr-xr-x 1 root root 80 Oct 20 22:05 man
drwxr-xr-x 1 root root 0 Mar 11 2019 sbin
drwxr-xr-x 1 root root 0 Mar 11 2019 share
drwxr-xr-x 1 root root 0 Mar 11 2019 src
Then Change the unzipped directory name to tomcat9
LinuxHelp:/usr/local # mv apache-tomcat-9.0.27 tomcat9
Now navigate to the tomcat9 directory as well as bin
LinuxHelp:/usr/local # cd tomcat9/
LinuxHelp:/usr/local/tomcat9 # cd bin
Configure the environment variable for apache tomcat 9.0.27
LinuxHelp:/usr/local/tomcat9/bin # echo "export CATALINA_HOME="/usr/local/tomcat9"" >> ~/.bashrc
Reload the environment file
LinuxHelp:/usr/local/tomcat9/bin # source ~/.bashrc
List the contents in the bin directory
LinuxHelp:/usr/local/tomcat9/bin # ll
total 864
-rw-r--r-- 1 root root 35064 Oct 7 10:57 bootstrap.jar
-rw-r--r-- 1 root root 1703 Oct 7 10:57 catalina-tasks.xml
-rw-r--r-- 1 root root 15953 Oct 7 10:57 catalina.bat
-rw-r--r-- 1 root root 23567 Oct 7 10:58 catalina.sh
-rw-r--r-- 1 root root 2123 Oct 7 10:57 ciphers.bat
-rw-r--r-- 1 root root 1997 Oct 7 10:58 ciphers.sh
-rw-r--r-- 1 root root 206895 Oct 7 10:58 commons-daemon-native.tar.gz
-rw-r--r-- 1 root root 25197 Oct 7 10:57 commons-daemon.jar
-rw-r--r-- 1 root root 2040 Oct 7 10:57 configtest.bat
-rw-r--r-- 1 root root 1922 Oct 7 10:58 configtest.sh
-rw-r--r-- 1 root root 8513 Oct 7 10:58 daemon.sh
-rw-r--r-- 1 root root 2091 Oct 7 10:57 digest.bat
-rw-r--r-- 1 root root 1965 Oct 7 10:58 digest.sh
-rw-r--r-- 1 root root 3606 Oct 7 10:57 makebase.bat
-rw-r--r-- 1 root root 3382 Oct 7 10:58 makebase.sh
-rw-r--r-- 1 root root 3460 Oct 7 10:57 setclasspath.bat
-rw-r--r-- 1 root root 3708 Oct 7 10:58 setclasspath.sh
-rw-r--r-- 1 root root 2020 Oct 7 10:57 shutdown.bat
-rw-r--r-- 1 root root 1902 Oct 7 10:58 shutdown.sh
-rw-r--r-- 1 root root 2022 Oct 7 10:57 startup.bat
-rw-r--r-- 1 root root 1904 Oct 7 10:58 startup.sh
-rw-r--r-- 1 root root 47882 Oct 7 10:57 tomcat-juli.jar
-rw-r--r-- 1 root root 419428 Oct 7 10:58 tomcat-native.tar.gz
-rw-r--r-- 1 root root 4574 Oct 7 10:57 tool-wrapper.bat
-rw-r--r-- 1 root root 5515 Oct 7 10:58 tool-wrapper.sh
-rw-r--r-- 1 root root 2026 Oct 7 10:57 version.bat
-rw-r--r-- 1 root root 1908 Oct 7 10:58 version.sh
Assign executable permissions to both startup.sh and catalina.sh
LinuxHelp:/usr/local/tomcat9/bin # chmod a+x catalina.sh startup.sh
Now,run the startup.sh script to start the tomcat
LinuxHelp:/usr/local/tomcat9/bin # ./startup.sh
Using CATALINA_BASE: /usr/local/tomcat9
Using CATALINA_HOME: /usr/local/tomcat9
Using CATALINA_TMPDIR: /usr/local/tomcat9/temp
Using JRE_HOME: /usr/lib64/jvm/java-11-openjdk-11
Using CLASSPATH: /usr/local/tomcat9/bin/bootstrap.jar:/usr/local/tomcat9/bin/tomcat-juli.jar
Tomcat started.
To check tomcat service are started or not, open a browser and type the IP address of your system with tomcat port number
With this,Installation of Apache TomcaT 9.0.27 OpenSuse 15.1 comes to an end.
Comments ( 0 )
No comments available