Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Port selection not working #23

Closed
senthil13 opened this issue Sep 4, 2019 · 7 comments
Closed

Port selection not working #23

senthil13 opened this issue Sep 4, 2019 · 7 comments
Labels
question Further information is requested

Comments

@senthil13
Copy link

Even though specfy different port than 9000, still the kafdrop listen on 9000.

ps ax | grep -i "kafdrop.jar" | egrep -v "grep" | awk '{print $1}'
1199

netstat -plant | grep 9000
tcp6       0      0 :::9000                 :::*                    LISTEN      1199/java

netstat -plant | grep 9010
tcp6       0      0 :::9010                 :::*                    LISTEN      1199/java
@shaaimin
Copy link
Contributor

@senthil13
which command did you used to start kafdrop?
like java -jar kafdrop-3.8.1.jar --server.port=9001 > kafdrop.log &

@senthil13
Copy link
Author

Sorry for delay in response.

below is the command i used.

nohup java -jar kafdrop.jar --zookeeper.connect=<servername:port> --server.port=9010 >> kafdrop.$(date +"%F").out &

@shaaimin
Copy link
Contributor

@senthil13
i also tried on my local, it seems that port not be changed...

could you try the following one? i think it works.
nohup java -Dspring.application.json='{"server.port":9010}' -jar kafdrop.jar --zookeeper.connect=servername:port >> kafdrop.$(date +"%F").out &

@ekoutanov
Copy link
Member

@senthil13 @shaaimin

Kafdrop uses Undertow to serve both the user-facing content (web pages and REST APIs) as well as the /actuator endpoint for serving metrics. These can be served on two different ports, but both default to 9000.

To change both, thereby freeing 9000 altogether, pass in the following arguments:

--server.port=9001 --management.server.port=9001

@ekoutanov ekoutanov added the question Further information is requested label Sep 24, 2019
@ekoutanov
Copy link
Member

Updated the README for the 'make-benefit of future generation' :) And closing issue.

@dlipofsky
Copy link

Environment variables SERVER_PORT and MANAGEMENT_SERVER_PORT also work, although the README only mentions the former.

@Bert-R
Copy link
Collaborator

Bert-R commented Aug 18, 2023

Added it in #553

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
question Further information is requested
Projects
None yet
Development

No branches or pull requests

5 participants