Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Missing Tomcat8 conf directory

I've just installed Tomcat8 version 8.0.24-1 from Debian 8 repository by aptitude install tomcat8. I tried to play around with Tomcat, starting and stopping it. When I tried to shut it down by running ./bin/shutdown.sh, I noticed that shutdown operation fails - it complains that conf directory is missing. I checked it and that is right - indeed it is missing!

Why?

I downloaded Tomcat8 from official Tomacat website to compare content of both directories - from the Debian's repo and from Tomcat's website. It turned out that directory from Tomcat's website is complete and contains conf directory.

Why is that? Why package from Debian's repo doesn't contain conf directory and bunch of configuration files?

BTW: neither tomcat8-examples nor tomcat8-admin packages contain conf directory.

like image 516
patryk.beza Avatar asked Aug 09 '15 16:08

patryk.beza


People also ask

Where are Tomcat config files?

By default, these files are located at TOMCAT-HOME/conf/server. xml and TOMCAT-HOME/conf/web.

Where is Tomcat home directory?

The default directory for Tomcat files will be in /usr/local/tomcat9, you can view the configuration files inside the conf folder, the main page that you have seen above, when you open your website on the 8080 port is in /usr/local/tomcat9/webapps/ROOT/.

What is Tomcat bin directory?

In the bin folder, the executable programs are contained, including scripts to start and stop the Tomcat instance. The conf folder contains a set of XML and property configuration file. The file server. xml represents Tomcat's main configuration file.

Which Tomcat configuration file is used to manage Tomcat session?

xml is to define the configuration of an instance of the Tomcat 3.3 web server. The parent configuration elements in the server. xml file represent that instance.


2 Answers

/usr/share/tomcat8 contains the application.

All the variable parts (conf, logs, webapps, etc.) are normally in /var/lib/tomcat8

like image 57
Denys Séguret Avatar answered Oct 02 '22 11:10

Denys Séguret


Thats true , the problem is that tomcat8 is setup to have a conf in share as well.. this seems to be because catalina.sh and/or startup.sh fail to specify a separate base even tho the debian maintainers are using one.

The only reasonable fix seems to be to manually edit your catalina.sh and set CATALINA_BASE=/var/lib/tomcat8

This doesn't fix netbeans, which has permissions issues since a lot of that var stuff is owned by root or linked to it... copying those bits to share or adding tomcat8 group to /etc files... please someone have a better answer!

like image 24
user8196687 Avatar answered Oct 02 '22 13:10

user8196687