03-06-2015 08:23 PM - edited 03-05-2019 12:58 AM
Dear All, As we know, BGP peer relation needs reachability of tcp 179. But usually if the two peer neighbors can ping each other, we can consider the tcp 179 is working well. So what is relationship between ping and tcp in BGP in this situation ? Thank you !
Solved! Go to Solution.
03-09-2015 01:26 AM
Ping is a tool in the ICMP suite, and doesn't use ports. It uses codes. TCP is a different protocol, and does use ports. In the case of BGP, once the process is started (and you have at least one neighbor command) it will open port 179. Who is the client and who is the server in the neighborship, does not matter. If you have issues with BGP neighbors being formed, and you believe the configuration is correct - Telnet to the port to be sure that it is working. Also, if they are not directly connected, you may need to enable multihop. Check Access lists also.
Pinging the other router it is unrelated to the BGP TCP process. - Here is an example pinging fine, but before the BGP process has opened port 179.
There is just two routers on a /30 segment - 10.19.2.2 and 10.19.2.1
LON-ROUTER#ping 10.19.2.1
Type escape sequence to abort.
Sending 5, 100-byte ICMP Echos to 10.19.2.1, timeout is 2 seconds:
.!!!!
Success rate is 80 percent (4/5), round-trip min/avg/max = 8/9/12 ms
Pings fine.
LON-ROUTER#
LON-ROUTER#telnet 10.19.2.1 179
Trying 10.19.2.1, 179 ...
% Connection refused by remote host
Enable BGP on the neighbor:
LON-CORE(config)#router bgp 65000
LON-CORE(config-router)#neighbor 10.19.2.2 remote-as 65001
LON-CORE(config-router)#
try the TCP connection again
LON-ROUTER#
LON-ROUTER#telnet 10.19.2.1 179
Trying 10.19.2.1, 179 ... Open
The connection now works, as the port is open on the neighbor.
03-09-2015 01:26 AM
Ping is a tool in the ICMP suite, and doesn't use ports. It uses codes. TCP is a different protocol, and does use ports. In the case of BGP, once the process is started (and you have at least one neighbor command) it will open port 179. Who is the client and who is the server in the neighborship, does not matter. If you have issues with BGP neighbors being formed, and you believe the configuration is correct - Telnet to the port to be sure that it is working. Also, if they are not directly connected, you may need to enable multihop. Check Access lists also.
Pinging the other router it is unrelated to the BGP TCP process. - Here is an example pinging fine, but before the BGP process has opened port 179.
There is just two routers on a /30 segment - 10.19.2.2 and 10.19.2.1
LON-ROUTER#ping 10.19.2.1
Type escape sequence to abort.
Sending 5, 100-byte ICMP Echos to 10.19.2.1, timeout is 2 seconds:
.!!!!
Success rate is 80 percent (4/5), round-trip min/avg/max = 8/9/12 ms
Pings fine.
LON-ROUTER#
LON-ROUTER#telnet 10.19.2.1 179
Trying 10.19.2.1, 179 ...
% Connection refused by remote host
Enable BGP on the neighbor:
LON-CORE(config)#router bgp 65000
LON-CORE(config-router)#neighbor 10.19.2.2 remote-as 65001
LON-CORE(config-router)#
try the TCP connection again
LON-ROUTER#
LON-ROUTER#telnet 10.19.2.1 179
Trying 10.19.2.1, 179 ... Open
The connection now works, as the port is open on the neighbor.
03-11-2015 06:24 PM
Thank you for your reply.
Discover and save your favorite ideas. Come back to expert answers, step-by-step guides, recent topics, and more.
New here? Get started with these tips. How to use Community New member guide