Driver FixRecommendedSound, Wi-Fi or graphics acting up? Check drivers firstFind missing or outdated drivers fast.Check DriversOctober DealsAmazon USOctober deal check: compare before you payAmazon US: current deals, useful picks and tech finds.Check DealsWindows FixRecommendedWindows errors stealing your time? Find the fix fastScan stability, cleanup and performance issues.Fix Now×
Skip to content
World desk11 min

How to Install Tomcat on Ubuntu: Step-by-Step Server Setup

A practical Ubuntu guide to Tomcat 10.1: install with APT or a verified Apache archive, run it safely under systemd, deploy an app, and test Jakarta compatibility.
Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

The most maintainable way to install Tomcat on Ubuntu is the distribution package: install Java 11 or newer, install tomcat10 with APT, enable its systemd service, and verify the local HTTP endpoint. Use Apache’s upstream archive instead when you need a particular Tomcat 10.1 release or a filesystem layout independent of Ubuntu packaging. This guide covers both methods, secure service operation, verification, upgrades, and the Tomcat 9-to-10 compatibility issue.

What you need before installing

  • An Ubuntu server with shell access and an account allowed to use sudo.
  • Java 11 or later. Apache’s Tomcat 10.1 documentation states that Tomcat 10.1 requires Java 11 or later. Java 17 is a practical current choice on supported Ubuntu releases.
  • A decision about the HTTP port. Tomcat’s default connector listens on TCP port 8080; put a reverse proxy in front of it for public HTTPS rather than exposing the container directly when possible.
  • A service-account plan. Tomcat should run as an unprivileged account, never as root.
  • Enough disk space for the runtime, logs, deployed applications, and any file uploads your applications create.

Check the operating system and Java before changing anything:

As an Amazon Associate I earn from qualifying purchases.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.
lsb_release -a
java -version

If Java is missing, install a supported OpenJDK package. The package name can vary by Ubuntu release; these commands use OpenJDK 17:

sudo apt update
sudo apt install openjdk-17-jdk
java -version

Confirm that the reported major version is 11 or higher. If your application specifically requires Java 11, install openjdk-11-jdk where that package is available and use its path consistently in the service configuration.

#1 Best Overall
Sale
TOZO A1 Wireless Earbuds Bluetooth 5.3 Light Weight in Ear Headphones | IPX5 Waterproof,2 Mics for AI Calls,Immersive Premium Sound Bass Headset with Charging Case,32 EQ via App Black
  • [Ultra-Lightweight Ear Buds Designed for Small Ears] Each earbud weighs only 3.7g and features a compact, ergonomic in-ear design made especially for small ears. Secure, low-profile, and comfortable for workouts, all-day wear or overnight sleeping.The ultra-slim profile sits flush in your ear with no hard edges poking or rubbing, so you can even sleep on your side without discomfort.
  • [Immersive Stereo Sound with TOZO OrigX Technology] TOZO OrigX tuning delivers clear vocals, balanced mids, and natural stereo sound for music, podcasts, and videos.
  • [Long Battery Life for Daily Use] Get up to 7 hours of playtime on a single charge, with up to 32 hours total using the charging case—ideal for workdays, commuting, and extended listening sessions.
  • [Bluetooth 5.3 & Stable Connection] Bluetooth 5.3 provides fast pairing, stable wireless performance, and reduced dropouts as you move around home or office.
  • [Deep Bass with Clear Vocals] High-performance drivers produce punchy bass while keeping vocals clean and detailed for everyday listening.

Choose APT or the Apache archive

Both installation paths run the same Tomcat software, but they put ownership of updates and service integration in different places. Decide before deploying applications because changing layouts later can require moving configuration, logs, and deployed files.

