Tag Info

Hot answers tagged

20

Inside the Service tag change: <Connector port="8080" protocol="HTTP/1.1" ... to: <Connector address="127.0.0.1" port="8080" protocol="HTTP/1.1" ... For more information: http://tomcat.apache.org/tomcat-6.0-doc/config/http.html


14

Ok I finally solved it. I was directed to try this and Henk's solution. Neither of which seemed to work with the remote virtual server. I'm guessing the fact that because I'm on a shared kernel space so the provider prevents this. In any case I added: JAVA_OPTS= $JAVA_OPTS -Djava.net.preferIPv4Stack=true -Djava.net.preferIPv4Addresses to the catalina.sh ...


13

We've been dealing with this issue too. It looks like Amazon found the root cause and corrected it. Here is the info they gave me. Hi, I am pasting below an explanation of what was causing this issue. Good news is that this has been fixed very recently by our engineering team. To get fix, all you'll have to do is STOP/START the Windows Server ...


9

ProxyPass / http://www.abc.com:8080/myApp/ ProxyPassReverse / http://www.abc.com:8080/myApp/ Read more about mod_proxy


9

A neat trick is to run the command "lsof -p PID" where PID is the process id of your tomcat server. This command will give you a list of all files opened by the process, including the log file.


8

Don't touch the init script. Instead, edit the /etc/default/tomcat6 file and comment out the line enabling remote debugging there: # To enable remote debugging uncomment the following line. # You will then be able to use a java debugger on port 8000. JAVA_OPTS="${JAVA_OPTS} -Xdebug -Xrunjdwp:transport=dt_socket,address=8000,server=y,suspend=n"


7

share my experiences,hope it helps step1: enable tomcat plugins sudo ln -s /usr/share/munin/plugins/tomcat_access /etc/munin/plugins/tomcat_access sudo ln -s /usr/share/munin/plugins/tomcat_jvm /etc/munin/plugins/tomcat_jvm sudo ln -s /usr/share/munin/plugins/tomcat_threads /etc/munin/plugins/tomcat_threads sudo ln -s /usr/share/munin/plugins/tomcat_volume ...


6

Taken from this page add "digest" attribute on your element in server.xml with a hash algorithm as value (possible values are for example md5, sha-1 or sha-256, where the latter is strongly recommended). Run $CATALINE_HOME/bin/digest.sh -a <YOUR_HASH_ALGORITHM> <YOUR_PASSWORD> You will get an output in the following form ...


5

By the look of the error the Tomcat native launcher does not find the rt.jar file in your JRE install. Make sure that: the JVM is correctly installed; the JRE_HOME variable points to it.


5

