Frage

I have installed Jenkins on Centos machine , but Java is a prerequisite for that and java is using 8080 port by default and when i was starting jenkins server on browser it is giving TCP error ,as it is using 8080 port . hence it is unable to establish a connection for that . So how to change ports in centos or how to access jenkins on 8080 port ..??

War es hilfreich?

Lösung

... and java is using 8080 port by default

Actually, not it isn't.

Java doesn't use any port by default. It is some Java application that is using port 8080 by default. Or if you count Jenkins as well, maybe it is two different Java applications trying to use port 8080.

So how to change ports in centos or how to access jenkins on 8080 port ..??

In general:

  1. Run netstat -a -n to get a list of all applications that are LISTENing, and look for the one that listens on port 8080. This may well reveal that (for example) you already have an instance of Jenkins running(!)

  2. Decide which of the applications should and should not use that port.

  3. Look at the application documentation for how to use a different port.

Note that this may well entail looking at the scripts that you are using to launch various services ...

In this particular case, the port that Jenkins uses is a command line parameter.

Andere Tipps

You can run Jenkins on some other available port using

java -jar jenkins.war --httpPort="Port-No".

java -jar jenkins.war --httpPort="default" is 8080. You can give a port-offset for that like 100 or 1010, and then it would be 8180 or 9090.

By default, the 8080 port is used by many domains like the tomcat Application Server, Oracle DB server, Jenkins, Ajp Port no, http default transport(in case of Jboss). So, make sure that they're not conflicting.

Lizenziert unter: CC-BY-SA mit Zuschreibung
Nicht verbunden mit StackOverflow
scroll top