Calico Calico BGP peer not reachable.

Network connectivity issues or incorrect BGP configuration.

Understanding Calico and Its Purpose

Calico is a powerful open-source networking and network security solution for containers, virtual machines, and native host-based workloads. It is designed to provide scalable and efficient networking for cloud-native applications. Calico uses a pure Layer 3 approach to networking, which simplifies the network architecture and enhances performance. One of its key features is the use of Border Gateway Protocol (BGP) to distribute routing information, enabling seamless integration with existing network infrastructure.

Identifying the Symptom: BGP Peer Not Reachable

When working with Calico, you might encounter an issue where a BGP peer is not reachable. This symptom is typically observed when there is a failure in establishing a BGP session between Calico nodes or between a Calico node and an external BGP peer. The error message might appear in the logs as CALICO-1022 or similar, indicating a connectivity problem.

Exploring the Issue: CALICO-1022

The error code CALICO-1022 signifies that Calico is unable to reach a configured BGP peer. This issue can arise due to several reasons, such as network connectivity problems, incorrect BGP configuration, or firewall rules blocking BGP traffic. Understanding the root cause is crucial for resolving the issue effectively.

Common Causes of BGP Peer Unreachability

  • Network connectivity issues between the nodes.
  • Incorrect BGP configuration settings.
  • Firewall rules blocking BGP traffic (TCP port 179).

Steps to Resolve the BGP Peer Not Reachable Issue

To resolve the CALICO-1022 issue, follow these detailed steps:

Step 1: Verify Network Connectivity

Ensure that there is network connectivity between the Calico node and the BGP peer. You can use the ping command to test connectivity:

ping <BGP_PEER_IP>

If the ping fails, check the network configuration and routing tables to ensure proper connectivity.

Step 2: Check BGP Configuration

Review the BGP configuration on the Calico node. Ensure that the BGP peer IP address, AS number, and other settings are correctly configured. You can view the BGP configuration using the following command:

calicoctl node status

Refer to the Calico BGP Configuration Guide for detailed configuration instructions.

Step 3: Inspect Firewall Rules

Ensure that firewall rules are not blocking BGP traffic. BGP uses TCP port 179, so verify that this port is open on both the Calico node and the BGP peer. You can use the following command to check firewall rules:

iptables -L -n | grep 179

Adjust the firewall rules if necessary to allow BGP traffic.

Step 4: Review Logs for Additional Clues

Check the Calico logs for any additional error messages or warnings that might provide more context about the issue. Logs can be accessed using:

kubectl logs -n calico-system <calico-node-pod>

Look for any specific error messages related to BGP connectivity.

Conclusion

By following these steps, you should be able to diagnose and resolve the CALICO-1022 issue related to BGP peer unreachability in Calico. Ensuring proper network connectivity, correct BGP configuration, and open firewall ports are key to maintaining a stable BGP session. For more information, visit the Calico Documentation.

Master

Calico

in Minutes — Grab the Ultimate Cheatsheet

(Perfect for DevOps & SREs)

Most-used commands
Real-world configs/examples
Handy troubleshooting shortcuts
Your email is safe with us. No spam, ever.

Thankyou for your submission

We have sent the whitepaper on your email!
Oops! Something went wrong while submitting the form.

Calico

Cheatsheet

(Perfect for DevOps & SREs)

Most-used commands
Your email is safe with us. No spam, ever.

Thankyou for your submission

We have sent the whitepaper on your email!
Oops! Something went wrong while submitting the form.

MORE ISSUES

Made with ❤️ in Bangalore & San Francisco 🏢

Doctor Droid