Hardware FixRecommendedDevice not working? Your driver may be the problemCheck updates for common hardware issues.Fix DriversHalloween DealsAmazon USHalloween week deals: useful picks before month-endAmazon US: current deals, useful picks and tech finds.Check DealsSlow PC?RecommendedPC slow today? Run a repair scan before it gets worseResolve common Windows issues and optimize system performance.Scan Now×
Skip to content
World desk5 min

How to Fix Tomcat Not Working on a Linux VPS

A precise Tomcat VPS troubleshooting guide that starts with the first log error, verifies Java and CATALINA_BASE, confirms the listening connector, and separates local service failures from firewall, DNS, and proxy problems.
Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

Fix Tomcat from the inside out: first determine how it is launched, then read the first startup error, verify the Java runtime and CATALINA_BASE, confirm the connector socket, and only afterward investigate firewalls, DNS, or a reverse proxy. A successful Java process alone does not prove that Tomcat is healthy.

Start with a five-minute triage

Use the result of each test to choose the next layer. Do not change several layers at once; otherwise you will not know which change solved the failure.

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.
  1. Check the service state. If Tomcat is managed by systemd, run sudo systemctl status tomcat (replace tomcat with the unit name used by your VPS) and then sudo journalctl -u tomcat -b --no-pager. A unit can be named after a version, an application, or a custom installation.
  2. Find the first meaningful error. Inspect the instance’s logs/ directory and any output files configured by the startup method. In a Unix daemon setup, Apache documents catalina.out and catalina.err as possible destinations. Fix the earliest Java, path, permission, bind, or deployment error rather than the later cascade.
  3. Test locally on the VPS. Run curl -i http://127.0.0.1:8080/, substituting the connector port from conf/server.xml. If this fails, stay focused on Tomcat, Java, its files, or local permissions.
  4. Inspect the listening socket. Use sudo ss -ltnp and look for the address and port owned by the Java process. No socket means startup or connector failure; a different process on that port means a conflict.
  5. Only then test the public path. If localhost works but the domain does not, check the VPS firewall, provider firewall or security group, DNS, listener address, and reverse-proxy forwarding.

This order prevents a common mistake: opening port 8080 to the Internet when Tomcat never started, or rebuilding Tomcat when the real problem is a blocked provider firewall.

Identify how Tomcat is launched

The correct logs, environment, and restart command depend on the launch method. A package installation, a custom archive, and the shell or daemon scripts do not necessarily use the same user or paths.

#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.

systemd unit

Check loaded units with systemctl list-units --type=service | grep -i tomcat. Then inspect the effective definition:

sudo systemctl cat tomcat
sudo systemctl status tomcat --no-pager
sudo journalctl -u tomcat -b --no-pager

Look in the unit for User=, Environment=, EnvironmentFile=, ExecStart=, CATALINA_HOME, and CATALINA_BASE. Run diagnostic commands as the same account where practical; an interactive shell may have a different PATH and JAVA_HOME from systemd.

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

Distribution package

Package-managed Tomcat may place configuration, logs, and web applications in distribution-specific directories and may use a versioned unit name. Do not assume that the directory from a downloaded archive is the active instance. The unit definition and its environment file are authoritative for that VPS.

Shell scripts or jsvc

For a manual installation, inspect $CATALINA_BASE/logs and the files redirected by the startup command. Apache’s Unix daemon example uses catalina.out and catalina.err. Capture the complete command, account, working directory, and exported variables before changing them. A command that succeeds from your login shell can fail when run by a service account.

Read the first real startup error

Tomcat often emits many secondary messages after one early failure. Search the beginning of the failed boot in the journal and the newest files in logs/. Classify the first actionable message:

  • Java executable or JAVA_HOME error: the service cannot find the required runtime, or the variable points to a nonexistent directory.
  • Bind exception: another process already owns the configured address and port, or the service lacks permission to bind the chosen port.
  • Permission denied: the service account cannot read configuration or write logs, temporary files, work files, or deployment directories.
  • Missing configuration: the active base directory lacks required files such as conf/server.xml or conf/web.xml.
  • Deployment failure: Tomcat starts, but an application or context fails while being deployed.
  • Application stack trace: the container is running and the defect is inside the application, its dependencies, or its configuration.

Save the first error and the surrounding lines before restarting repeatedly. A restart can rotate or overwrite the most useful evidence.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.
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.

Verify Java for the Tomcat major version

Tomcat checks the Java runtime visible to its own process, not necessarily the one shown by your shell. Compare both environments:

java -version
readlink -f "$(command -v java)"
sudo -u tomcat env | grep -E 'JAVA_HOME|PATH'
sudo -u tomcat java -version

