Question

I am sure I would be able to find the answer if I knew the right terminology for some of these things, but basically the problem is:

Every time I have run a something in Eclipse (Java) before, there has been a square red button (hovertext "Terminate") in the "Console" tab of the bottom-right (wide) window (in "Java" perspective) that I could use to terminate a program.

I recently added a new project (to isolate and figure out some code I was having trouble with in the main project...but that's a different story), and now: (a) it seems to be running more than just what I want it to run, and (b) the red button is sometimes not available, but clearly something is running because when I hover over the "Run", button, it says "Run [program name here] (already running)" instead of "Run [program name here]".

Can anyone tell me why this would happen? Can anyone tell me how to terminate a program when you don't have a terminate button?

(...and I won't ask here how to get Eclipse to stop running things I don't want it to run, since I haven't scoured the internet for the answer to that one for long enough to justify a StackOverflow question, but it's probably coming...)

Update: This button cleared things up (after the double-x icon button hint helped). Eclipse should really have a separate "Console" tab for each console, though!

button to switch between consoles (if pressed directly), or select console to view (if press drop-down arrow)

Was it helpful?

Solution

Sometimes the running console can be hidden behind a terminated console. Look for the grey double-x on the console display to remove inactive consoles, and see if your red box shows up again.

OTHER TIPS

Click the xX(double X) on console. this will remove all inactive consoles

enter image description here

enter image description here

Click on the above icon and you can see all running applications or terminated whihch is in my case.

Although the issue has been resolved, posting a method that would help MAC users.

I was running Tomcat on ports 8080(http) and 8443(https). The same error occurred as some processes are running on them and the following helped me.

lsof -i :8080 //returns the PID (process id) that runs on port 8080
kill 1234 //kill the process using PID (used dummy PID here)
lsof -i :8443
kill 4321

PID is shown as

COMMAND  PID       USER   FD  TYPE              DEVICE  SIZE/OFF  NODE  NAME
java     3240   vignesh  46u  IPv6  0x5ccb07da8bf4a3a5       0t0   TCP  *:http-alt (LISTEN)

Restarted eclipse and restarted the server. (Without eclipse restart, restarting the server alone didn't work for me.)

SOLVED : Now, you go to WINDOW > SHOW VIEW > CONSOLE after clicking these steps Console window is open.but this step you have to done manually because in background your PROGRAM ALREADY RUNNING but after run Program Console window not open automatically like before when we press Run or Ctrl+F11.so,this is only way you can execute your code and you can also press pinned option under the console window menu option on top horizontally given to get rid of this problem and you will able to continue your work.

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top