0

I would like to troubleshoot an issue that I think it happens only in my just made up environment. I have an almalinux 9 with apache tomcat 10 and openlogic jdk version 11. Installation seemed to work fine (all using tar.gz) and I can see at ip:9080 the tomcat greeting and I can access the manager gui. And I can see that everything is owned by the existing user tomcat.

 ps aux shows
tomcat 16179 0.3 7.6 9282676 1897144 ? Sl Nov26 3:47 /opt/java11/bin/java -Djava.util.logging.config.file=/opt/tomcat10j11/conf/logging.properties -Djava.util.logging.man
netstat -polent shows
tcp6 0 0 :::9080 :::* LISTEN 1000 152959 16179/java off (0.00/0/0)

I copied some war files inside the /opt/tomcat10j11/webapps/ folders and the logs from catalina.out are telling me that for every war file I got

SEVERE [Catalina-utility-1] org.apache.catalina.startup.HostConfig.deployWAR Error deploying web application archive [/opt/apache-tomcat-10.1.33/webapps/name_of.war]
java.lang.IllegalStateException: Error starting child
Caused by: org.apache.catalina.LifecycleException: Failed to initialize component [org.apache.catalina.webresources.WarResourceSet@533c9e9a]at org.apache.catalina.util.LifecycleBase.handleSubClassException(LifecycleBase.java:406)
Caused by: java.lang.IllegalArgumentException: java.io.FileNotFoundException: /opt/apache-tomcat-10.1.33/webapps/name_of.war (Permission denied) at org.apache.catalina.webresources.AbstractSingleArchiveResourceSet.initInternal(AbstractSingleArchiveResourceSet.java:141)

So my assumption is that permission denied means that the folder and the file should be owned by tomcat. At that point I run chown -R tomcat:tomcat /opt/apache-tomcat-10.1.33/ after that I try to restart the server, but I keep getting the 404 error. Where should I look and how can I troubleshoot tomcat/war deployment?

asked Nov 27, 2024 at 11:30

1 Answer 1

0

The issue is with the tomcat - java version used. In order to have the war working in this environment I have to use openlogic jdk version 11 AND tomcat 9

answered Nov 27, 2024 at 14:09

You must log in to answer this question.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.