Use the real service account and unit name on your VPS. For systemd, inspect the unit’s environment and start command rather than relying on shell startup files.

Tomcat line Minimum Java version What to verify
Tomcat 9.0.x Java 8 or later The service account resolves a supported Java executable.
Tomcat 10.1.x Java 11 or later Apache’s migration guidance states that Java 11 is the minimum.
Tomcat 11.0.x Java 17 or later Apache’s Tomcat 11 migration guide states that Java 17 is the minimum.

Installing a newer Java globally does not fix a unit that still points to an older or removed path. Set JAVA_HOME to the Java installation directory (not the bin/java file), ensure the service account can traverse it, then reload and restart the unit:

sudo systemctl daemon-reload
sudo systemctl restart tomcat
sudo systemctl status tomcat --no-pager

Use the exact variable and path expected by the existing unit. If the error changes from an executable problem to an application compatibility error, Java discovery is fixed and the next layer needs attention.

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

Check CATALINA_HOME and CATALINA_BASE

CATALINA_HOME identifies the Tomcat installation. CATALINA_BASE contains instance-specific configuration, logs, deployed applications, work, and temp. Multiple instances can share one home while using separate bases.

Print the values in the same context as the service, then inspect the active base:

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
echo "$CATALINA_HOME"
echo "$CATALINA_BASE"
find "$CATALINA_BASE/conf" -maxdepth 1 -type f -printf '%fn'
ls -ld "$CATALINA_BASE" "$CATALINA_BASE/conf" "$CATALINA_BASE/logs" "$CATALINA_BASE/temp" "$CATALINA_BASE/work"

If variables are empty in your shell, obtain them from systemctl cat, an environment file, or the wrapper script. Apache warns that the required conf/server.xml and conf/web.xml must exist in CATALINA_BASE; a missing file can stop startup or normal operation. A frequent upgrade error is pointing the new service at an old, partially copied base.

Do not replace a working base wholesale. Confirm which settings are intentional, compare the new release’s default configuration, and copy only the required changes.

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

Repair ownership and write permissions safely

Tomcat should not run as root. Apache recommends a dedicated non-root account with minimum permissions. Identify the account in the unit or startup script and test access as that account:

sudo -u tomcat test -r "$CATALINA_BASE/conf/server.xml" && echo readable
sudo -u tomcat test -w "$CATALINA_BASE/logs" && echo logs-writable
sudo -u tomcat test -w "$CATALINA_BASE/temp" && echo temp-writable
sudo -u tomcat test -w "$CATALINA_BASE/work" && echo work-writable

Replace tomcat and the variable with your actual values. The account needs read and directory-traverse permission for the installation and configuration, plus write access to runtime locations used by that instance: especially logs, temp, work, and deployment directories.

Correct ownership narrowly, for example with an administrator-approved command such as sudo chown -R tomcat:tomcat /path/to/instance when that entire instance is intended to belong to the service account. Do not make the installation world-writable. Recheck parent-directory permissions, ACLs, and security policies if ownership appears correct but access is still denied.

Confirm the connector and port

Apache’s security guidance says that a non-TLS HTTP/1.1 connector is configured on port 8080 by default. The default is not a guarantee: the active conf/server.xml value wins.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.
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.
grep -nE '

Use the actual configured port in the curl command. A connector may bind only to a specific address rather than all interfaces. A request to 127.0.0.1 can therefore work while a request to the VPS's public address fails, or the reverse.

Resolve a port conflict

