On my project I have several QA environments, and quite frequently need to debug it. I'm using 'Remote JVM Debug' and it works fine, but also I want to see logs. I already configured bash script to run tailf over SSH and write it to local file and in debug configuration define local file to see it in log tab of Debug view. But now I'm running these scripts manually and then running debug, and after dubug session I need to stop tailf and disconnect SSH. If I put this scripts to 'Before launch' section, it will wait until this scripts will be completed, and wont start debug itself. I know that I can define run this scripts in background, but I want them to disconnect and terminate when I'm stopping debugging. Is there some solution for this?
Related
i want to stop a Minecraft server (java) from an empty cmd window (in the server window, we just can type "stop" to stop the server),
because I want to automatize the start and the stop of the server with os library with :
os.system("the command i search")
I don't want to kill the task , because with this method, the server is not stopped properly, and we lost a lot of data.
As for automation of the start of the server, that's simple. Either put a shortcut to your server file in your Startup folder in Windows or put a shortcut to your run.bat file in the same folder. For shutting it down, that might be a pain. I can tell from using the os.system() method that you're using Python. Stopping the server from a clear command window is something I don't know how to do, but I did find a "life-hack" you can do. This plugin is made to automatically restart your server at a specific time of day. But you should be able to configure it to just shut down, instead of a restart. Even if you made it restart, you could make the PC it's hosted on shut down just after the server restarts. This would cause a crash, granted, but it would also save all progress.
I am attempting to configure an application for remote debugging. I am attempting to use the instructions under https://wrapper.tanukisoftware.com/doc/english/qna-eclipse-remote.html and have added the following lines to my wrapper.conf
wrapper.java.additional.16=-Xdebug
wrapper.java.additional.17=-Xrunjdwp:transport=dt_socket,address=8001,server=y,suspend=y
When I start my application using console console the application does not freeze with the following:
Listening for transport dt_socket at address: 8001
instead it carries on running and I cannot connect to it. Can anyone advise what settings I may be missing in order to allow the application to be remotely debugged.
One of the earlier configuration number was commented out
#wrapper.java.additional.13
This appears to mean that 14,15,16,17 were also ignored. I re-numbered these and can now debug.
This might be silly question but I really don't know it.
I have performed some changes in my web application in java/jsp.
Tested it in localhost in eclipse where I can see logs in console.
After that I have deployed the changes to beta server and its not
reflecting as in localhost hence want to see running logs through
tomcat console but Tomcat is already running and was started with
services utility of windows.
Is there any way to open console of running tomcat.
I do know that we can see tomcat logs as well, but running console
will be preferred for me as there are multiple projects are running on
same server.
You can check log file(s) in the tomcat-home/logs folder.
You can attach Eclipse to a running process if you have started the server with the right settings: see Attach debugger to application using Eclipse On windows, you can either delete and reinstall the services as in https://tomcat.apache.org/tomcat-7.0-doc/windows-service-howto.html or, you can add these parameters in the Windows registry for the Tomcat you are running: see http://www.tomcatexpert.com/knowledge-base/allocating-more-ram-tomcat-windows . I would be very careful with the registry hack unless you've hacked the registry before and are comfortable doing it.
How does one debug mpijava code. Ideally, I would want to debug it on the same machine with eclipse with a master and a client running and attached to the same eclipse. Though these might be two processes but since eclipse can debug multiple running threads, may be that is possible ?
Run server with options:
-Xdebug -Xrunjdwp:transport=dt_socket,address=8998,server=y
Then run eclipse and connect to 8998 port. See How To Debug a Remote Java Application for details.
I'm working with a certain external server product which happens to be proprietary. However, I do have the ability to modify the server's startup scripts. What I'd like to do is essentially set debugging breakpoints in the custom module code which I'm writing so as to be able to fix a bug I'm experiencing in my code.
Is there a way to do this, integrating Eclipse with debugging an external process?
If that certain external server product is a Java server, you should be able to debug your code running in it through standard Java remote debugging.
In Eclipse, open the Debug configurations and add a new configuraion of type "Remote Java Application", and enter the hostname of the server and the port the remote debugger listens to.
In the server startup script, you may need to add an additional Java option to enable remote debugging for the JVM and specify the port. Something like this (excerpt from the JBoss startup config file):
# Sample JPDA settings for remote socket debugging
JAVA_OPTS="$JAVA_OPTS -Xrunjdwp:transport=dt_socket,address=8787,server=y,suspend=n"
(address - 8787 in this case - is the port to connect to)