How to Install Tomcat 10 for Jakarta Development |Video upload date:  · Duration: PT5M6S  · Language: EN

Step by step guide to install Tomcat 10 for Jakarta EE development on Windows Linux and Mac with quick configuration and deploy tips

Why this guide exists and why you should care

You want a local Apache Tomcat 10 server for Jakarta EE development, and you want it to start without throwing a tantrum. This guide walks you through downloading Tomcat 10, verifying Java, unpacking files, configuring a manager user and ports, deploying a sample WAR, and starting the server on Windows Linux or Mac. It is short on fluff and long on practical steps with a pinch of sarcasm for morale.

Download Tomcat 10

Get the binary distribution from the Apache Tomcat mirrors. Pick the core zip or tar archive that matches your operating system. If you enjoy reading documentation grab the docs and examples too for emotional support.

Pick the right archive

Linux and Mac normally use the tar.gz file. Windows users will want the zip. No need to overthink it.

tar xzf apache-tomcat-10.x.tar.gz on Unix like systems
unzip apache-tomcat-10.x.zip on Windows

Install Java

Tomcat 10 requires Java 11 or later. Yes that means JDK not some mystery runtime you half installed five years ago. Install Java using your platform package manager or the vendor installer. Then confirm the install with a single command and no drama.

java -version

Set JAVA_HOME to the root of your JDK. On Linux add it to your shell profile or systemd unit. On Windows set the environment variable to your JDK install folder such as C drive Program Files Java jdk 11. If you skip this step Tomcat will sulk and give vague errors.

Unpack and place server files

Extract the archive to a sensible location like your home directory or a system level folder. The Tomcat home will contain conf lib bin logs webapps and work folders. Keep it somewhere you can find later without divine intervention.

Configure users and ports

To use the manager app add a user in conf/tomcat-users.xml with the expected roles. Use manager-gui for the web based manager and admin-gui if you want the admin pages. Make sure the XML stays well formed because parsers do not suffer fools.

<tomcat-users>
  <role rolename="manager-gui" />
  <role rolename="admin-gui" />
  <user username="dev" password="changeit" roles="manager-gui,admin-gui" />
</tomcat-users>

If port 8080 is already in use by another app change the Connector port in conf/server.xml to an unused number. Search for Connector port and edit the value. No magic here just plain port swapping.

Deploy and start the server

There are two boringly simple ways to deploy your WAR. Option one drop the WAR into the webapps folder and let Tomcat auto deploy it. Option two enable the manager app and upload the WAR with the web UI once you added the manager user.

Deploy by copying MyApp.war into webapps
Start Tomcat with the provided script
bin/startup.sh on Unix
bin\startup.bat on Windows

Logs live in the logs folder. If Tomcat complains check the log files for stack traces and missing class errors. On Unix you may have a logs/catalina.out file to tail. Debugging is 10 percent logic and 90 percent reading the logs while swearing softly.

Troubleshooting and quick tips

  • Permissions Make sure the user running Tomcat can read conf and write logs and webapps
  • Environment Verify JAVA_HOME and your PATH if startup fails
  • Ports If 8080 is busy change conf/server.xml or stop the offending process
  • Manager app If the manager UI is missing check tomcat-users.xml for typos or wrong roles
  • Deploy WAR If auto deploy does not work try copying the exploded app to webapps and watch the logs

Final words for the courageous

Follow these steps and you will have a running Tomcat 10 instance ready for Jakarta EE development and local testing. If things break consult the logs and remind yourself that servers only misbehave when humans try to make them useful. Now go deploy a WAR and pretend you are in charge.

I know how you can get Azure Certified, Google Cloud Certified and AWS Certified. It's a cool certification exam simulator site called certificationexams.pro. Check it out, and tell them Cameron sent ya!

This is a dedicated watch page for a single video.