dosubot[bot] commented on issue #2756: URL: https://github.com/apache/incubator-hugegraph/issues/2756#issuecomment-2832085845
<!-- Greeting --> Hello @ZequanLIU! I'm [Dosu](https://dosu.dev), your friendly bot here to help you tackle bugs, answer questions, and assist with becoming a contributor. I'm ready to help while you wait for a human maintainer! <!-- Answer --> I found a similar open issue titled "[Bug] start server failed but still port in use" <sup>[[1]](https://github.com/apache/incubator-hugegraph/issues/2430)</sup>. The suggested solution involves checking if the server might have started in the background even though the `curl` command timed out, which could lead to the "port already in use" error. Additionally, it's recommended to verify if another process is using the port by running `lsof -i :8080` or `netstat -tuln | grep 8080`. If another process is using the port, you should stop it or change the port that HugeGraph uses. There might also be an issue with the `bin/init-store.sh` script, so checking the logs for any error messages could be helpful. HugeGraph uses a script named `checksocket.sh` to check if a port is already in use during startup. This script utilizes a Java class `org.apache.hugegraph.util.CheckSocket` to perform the check <sup>[[2]](https://github.com/apache/incubator-hugegraph/blob/master/hugegraph-server/hugegraph-dist/src/assembly/static/bin/checksocket.sh)</sup>. To avoid port conflicts during server restarts, you can enable the `RPC_ADAPTIVE_PORT` setting, which allows the server to automatically increment the port number by 1 if the specified port is already in use <sup>[[3]](https://github.com/apache/incubator-hugegraph/blob/master/hugegraph-commons/hugegraph-rpc/src/main/java/org/apache/hugegraph/config/RpcOptions.java)</sup>. <!-- Dosu Comment Footer --> *To continue talking to [Dosu](https://dosu.dev), mention @dosu.* --- <sup>Help Dosu learn! Give it feedback: [Great Response](https://app.dosu.dev/response-feedback/8448a728-ab99-4787-adce-a4f2c351248d?feedback_type=great_response) | [Irrelevant Answer](https://app.dosu.dev/response-feedback/8448a728-ab99-4787-adce-a4f2c351248d?feedback_type=irrelevant_answer) | [Incorrect Sources](https://app.dosu.dev/response-feedback/8448a728-ab99-4787-adce-a4f2c351248d?feedback_type=incorrect_sources) | [Too Verbose](https://app.dosu.dev/response-feedback/8448a728-ab99-4787-adce-a4f2c351248d?feedback_type=too_verbose) | [Hallucination](https://app.dosu.dev/response-feedback/8448a728-ab99-4787-adce-a4f2c351248d?feedback_type=hallucination) | [Bug Report](https://app.dosu.dev/response-feedback/8448a728-ab99-4787-adce-a4f2c351248d?feedback_type=bug_report) | [Other](https://app.dosu.dev/response-feedback/8448a728-ab99-4787-adce-a4f2c351248d?feedback_type=other)</sup> -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: [email protected] For queries about this service, please contact Infrastructure at: [email protected] --------------------------------------------------------------------- To unsubscribe, e-mail: [email protected] For additional commands, e-mail: [email protected]
