Installation And Unistallation Of Tomcat

I just installed the tomcat 10.0.12 using below command

$ mkdir /opt/tomcat
$ cd /opt/tomcat
sudo wget https://dlcdn.apache.org/tomcat/tomcat-10/v10.0.12/bin/apache-tomcat-10.0.12.tar.gz
$ tar xvzf apache-tomcat-8.5.65.tar.gz
$ nano ~/.bashrc
and set the environment variabels in it which are
export JAVA_HOME=/usr/lib/jvm/jdk-17
export CATALINA_HOME=/opt/tomcat/apache-tomcat-10.0.12
saved the changes
$ . ~/.bashrc
$ $CATALINA_HOME/bin/startup.sh

then i runned http://127.0.0.1:8080 in browser it worked perfectly fine for me
but when i checked that application for which i installed the tomcat 10.0.12 it said for now its not supported to use tomcat i have to install tomcat 10.0.10 so i unistalled tomcat using below command

sudo rm -rf /opt/tomcat

and installed tomcat 10.0.10 by making few changes in above code but when i runned http://127.0.0.1:8080 again the page shown me this


instead of showing me this
webminmin-660x335
please ignore 8.5.05 cause i downloaded this image from another website which was providing tutorial to insatll tomcat on linux
i think tomcat didn't uninstall completely and still running what should i do please tell me

I would have opted for this guide, instead:

According to Apache:
http://tomcat.apache.org/

Applications that run on Tomcat 9 and earlier will not run on Tomcat 10 without changes. Java EE based applications designed for Tomcat 9 and earlier may be placed in the $CATALINA_BASE/webapps-javaee directory and Tomcat will automatically convert them to Jakarta EE and copy them to the webapps directory. This conversion is performed using the Apache Tomcat migration tool for Jakarta EE tool which is also available as a separate download for off-line use.

okay but what should i do now tell me how should i completely uninstall remove them and then i will install tomcat using your guide

I believe you already uninstalled it. By the way: Did you adjust your bashrc after removing TomCat?

The webpage you are referencing will show as unreachable without Tomcat installed.

in bashrc i did some changes like which are

export JAVA_HOME=/usr/lib/jvm/jdk-17
export CATALINA_HOME=/opt/tomcat/apache-tomcat-10.0.12

to

export JAVA_HOME=/usr/lib/jvm/jdk-17
export CATALINA_HOME=/opt/tomcat/apache-tomcat-10.0.10

@Aravisian please help me how should i solve this problem please bro

I'm sorry Aditya, I thought the above posts were self evident.
As Tomcat is already Uninstalled, follow the installation guide above and adjust bashrc as necessary.

This topic was automatically closed 90 days after the last reply. New replies are no longer allowed.

Marked solution. 165