0

I installed the jetty java server on Windows. I went to the installation directory and double-clicked on the start.jar file. Now a server is constantly listening at port 8080. I need to stop this server.

I checked both online and the documentation and the closest I've come to the solution is this:

$ {jetty home}/ java -jar start.jar STOP.KEY=[PASSWORD] STOP.PORT=[PORT] --stop

I have tried this many times but it doesn't work. Also tried without the STOP.PORT directive and without the STOP.PASS directive with no success. Apparently, I need the STOP.KEY which was used to start the server. But, as I double-clicked the .jar file to run it, I have no idea of what I have actually done. I've been looking for several hours for some sort of default password, or a service to kill, anything that allows me to free the port 8080 but I haven't found any solutions.

There is a question about how to stop it from Eclipse but didn't work for me.

Does anyone know how to kill jetty if it started double-clicking the start.jar file?

ppicom
  • 318
  • 2
  • 11

1 Answers1

0

This is not the solution. But it´s a workaround if you need to stop the process somehow:

Found in this question by @brad-wilson how-can-you-find-out-which-process-is-listening-on-a-port-on-windows

  1. First, find the process running on the port:
PS: Get-Process -Id (Get-NetTCPConnection -LocalPort <PORT>).OwningProcess
  1. Then kill it like this:
PS: Stop-Process -Name <PROCESS_NAME>

This should have freed the port.

ppicom
  • 318
  • 2
  • 11