> For the complete documentation index, see [llms.txt](https://docs.thousandeyes.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.thousandeyes.com/product-documentation/tests/bgp-tests/private-bgp-monitoring.md).

# Private BGP Monitoring

Private BGP monitoring uses routing updates from routers that you manage to show your network's perspective on routing. The existing collection method lets your router advertise its routes to internet destinations directly to a ThousandEyes-hosted route collector over an eBGP session, without an Enterprise Agent.

In this context, *private* describes a routing perspective from your network. It does not mean that the monitored routes must use private IP addresses. The Enterprise Agent collection method extends this capability to local collection, including routes with private autonomous system (AS) numbers, private prefixes, or both.

Public BGP monitors provide routing perspectives from locations across the internet, including locations near your customers. Private BGP monitors provide routing perspectives from your own network, helping you compare external reachability with the routes that your routers observe.

## Use Cases

Use private BGP monitoring to:

* Monitor routes from locations in your network that are important to your organization.
* Investigate unexpected route announcements and withdrawals, reachability changes, and suspected routing misconfigurations.
* Identify which private BGP monitor reported a problematic route update and view BGP data from multiple sites in one place.

## How Private BGP Monitoring Works

A router in your network establishes a BGP session with a ThousandEyes route collector and sends routing updates through that session. ThousandEyes processes the updates and associates them with a private BGP monitor. You can then use the monitor's routing perspective in BGP tests and supported tests that collect BGP data.

Private BGP monitoring complements public BGP monitoring. You can use public monitors, private monitors, or both to compare routes observed inside and outside your network.

## Choosing a Collection Method

Private BGP monitoring supports two collection methods. Both create private BGP monitors under **Routing > Private BGP Monitors**.

| Collection Detail            | ThousandEyes-Hosted Route Collector                                                              | Enterprise Agent                                                                                          |
| ---------------------------- | ------------------------------------------------------------------------------------------------ | --------------------------------------------------------------------------------------------------------- |
| BGP session                  | Your router peers directly with a ThousandEyes-hosted route collector.                           | Your router peers locally with the **BGP Route Collector** module on an Enterprise Agent in your network. |
| Router peer address          | A public IPv4 or IPv6 address. RFC 1918 private addresses are not supported for this connection. | An address reachable by the Enterprise Agent, which can be private.                                       |
| Routing visibility           | Your router's perspective on routes to internet destinations.                                    | Local routing visibility, including routes with private AS numbers, private prefixes, or both.            |
| Sending data to ThousandEyes | Your router sends routing updates directly to the hosted collector over eBGP.                    | The Enterprise Agent sends collected routing telemetry over its existing authenticated HTTPS connection.  |
| Enterprise Agent required    | No.                                                                                              | Yes, with the **BGP Route Collector** module enabled.                                                     |

The Enterprise Agent method adds local collection to the existing private BGP monitoring workflow. Both methods remain available. For either method, the router's BGP export policy determines which routes it advertises to the collector.

Use the procedure below for a ThousandEyes-hosted route collector. For local collection, see [Configuring Private BGP Monitoring with Enterprise Agents](/product-documentation/tests/bgp-tests/private-bgp-monitoring/configuring-an-enterprise-agent-with-bgp-route-collector.md).

## Configuring a Private BGP Monitor

This procedure configures direct eBGP peering between your router and a ThousandEyes-hosted route collector. It does not use an Enterprise Agent. ThousandEyes uses the routing updates to show reachability and routing changes from your router's perspective.

### Before You Begin

Before you configure the monitor:

* Confirm that your role has the *Edit BGP monitors* permission.
* Identify the public IPv4 or IPv6 address of the router that will peer with ThousandEyes. The address must not be an RFC 1918 private address.
* Identify the router's AS number.
* Have qualified network personnel review and apply the router configuration.

### Creating the Private BGP Monitor

1. In ThousandEyes, go to [**Routing > Private BGP Monitors**](https://app.thousandeyes.com/routing/private-bgp-monitors/), and then select **Add Private BGP Monitor**.

   The **Create Private BGP Monitor** screen appears.

   ![Create Private BGP Monitor screen with BGP peer and notification settings](https://1112912342-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F-M4QARF6s57qxMrOHDTZ%2Fuploads%2Fgit-blob-fcd91faa7c6e8f632d43ee6260bbdc1f1b75d948%2Fcreate-private-bgp-monitor.png?alt=media)
2. Complete the following fields:

   | Field                                | Description                                                                         |
   | ------------------------------------ | ----------------------------------------------------------------------------------- |
   | **Monitor Name**                     | Enter the name to display in the list of BGP monitors.                              |
   | **IP Address**                       | Enter the public IPv4 or IPv6 address assigned to your router.                      |
   | **AS Number**                        | Enter your router's AS number.                                                      |
   | **TCP MD5 Password**                 | Optional. Enter the authentication key for the BGP session.                         |
   | **Send monitor status alert emails** | Enable this option to send an email notification when the monitor's status changes. |
   | **Notification Emails**              | Select the recipients for monitor status alert emails.                              |
3. Select **Create BGP Monitor**.

   ThousandEyes creates the monitor and sends the peering instructions and router configuration commands by email. The monitor appears with a **Pending** status.
4. Configure your router as an external multihop peer by using the values in the email from ThousandEyes:

   * **Peer AS number:** **65315**
   * **BGP type:** **external**, **multihop**
   * **Neighbor address:** Use the peer address from the email.

   <div data-gb-custom-block data-tag="hint" data-style="warning" class="hint hint-warning"><p>Use only the neighbor address provided for this peering request. Do not reuse an address from another private BGP monitor configuration.</p></div>
5. Configure the peering session to reject all routes received from the ThousandEyes peer.

   After ThousandEyes approves the request and the peering session is established, the monitor displays the peer information and the duration of the established session.

### Managing the Private BGP Monitor

To delete a private BGP monitor or cancel a pending request, select the trash icon next to the monitor's **Status** field, and then confirm the action.

You can also configure an alert to notify specified recipients when the private BGP monitor is unavailable.

## Learn More

* To view AS paths from BGP monitors to a target prefix, see [Visualizing BGP Routes](https://docs.thousandeyes.com/product-documentation/tests/bgp-tests/using-the-bgp-route-visualization-view).
* To inspect route announcements, withdrawals, and other BGP update messages, see [Using the BGP Updates Table](https://docs.thousandeyes.com/product-documentation/tests/bgp-tests/using-the-bgp-updates-table).
* To resolve a connection problem with a ThousandEyes-hosted route collector, see [Troubleshooting Private BGP Monitoring Sessions](https://docs.thousandeyes.com/product-documentation/tests/bgp-tests/troubleshooting-private-bgp-monitoring-sessions).
