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.
By default, these files are located at TOMCAT-HOME/conf/server. xml and TOMCAT-HOME/conf/web.
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/.
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.
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.
/usr/share/tomcat8
contains the application.
All the variable parts (conf
, logs
, webapps
, etc.) are normally in /var/lib/tomcat8
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!
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With