在内部使用公共 AS 编号

网络工程 BGP 射频
2022-02-02 10:07:09

我们的网络和客户网络之间有 BGP,到目前为止,每个连接都使用私有 AS 编号(在我们这端,我们为每个连接使用不同的 AS 编号)

我们最近获得了一个公共 AS 编号,用于连接到提供商。现在我们有了这个公共 AS 号,我们应该在我们自己的路由器之间内部使用它(即在设备之间部署新的 BGP 会话等时) - 还是应该继续使用私有 AS 号?

根据我的收集,我们将使用一个 AS 编号(我们的公共 AS 编号)来代表我们的组织(在我们的路由器内部和外部之间)我们可以(这将是公共 AS 编号)。这是正确/最佳实践吗?

我快速浏览了 RFC 1930,其中指出:

 The classic definition of an Autonomous System is a set of routers
 under a single technical administration, using an interior gateway
 protocol and common metrics to route packets within the AS, and
 using an exterior gateway protocol to route packets to other ASes.
 Since this classic definition was developed, it has become common
 for a single AS to use several interior gateway protocols and
 sometimes several sets of metrics within an AS.  The use of the
 term Autonomous System here stresses the fact that, even when
 multiple IGPs and metrics are used, the administration of an AS
 appears to other ASes to have a single coherent interior routing
 plan and presents a consistent picture of what networks are
 reachable through it.

    To rephrase succinctly:

 An AS is a connected group of one or more IP prefixes run by one
 or more network operators which has a SINGLE and CLEARLY DEFINED
 routing policy.
2个回答

有两种常见的解决方案:

  • 在网络边缘与上游提供商一起使用您的公共 AS,并将私有 AS 保留在您的网络中,然后在两者之间建立一些对等点。通过这种方式,您可以轻松定义“内部”和“外部”网络,但如果您的网络很大,则可能容易出现复杂性和错误。

  • 在任何地方都使用您的公共 AS,但您应该同时更改所有 iBGP 会话以防止出现路由问题。您可能需要为此安排停机时间。在客户方面,您可以在这些会话中使用“local-as”或类似的东西,直到他们准备好与您一起进行更改。

ASN 并不需要始终保持相同,但路由器一次只支持一个 AS 实例。您可以与多个 ASN(不同的远程网络)对等,但一次只能在路由器上定义一个实例。就个人而言,我会使用您的公共 ASN 深思熟虑。或者,您可以切换到在内部使用其他东西,例如 EIGRP 或 OSPF(可能会在混合中添加重新分配)并将 BGP 留给您的优势。

从技术上讲,您可以在私有和公共 ASN 之间进行对等,因此您可以将它们混合在一起。我不知道是否真的有一个“最佳实践”的答案——这主要取决于管理员,如果你想维护单独的 ASN。