Decision point Ubuntu APT package Apache upstream archive
Release selection Uses the Tomcat version built for your Ubuntu release and available from its repositories. Lets you select a specific Apache release, such as Tomcat 10.1.61, independently of the Ubuntu package version.
Update ownership Ubuntu package management supplies package updates and integrates them with the operating system. You monitor Apache releases, download each archive yourself, and verify it before installation.
Filesystem layout Ubuntu chooses the service, configuration, log, and application-data locations. You choose locations such as /opt/tomcat and can keep multiple versions side by side.
Service integration Includes a ready-to-use systemd service named tomcat10. Requires your own systemd unit or a daemon wrapper such as jsvc.
Upgrade and rollback Simple package upgrades, with the exact rollback options determined by Ubuntu’s package history. A versioned directory and stable symlink make switching to an older extracted release straightforward.
Application compatibility Both choices are Tomcat 10.1 deployments and therefore require Java 11 or newer and the Jakarta namespace used by Tomcat 10.

For a normal Ubuntu server, start with APT. Choose the archive when release pinning, custom paths, or independent upgrade control is more important than distribution integration.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

Install Tomcat 10 with Ubuntu packages

1. Install the runtime

Update package metadata and install the Tomcat 10 runtime:

sudo apt update
sudo apt install tomcat10

APT creates the service account, installs the configuration and runtime files in Ubuntu’s expected locations, and registers the systemd unit. Do not create a second account or manually unpack another Tomcat into the package’s directories.

2. Enable and start the service

sudo systemctl enable --now tomcat10
systemctl status tomcat10 --no-pager

enable --now starts Tomcat immediately and schedules it to start at boot. A healthy status normally shows active (running). If it is failed, continue with the logs before repeatedly restarting it.

3. Inspect the journal and listening socket

sudo journalctl -u tomcat10 -e --no-pager
ss -ltnp | grep 8080

The journal should show a completed startup rather than a Java exception. The socket check confirms that a process is listening on port 8080. If the service is active but no socket appears, inspect the connector configuration and the most recent journal entries.

What’s actually slowing this PC down?

Pick the symptom - the matching free tool is one click away.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

4. Add optional Ubuntu packages only when needed

The runtime is separate from the optional administration application, documentation, examples, and user-instance support. Install only the components you actually need:

sudo apt install tomcat10-admin tomcat10-docs tomcat10-examples tomcat10-user
  • tomcat10-admin supplies the manager and host-manager web applications. Treat them as administrative surfaces, not public websites.
  • tomcat10-docs installs local Tomcat documentation.
  • tomcat10-examples installs sample applications useful for learning and smoke tests.
  • tomcat10-user supports creating additional Tomcat user instances where that packaging model is appropriate.

After adding a package, restart only if its files or configuration require it:

Rank #2
Sale
Smart Watch for Men Women Compatible with iPhone Samsung Android Phone 1.69 inch Full Touch Screen IP68 Waterproof Bluetooh Fitness Tracker Heart Rate/Sleep Monitor (Black)
  • 【IP68 Waterproof Multifunctinal Smart Watch】Torjalph fitness activity tracker smart watch is IP68 waterproof technology ,you can wear it when swimming,handwashing,it's rain-proof which means that you perform multiple exercise modes outside without worrying about sweat or rain corroding your fitness smart watch,and this watch equipped with a 230 mAh large capacity battery magnetic charging ,and this sports activity tracker watch can be used 5-7 days If fully charged.
  • 【Larger 1.83'' Full Screen Watch & Multi-dial Selection】1.83 inch full HD color touch screen smart watch for men / women provides excellent 240*284 resolution image quality ,This Bluetooth smart watch offers a better touch experience and remarkable immersion and ,more than 200 watch faces for you to choose from App"Da Fit ", you can change the dial style according to your mood to wear keeping the world on your wrist
  • 【Accurate Activity Tracker Smart Watch 】sports watch activity tracker uses sweat and dust resistant breathable silicone strap, our Fitness Tracker Smart Watch for Android iOS Phones supports 12 sports modes,walking,running,bicycle,swimming,badminton,basketball,football,rope skipping. This bluetooth calls smart watch for men women is lightweight and stylish, bringing more convenient and relaxing sports experience while also providing more protection.
  • 【Your 24 Hour Personal Daily Health Monitor】Fitness watch for women men full touch screen IP67 waterproof bluetooth smartwatch for Android iOS Phones with heart rate blood pressure monitor multifunction Andriod smart watch with steps counter sleep monitor sports fitness watch, monitoring blood oxygen saturation allows you to understand your physical condition in real time to track fitness progress ,to know your health status in time.
  • 【More Functions Bluetooth Call Smart Watch】This fitness activity smart watch full screen for iPhone and Android phones includes a bunch of new features including:The bluetooth smart watch can hang up the phone, receive and display WhatsAPP /Text /Facebook /Twitter /Messenger reminder.Support sedentary reminder, alarm clock, stopwatch, timer,weather information,music control, remote camera control compatible with Android 5.0 and above or iOS 9.0 and above smartphones.