A bind failure means another process already owns the same port and IP. The HTTP connector reference notes that only one server application can listen on a particular port number and IP address. Identify the owner with sudo ss -ltnp (or your platform's equivalent), then choose one deliberate action:

  • stop or reconfigure the unrelated process;
  • move Tomcat to an unused connector port and update every proxy rule and firewall rule; or
  • change the bind address when two services can safely share a port on different interfaces.

Restarting without resolving the owner will reproduce the same failure.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.
Independent reader supportYour contribution helps us test, update, and keep practical guides available for everyone.Support on Ko-Fi

Separate Tomcat failure from network failure

When localhost fails

Connection refused or a timeout on the VPS itself points to a stopped process, wrong port, failed bind, local firewall, or listener-address mismatch. Check the systemd result, the first startup error, the socket list, and server.xml before changing DNS.

When localhost works but the public address fails

Tomcat has accepted a local request, so inspect the path between the Internet and that socket:

  • Confirm the domain's DNS record resolves to the intended VPS address.
  • Check the VPS firewall and the hosting provider's firewall or security group.
  • Confirm that the connector listens on an address reachable from the proxy or external client, not only loopback.
  • Verify that any reverse proxy is running and forwarding to the same port that passed the local curl test.

Apache's troubleshooting guidance provides a useful boundary: if the request is absent from Tomcat's access log, Tomcat did not process it. Investigate the listener, firewall, DNS, or proxy layer instead of the application.

Fix Apache or Nginx reverse-proxy forwarding

A reverse proxy should target the connector that works locally. Check the proxy's upstream address and port, then compare it with server.xml and the socket list. A one-digit port mismatch is enough to produce a public 502 or connection-refused error while direct localhost access remains healthy.

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.

For Apache HTTP Server, verify the forwarding rule and the response rewrite setting. Apache's proxy documentation uses ProxyPass to send requests to a Tomcat connector and recommends ProxyPassReverse so backend redirects are rewritten for clients. After editing, validate and reload Apache using the command appropriate to your distribution, then test the domain again.

Restrict the backend connector so only the proxy host can reach it when the architecture permits. This reduces direct exposure of the Tomcat port while leaving the public HTTP or HTTPS endpoint at the proxy. Do not expose an administrative or unencrypted connector merely to make troubleshooting easier.

For Nginx, inspect the proxy_pass destination, the active server block, and the reload result. Confirm that the request reaches the expected virtual host and that TLS termination, host headers, and redirects are consistent with the application. If the proxy access log shows the request but Tomcat's access log does not, inspect the upstream connection and proxy error log.

Handle deployment and application failures

Tomcat can be running even when one application returns an error. Distinguish a container health check from an application health check:

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.
  • A listening connector and a successful request to the root context show that the container accepted traffic.
  • A failed application context usually appears in deployment logs with a stack trace, missing dependency, invalid descriptor, or incompatible API.
  • Test the failing context path separately from the root URL and inspect the corresponding access and application logs.

Do not “fix” an application stack trace by deleting all of work or changing ownership broadly. Preserve logs, make a targeted change, and restart only when the application or container requires it.

Upgrade without carrying the old failure forward

Treat a Tomcat upgrade as a compatibility change, not a file-copy operation. Start with the new release's default configuration and reapply intentional connector, host, valve, realm, and proxy settings one at a time. Do not copy a previous major release's configuration wholesale; obsolete attributes or changed defaults can prevent startup.

Moving from Tomcat 9 to Tomcat 10 or later can require application changes because the Java web API namespace changes from javax.* to jakarta.*. A container that starts successfully can still reject an application compiled for the old namespace. Keep the previous installation available for rollback, point the new unit at a separate CATALINA_BASE, and switch traffic only after the local connector and application contexts pass their checks.

Choose the least risky fix

Failure layer Typical evidence Preferred scope Reversibility and security
Process or unit systemd reports failed; no Java socket Correct the unit command, environment, or dependency Highly reversible; keep the service non-root
Java runtime Unsupported version, missing executable, wrong JAVA_HOME Point the service to a supported Java installation Reversible; test as the service account
Filesystem Permission denied or missing base files Restore required files and narrow ownership/write access Reversible; avoid world-writable directories
Connector Bind exception, wrong port, no listener Free or deliberately change the port and update dependants Reversible; avoid unnecessary public exposure
Firewall or DNS Local curl works; public request never reaches access log Correct records and network policy Change only the required rule; retain least exposure
Proxy Proxy error or wrong backend; Tomcat local test passes Match upstream port and add response rewriting where required Reversible; restrict direct backend access

A repeatable recovery runbook

  1. Record the unit name, service account, installation path, base path, Java version, configured connector port, and current error.
  2. Read the first meaningful journal or Tomcat log error and classify it by layer.
  3. Verify the Java minimum for the Tomcat major version in use, from the service account's environment.
  4. Verify that CATALINA_BASE/conf/server.xml and web.xml exist and that runtime directories are writable by the dedicated account.
  5. Inspect the configured connector and confirm the actual socket with ss.
  6. Run a local curl against that exact address and port.
  7. If local access succeeds, trace DNS, provider and host firewalls, listener address, and proxy forwarding in that order.
  8. After one targeted change, restart or reload the affected service, repeat the local test, and then test the public hostname.
  9. Keep the working configuration and logs so a later upgrade or deployment can be compared against a known-good state.

This sequence answers the most common symptoms: “systemctl failed” is resolved from the unit and first error; “connection refused” is resolved from the listener and port; “localhost works but the domain fails” is resolved outside Tomcat unless the proxy points at the wrong connector; and Java-version errors are resolved in the service environment rather than only in an administrator's shell.

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.

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 *

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
Outdated Drivers Are Slowing You DownFree scan - exact matches
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.