Tomcat Apache 5.5

Published on December 13, 2007
Some technicalities about Tomcat:
  • You can unrar a war file in an external hard disk, and have Tomcat point to it.
    The simpler way is to change under server.xml, change appBase="webapps" to appBase="J:/MyApps/". All applications will then be hosted under that directory.
    But there are other ways too, such as adding a Context element.

  • To copy .war to Tomcat webapps after building in netbeans, add the following to build.xml:




  • Failed to start apache with service-specific error 0x0.
    Tomcat service log error shows "Failed creating java C:\Program Files\Java\jre1.6.0_03\bin\client\jvm.dll"
    This is due to
    msvcr71.dll not found by Tomcat. Read solution below:
    http://forum.java.sun.com/thread.jspa?threadID=5243681
  • Running multiple Tomcat Containers
    This topic is not detailedly explained.. Here are some help..
    http://azeditech.com/tomcat/multiple-tomcat-instances.html
    http://forum.java.sun.com/thread.jspa?threadID=515368&messageID=2458945
  • To setup a web server to serve .cab OTA installation for Windows Mobile application, add to web.xml:

    cab
    application/x-cab-compressed

  • Increase Java Heap Size
    The default heap size for Tomcat is pretty small. When the memory used is more than the maximum specified, a OutOfMemoryError is frequently encountered.
    A convenient way is to put this in catalina.bat:

    set CATALINA_OPTS="-Xmx256m"
    JavaHowto - For more details..