sudo systemctl restart tomcat10

5. Configure administration carefully

If you install the manager applications, locate the package configuration under /etc/tomcat10 and edit the package’s tomcat-users.xml file. Define a non-obvious username and a long, unique password, then grant only the role required by the specific manager interface. A minimal example is:

<role rolename='manager-gui'/>
<user username='deployadmin' password='replace-with-a-long-unique-secret' roles='manager-gui'/>

Do not expose the manager applications to the whole internet. Restrict access with the application’s address controls, a reverse proxy allow-list, a VPN, or the host firewall. Restart Tomcat after changing the users file and remove the example account as soon as testing is complete.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

6. Check the default page locally

curl -i http://127.0.0.1:8080/

A successful response includes an HTTP status line and Tomcat’s default page. From another machine, substitute the server’s address only after you have deliberately allowed the port through the firewall.

Expose only the traffic you intend

Tomcat’s connector is normally bound to port 8080. For a private application server, leave that port reachable only from the reverse proxy or trusted network. If direct access is required temporarily, allow it explicitly and remove the rule when finished:

sudo ufw allow 8080/tcp
sudo ufw status verbose

A public production site generally terminates TLS at a reverse proxy on ports 80 and 443, forwards only the application traffic to Tomcat, and keeps 8080 closed to the internet. The exact proxy configuration depends on the proxy and application, so do not copy a generic rule without checking forwarding headers, timeouts, upload limits, and access logs.

Install a specific Apache release from the upstream archive

Use this route when you need an Apache release that is not yet packaged for your Ubuntu version, or when you want a predictable custom layout. The Apache Software Foundation publishes binary archives and instructs users to verify downloads with an OpenPGP signature or a SHA-512 checksum before use. Download the archive, its matching verification files, and the signing-key information from the official Tomcat 10.1 download page using a browser or a trusted download method. Do not treat an unverified archive as production software.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

1. Install Java and the service tools

sudo apt update
sudo apt install openjdk-17-jdk jsvc
java -version

jsvc is Apache Commons Daemon’s native launcher and can daemonize a Unix installation. You may instead use the systemd unit shown below; do not run both launchers for the same instance.

2. Verify the archive

The following example uses Tomcat 10.1.61, a version identified in Apache’s 2026 documentation. Replace the filenames with the exact release you downloaded:

Rank #3
New Bee Guitar Cable 10ft Electric Instrument Bass AMP Cord
  • [Low Noise High Fidelity] New bee guitar cord with 22AWG oxygen-free-copper center conductors provides enhanced signal transfer, the PVC insulation material and the high-density stranded copper double shield provide noise rejection for quiet operation
  • [Ideal for Choice] New bee 1/4 straight and right angle metal connectors, ensures a secure connection in any instrument, pedal, or amp jack. L shape great fro on stage guitar stands
  • [Wide Compatible] Suitable for mixer, power amplifier, microphone, effector, decoder, equalizer, electoronic organ, electric guitar, electric bass and other electronic equipments. Widely used in the installation of smart home, karaoke speaker, professional stage audio, etc
  • [Easy Disassemble] Making incidental repairs quick and easy! Very nice, flexible cable
  • [Dont Hesite to Order] 24 hours customer services and professional technology team are standing by
