Escolar Documentos
Profissional Documentos
Cultura Documentos
Apache Tomcat
Apache Tomcat
Apache Tomcat is a web container that allows you to serve Java Servlets and JSP (Java Server Pages) web applications. The Tomcat 6.0 packages in Ubuntu support two different ways of running Tomcat. You can install them as a classic unique system-wide instance, that will be started at boot time will run as the tomcat6 unprivileged user. But you can also deploy private instances that will run with your own user rights, and that you should start and stop by yourself. This second way is particularly useful in a development server context where multiple users need to test on their own private Tomcat instances. System-wide installation Configuration Using Tomcat standard webapps Using private instances References
System-wide installation
To install the Tomcat server, you can enter the following command in the terminal prompt: s u d oa p t g e ti n s t a l lt o m c a t 6 This will install a Tomcat server with just a default ROOT webapp that displays a minimal "It works" page by default.
Configuration
Tomcat configuration files can be found in / e t c / t o m c a t 6 . Only a few common configuration tweaks will be described here, please see Tomcat 6.0 documentation for more.
2/28/2014
Apache Tomcat
various JVMs installed, you can set which should be used by setting JAVA_HOME in / e t c / d e f a u l t / t o m c a t 6 : J A V A _ H O M E = / u s r / l i b / j v m / j a v a 6 s u n
Tomcat documentation
The tomcat6-docs package contains Tomcat 6.0 documentation, packaged as a webapp that you can access by default at http://yourserver:8080/docs. You can install it by entering the following command in the terminal prompt: s u d oa p t g e ti n s t a l lt o m c a t 6 d o c s
2/28/2014
Apache Tomcat
s u d oc h m o dRg + w/ e t c / t o m c a t 6
2/28/2014
Apache Tomcat
instance is located in the m y i n s t a n c edirectory): m y i n s t a n c e / b i n / s t a r t u p . s h You should check the l o g s /subdirectory for any error. If you have a java.net.BindException: Address already in use<null>:8080 error, it means that the port you're using is already taken and that you should change it. You can stop your instance by entering the following command in the terminal prompt (supposing your instance is located in the m y i n s t a n c e directory): m y i n s t a n c e / b i n / s h u t d o w n . s h
https://help.ubuntu.com/12.04/serverguide/tomcat.html
4/4