I am trying to execute the Hawtio-1.5.jar in Linux environment. When I am running the executable, it says port is already in use. Can you suggest how to change the port number in Hawtio jar file to resolve this issue? I cannot change the port number of 8080 which is already using by other my service.
Error logs:
[main] INFO org.eclipse.jetty.webapp.WebAppContext - hawtio at http://0.0.0.0:8080/hawtio
[main] WARN org.eclipse.jetty.util.component.AbstractLifeCycle - FAILED SelectChannelConnector@0.0.0.0:8080: java.net.BindException: Address already in use
java.net.BindException: Address already in use
at sun.nio.ch.Net.bind0(Native Method)
at sun.nio.ch.Net.bind(Net.java:433)
at sun.nio.ch.Net.bind(Net.java:425)
at sun.nio.ch.ServerSocketChannelImpl.bind(ServerSocketChannelImpl.java:223)
at sun.nio.ch.ServerSocketAdaptor.bind(ServerSocketAdaptor.java:74)
at org.eclipse.jetty.server.nio.SelectChannelConnector.open(SelectChannelConnector.java:187)
at org.eclipse.jetty.server.AbstractConnector.doStart(AbstractConnector.java:316)
at org.eclipse.jetty.server.nio.SelectChannelConnector.doStart(SelectChannelConnector.java:265)
at org.eclipse.jetty.util.component.AbstractLifeCycle.start(AbstractLifeCycle.java:64)
at org.eclipse.jetty.server.Server.doStart(Server.java:293)
at org.eclipse.jetty.util.component.AbstractLifeCycle.start(AbstractLifeCycle.java:64)
at io.hawt.embedded.Main.run(Main.java:122)
at io.hawt.embedded.Main.run(Main.java:72)
at io.hawt.app.App.main(App.java:101)
You can change the port number by --port
option:
java -jar hawtio-app-1.5.2.jar --port 8090
See https://hawt.io/docs/get-started/#running-an-executable-jar for more info.