gpg --verify apache-tomcat-10.1.61.tar.gz.asc apache-tomcat-10.1.61.tar.gz
sha512sum -c apache-tomcat-10.1.61.tar.gz.sha512

A valid signature check reports a good signature from an Apache release key; a checksum check reports OK. A bad signature, a checksum mismatch, or a missing key is a stop condition: delete the archive, obtain the verification material again from Apache, and investigate the download path instead of extracting it.

3. Create a dedicated account and versioned directories

sudo useradd --system --home /opt/tomcat --shell /usr/sbin/nologin tomcat
sudo mkdir -p /opt/tomcat
sudo tar -xzf apache-tomcat-10.1.61.tar.gz -C /opt/tomcat
sudo ln -sfn /opt/tomcat/apache-tomcat-10.1.61 /opt/tomcat/current
sudo chown -R tomcat:tomcat /opt/tomcat

The versioned directory preserves the original release while /opt/tomcat/current provides a stable path for service configuration. For a larger installation, keep CATALINA_BASE in a separate instance directory so application data and configuration survive a binary replacement.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

4. Define Java and Tomcat variables

Find the actual Java home instead of assuming an architecture-specific path:

dirname $(dirname $(readlink -f $(command -v java)))

Use the resulting directory as JAVA_HOME. Apache’s setup guidance expects JAVA_HOME, CATALINA_HOME, and CATALINA_BASE to be defined. For this layout, the values are:

JAVA_HOME=/usr/lib/jvm/java-17-openjdk-amd64
CATALINA_HOME=/opt/tomcat/current
CATALINA_BASE=/opt/tomcat/current

If you separate the instance, set CATALINA_BASE to that instance directory and ensure it contains the required conf, logs, temp, webapps, and work directories with ownership assigned to tomcat.

Run the archive installation as a systemd service

A small, explicit unit is easier to audit than starting Tomcat from an interactive shell. Create /etc/systemd/system/tomcat-custom.service as root:

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.
[Unit]
Description=Apache Tomcat 10.1 custom installation
After=network.target

[Service]
Type=simple
User=tomcat
Group=tomcat
Environment=JAVA_HOME=/usr/lib/jvm/java-17-openjdk-amd64
Environment=CATALINA_HOME=/opt/tomcat/current
Environment=CATALINA_BASE=/opt/tomcat/current
ExecStart=/opt/tomcat/current/bin/catalina.sh run
ExecStop=/bin/kill -15 $MAINPID
Restart=on-failure
RestartSec=10

[Install]
WantedBy=multi-user.target

Adjust JAVA_HOME to the path reported on your server. Then load and start the unit:

sudo systemctl daemon-reload
sudo systemctl enable --now tomcat-custom
systemctl status tomcat-custom --no-pager
sudo journalctl -u tomcat-custom -e --no-pager

The run mode keeps Tomcat attached to systemd so logs and exit status are visible to the service manager. The process runs as tomcat, while systemd performs restarts after an unexpected failure. Confirm that no packaged tomcat10 service is also running on the same port.