It looks way too "procedural," IMO. You have to think in a "declarative" way. I would personally just create .rpm's or .deb's from those tarballs, and specify another repo to use so all you would have to do is something like this: class tomcat { Package { "tomcat": ensure => installed, } File { "/etc/init.d/tomcat": source => ...


4

By default check /var/log/tomcat6/catalina.out or something like that and check logging properties in /usr/share/tomcat6/conf/logging.properties usually /usr/share/tomcat6/conf/ is symbolic link to /etc/tomcat6/


4

Ok first thing: Do you really need to use a Java Security Policy? The simplest solution by far is to disable this in tomcat's startup script: in /etc/init.d/tomcat6 replace TOMCAT6_SECURITY=yes with TOMCAT6_SECURITY=no Assuming you must use the security manager, and you must match an existing installation, I would suggest un-installing ...


4

How do I update for 3 web servers? Do the same as when doing with 2 nodes. On the deployment node, add one more member in StaticMembershipInterceptor: <Member className="org.apache.catalina.tribes.membership.StaticMember" port="4002" securePort="-1" host="192.168.5.208" ...


4

The first location you should take a look at is catalina.out, it will tell you what might be wrong. If you can't make it works with multicast, just try static membership (I think it will simpler). Below is my config: Put the <Cluster node inside the <Host element: <Engine name="Catalina" defaultHost="localhost" jvmRoute="tomcat1"> ...


4

I don't have enough reputation to add a comment to @Michael's answer above, so I'm adding as an answer - First, it's a great answer! However, when you mention manually running and checking using "/etc/munin/plugins/tomcat_jvm," this doesn't pick up the environment variables from /etc/munin/plugin-conf.d/munin-node (i.e. user/password), so it fails. The ...


4

Many suggested updating catalina.sh startup script. Yes, that solution would work, but catalina.sh script is not meant to be customized/updated. All changes should go into the customization script instead, i.e. setenv.sh. NOTE: TOMCAT_HOME/bin/setenv.sh doesn't exist by default, you need to create it. Check the catalina.sh script and you will see the ...


4

I would use at least an m1.small or better an m1.large Instance. The micro-instance really is for development only, because the 613MB may soon not be enough even with zero users. Besides that, you will most likely see a lot of CPU steal time and your Server will not react some time after you had a small cpu peak. That is very annoying. I would try to get ...


4

I've recently seen this problem as well and it appears to be isolated to a change made in the 32-bit Oracle JVM between Java 6 and 7. On Linux, running the 32-bit Java 7 VM with strace shows the following system call when ServerSocket.accept() is invoked without having set SO_TIMEOUT: 32369 poll([{fd=5, events=POLLIN|POLLERR}], 1, 4294967295 <unfinished ...


4

Tomcat always returns status code 400 Because the webapps directory is empty: # ls -l /usr/share/tomcat6/webapps/ total 0 https://issues.apache.org/bugzilla/show_bug.cgi?id=50734 Either create a dummy ROOT context to get a 404 status: # mkdir /usr/share/tomcat6/webapps/ROOT # ls -l /usr/share/tomcat6/webapps/ total 4 drwxr-xr-x 2 root root 4096 ...


3

That class is part of the tomcat6-examples package. Install that package, ensure it's in the classpath, and all should be well.


3

Problem The problem with the standard Tomcat shutdown script is that it is simply not tough enough. When you are using your distro's service scripts to stop Tomcat you'll eventually simply be calling Tomcat's own shutdown script. CentOS is no different in this respect. For this reason you need to be familiar with what Tomcat's shutdown script can do for you ...


3

You can turn auto deployment on but it is not considered a best practice due to security concerns. With tomcat 7, you also have what is called "parallel deployment", which sounds cool but I have not read about other people's experiences with it. In theory, you will have your old version being served up alongside your new version. Established sessions would ...


3

I was experiencing the same problem using Tomcat 7.0.35 with Java 1.7.0_10 (32bit) on a 64-bit Debian Linux. In my case updating and using the 64bit JDK solved this problem


3

Quercus is a Java implementation of PHP5.


3

Those are the options for your JVM. to get the definitive list for the version you are running you can type java -h for the standard options and java -X for the non-standard options "the -X[X] options


3

I completely randomly found this thread while looking to debug a separate issue, but this is a little-brought-up, but well-known issue with Windows on EC2. We used to have premium support, and discussed this with them in a non-public setting via that channel, but this is a related issue that we did discuss in the public forums. As others have mentioned, you ...


3

Install a real webserver, like Apache or nginx, and use it's built-in proxying capabilities (mod_proxy on Apache, and HttpProxy core module on nginx) to proxy the path to the appropriate Tomcat application running on a high port.


3

Install apache and use mod_rewrite to proxy the requests to the backend tomcat applications. Here's a sample snippet of apache config that should do it: RewriteEngine on #Optional - setup a log, useful for debugging #RewriteLog logs/rewrite.log #RewriteLogLevel 3 RewriteRule ^/myAPP1(.*) http://10.XXX.XXX.XXX:8080/myAPP1$1 [P,L] RewriteRule ^/myAPP2(.*) ...



Only top voted, non community-wiki answers of a minimum length are eligible