11

When I attach to a running JVM in Eclipse using socket in a JVM machine running on a diffferent host like production environment, is there a way to get the STDOUT/STDERROR output in console too, i.e to have console enabled too ?

2
  • Don't think so , might be handy sometimes but can't you just open the server log in a handy text editor? I suppose the answer to that is no :) Commented Dec 15, 2011 at 9:35
  • Well, if I can see the console, would be neat. You see, the remote machine is in production mode, so I'm not very sure how to see all of the exceptions, maybe some of them are filtered. Commented Dec 15, 2011 at 9:39

2 Answers 2

2

Kind of...

I recently set up an ant script to deploy updates to a remote server and then automatically restart it. The restart script was called using putty's plink utility from ant. The restart script stopped the server, then started it in remote debug mode so I could link to it from my local eclipse for testing/debuging. The interesting thing though is that I did not start the server as a background process, so all the standard output was sent back to plink and displayed in the ant output in the eclipse console. I'm not sure how useful this maybe as the output is prefixed with the usual ant details, and the ant task does not finish until you stop the remote server.

Edit: on reflection the whole thing could be achieved far easier by calling plink to start your remote environment by creating an "External Tools" run configuration.

Sign up to request clarification or add additional context in comments.

Comments

1

Not directly AFAIK. Alternatively, you could use Eclipse Logfile Viewer to trail the tomcat log.

2 Comments

Nah, using find and grep is far better then viewing the whole file. But I was hopping I can use normally, no matter :(.
how do I install Eclipse Logfile Viewer ?

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.