Rank #4
BSIMB 15.6" Digital Family Calendar & Chore Chart, No Subscription Fees
  • Digital Family Calendar: BSIMB digital calendar wall touch screen puts an end to your chaotic life. Designed for busy families, the digital calendar keeps you organised and in step with your family. Assign different colours and tasks to each family member to make family scheduling easier and more intuitive.
  • Easy Setup and Auto-Sync: Plug in, connect to WLAN and auto-syn your electric calendar in minutes. Digital wall calendar compatible with Google calendar, iCloud calendar, Outlook calendar, Cozi calendar and Yahoo calendar. Add events directly on the device or through the ecalendar app. Electronic calendar stays current whether you're at work or traveling—no manual updates needed.
  • All-In-One Home Assistant: Smart calendar builds habits and encourage independence with personalised chores. Display daily meal plan to reduce the daily ‘What's for dinner?’ stress. To-do lists keep track of everything you want. Turning chores into valuable achievements with stars and rewards, making life easier and more enjoyable.
  • Manage Anytime Anywhere: BSIMB electronic calendar for family stay connected with the powerful ecalendar app. Access and manage your digital wall calendar anytime, anywhere with free features like stars & rewards, photo screensaver, chore charts, meals plans, to-do lists etc. Electronic planner paid features like Magic Import tailor advanced tools for users with special needs.
  • Stay in Touch with Loved Ones: Share photos or videos from your phone to electronic wall calendar with app, instantly update your life moment, and keep in touch with your family, especially those who are far away; you can also surprise your smart calendar digital wall by sending him a wish card; it's also great for keeping tech-illiterate elders in touch with the youngsters.

Using jsvc instead

For installations that must use Apache Commons Daemon, keep the same unprivileged account and variables, then invoke jsvc with Tomcat’s bootstrap and logging JARs, the Java home, the Tomcat home and base, a PID file, and output files. The exact command depends on the Ubuntu jsvc build and the chosen directory layout; consult the installed jsvc help and Apache’s Unix setup instructions, and test start, stop, and restart under a maintenance window. Never use jsvc to grant Tomcat root privileges merely to bind a low port; place a reverse proxy on ports 80 and 443 instead.

Independent reader supportYour contribution helps us test, update, and keep practical guides available for everyone.Support on Ko-Fi

Deploy an application and confirm its context

Tomcat maps an application to a context path. A WAR named inventory.war in the active instance’s webapps directory normally becomes /inventory. Deploy it only after the service is healthy:

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.
sudo install -o tomcat -g tomcat -m 0640 inventory.war /opt/tomcat/current/webapps/
sudo systemctl restart tomcat-custom
curl -i http://127.0.0.1:8080/inventory/

For the Ubuntu package, use the package-managed webapps directory discovered under /var/lib/tomcat10 rather than copying files into /opt. Watch the journal while the application expands:

sudo journalctl -u tomcat10 -f

Use the application’s documented context path and health endpoint; a working Tomcat root page does not prove that your application initialized successfully.

Tomcat 10 compatibility: Java and Jakarta

Java requirement

Tomcat 10.1 requires Java 11 or later. A server running an older Java runtime can fail before Tomcat opens its HTTP connector, so check java -version under the same environment used by systemd, not only in your interactive shell.

The javax to jakarta change

Tomcat 10 changed the servlet and related APIs from the javax.* namespace to jakarta.*. Applications built for Tomcat 9 or earlier may therefore need source changes, dependency updates, and a rebuilt WAR. A successful Tomcat installation cannot make an incompatible application run unchanged.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.
  1. Inventory the application’s servlet, JSP, persistence, and authentication dependencies.
  2. Check whether each framework version supports the Jakarta namespace.
  3. Build and test a Tomcat 10-compatible artifact in a staging instance.
  4. Exercise login, sessions, uploads, scheduled jobs, database access, and graceful shutdown before switching production traffic.
  5. Keep the previous Tomcat and application deployment available for rollback until the test window is complete.

If the application cannot yet migrate, keep it on a supported Tomcat 9 environment rather than forcing a Tomcat 10 deployment.

Verification checklist after installation

  • systemctl status tomcat10 or systemctl status tomcat-custom reports active (running).
  • The service journal contains no startup exception, permission error, or port-binding failure.
  • ss -ltnp shows the intended listener, normally TCP 8080.
  • curl -i http://127.0.0.1:8080/ returns an HTTP response from Tomcat.
  • Your deployed context URL returns the application’s expected status and content.
  • The process owner is the dedicated tomcat account, not root.
  • Only the reverse proxy or trusted administration network can reach management applications and the backend port.
  • The archive installation has a recorded Apache signature or SHA-512 verification result.
  • The Java version and Tomcat release are documented so the next administrator can reproduce the service.

