Local debugging of PD binding to LAN startup reports an error, but using 127.0.0.1 works fine

Note:
This topic has been translated from a Chinese forum by GPT and might contain errors.

Original topic: 本地调试pd绑定局域网启动报错,使用127.0.0.1就正常

| username: TiDBer_eEiwvfN0

[Test Environment for TiDB] Testing, pd v5.3.0
When compiling and debugging locally, start with
./bin/pd-server --data-dir=pd --advertise-client-urls=http://192.168.1.5:2379 --advertise-peer-urls=http://192.168.1.5:2380

Binding to the local network IP will cause an error, but using 127.0.0.1 works fine.

| username: zhh_912 | Original post link

The first possibility is a firewall or network configuration issue; the second is an incorrect address configuration.

| username: yytest | Original post link

You need to check the firewall configuration.

| username: ShawnYan | Original post link

How about checking the PD logs?

| username: 不想干活 | Original post link

Is it possible that the network card bound to the local IP is down?

| username: TiDBer_rvITcue9 | Original post link

Try pinging the IP.

| username: 小于同学 | Original post link

Take a look at the firewall.

| username: TiDBer_QYr0vohO | Original post link

Try pinging it.

| username: 友利奈绪 | Original post link

Try pinging the IP.

| username: shigp_TIDBER | Original post link

Try pinging the IP.

| username: Jack-li | Original post link

Is it possible that the firewall hasn’t allowed the traffic?

| username: zhh_912 | Original post link

Check the configuration of /etc/hosts.