Troubleshooting common failures

APT cannot find tomcat10

Refresh package metadata, confirm the Ubuntu release and enabled repositories, and check the package name available for that release. If the required Tomcat 10.1 release is not packaged, use the verified Apache archive rather than mixing files from different installation methods.

The service exits immediately

Read the complete journal with sudo journalctl -u tomcat10 -b --no-pager or the custom unit’s name. Java version errors, unreadable configuration, invalid XML, and filesystem permissions are more useful diagnoses than a second restart. Correct one error, then start the service again.

Port 8080 is already in use

Identify the owner with sudo ss -ltnp | grep 8080. Stop the duplicate Tomcat instance or change the connector port in the active installation. Do not run the packaged and archive services simultaneously unless they have separate ports and deliberately separate data.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

The browser cannot connect remotely

First test locally with curl. If local access works, check UFW or another host firewall, cloud security rules, the server address, and whether Tomcat is bound only to loopback. Public exposure should normally be through a configured reverse proxy.

The root page works but the application fails

Follow the deployment log while the WAR expands, inspect the application’s stack trace, and verify its Java and Jakarta dependencies. A Tomcat 9 application using javax.* APIs commonly requires migration before Tomcat 10 can load it.

Upgrade and rollback strategy

For APT, review the package version offered by your Ubuntu release and take a configuration backup before upgrading. Keep application backups and a tested deployment procedure; package upgrades do not replace application compatibility testing.

For the archive method, download and verify the new release, extract it beside the current version, copy or reference the intended CATALINA_BASE, stop the service, switch the /opt/tomcat/current symlink, and start the service. If validation fails, stop it, point the symlink back to the previous version, and restart. Keep only releases you still support, and remove old archives after confirming that rollback is no longer required.

Free tools Windows power users keep installed

One-click scans. No signup required.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

Which installation should you use?

Use Ubuntu’s tomcat10 package when standard systemd integration, Ubuntu-managed updates, and a conventional server layout meet your needs. Use the verified Apache archive when you need a specific Tomcat 10.1 release, a custom layout, or side-by-side version control. In either case, Java 11 or newer, non-root execution, restricted management access, and an explicit Tomcat 9-to-10 application test are non-negotiable parts of a reliable deployment.

Product prices and availability are accurate as of the date/time indicated and are subject to change. Any price and availability information displayed on Amazon at the time of purchase will apply.

Leave a Reply

Your email address will not be published. Required fields are marked *

Free tools Windows power users keep installed

One-click scans. No signup required.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

More from the Wire

  1. World desk4 min
    How to Spot an AI Voice Scam Before Sending MoneyDon’t rely on how a caller sounds. Pause, call back through a known number, and verify the emergency with another trusted person before sending money.
  2. Mountain View desk4 min
    Google’s SynthID Detector: How to Check AI-Generated Images, Video and AudioGoogle’s SynthID Detector looks for an embedded watermark in supported images, video and audio. Here is what its results do—and do not—show.
  3. Redmond desk20 min
    How to create a link to File or Folder in Windows 11Windows 11 gives you several ways to point to a file or folder without moving or duplicating it. You can create a desktop shortcut,…
Recommended PC Tool
Recommended PC Tool
Crashes, No Sound, or Screen Glitches?Free driver scan
Windows Errors? Fix Them Before They SpreadFree repair scan

Two free Windows tools

One Free Minute Could Fix That PC

Before you go - each of these free tools takes about a minute and tackles what quietly slows a Windows PC down.

Special offer. View Outbyte info, uninstall instructions, EULA, and Privacy Policy.