Quagga 是一个网络路由软件套件,用于提供各种不同的路由协议实施。NSX Advanced Load Balancer 使用 Quagga 对虚拟服务进行基于 BGP 的缩放。
有关 BGP 缩放的更多信息,请参见提供 BGP 支持以缩放虚拟服务。
说明
Quagga Shell 用于检查 BGP 配置和 BGP 对等体状态。
注:
在该示例中,所有命令是从托管启用了 BGP 的虚拟服务的 NSX Advanced Load Balancer SE 上的默认命名空间中执行的。要列出可用的命名空间,请使用 ip netns
命令。要切换到所需的数据路径命名空间,请使用以下命令。
admin@AVI-SE1:ip netns exec namespace name bash
可以使用 netcat localhost bgpd
命令而不是 telnet localhost bgpd
命令访问 Quagga Shell。
admin@AVI-SE1: netcat localhost bgpd Trying 127.0.0.1... Connected to localhost. Escape character is '^]'. Hello, this is Quagga (version 0.99.24.1).
如果身份验证成功,则会观察到以下输出:
Quagga-bgp>
配置和故障排除命令
可以使用 show run 命令以检查运行配置:
Quagga-bgp> en Quagga-bgp# show run Current configuration: ! password <password> log file /var/lib/avi/log/bgp/0_bgpd.log ! router bgp 65000 bgp router-id 1.2.87.205 network 10.140.99.153/32 neighbor 10.140.60.155 remote-as 3 neighbor 10.140.60.155 password <password> neighbor 10.140.60.155 advertisement-interval 5 neighbor 10.140.60.155 timers 60 180 neighbor 10.140.60.155 timers connect 10 neighbor 10.140.60.155 distribute-list 2 out neighbor 10.140.99.157 remote-as 2 neighbor 10.140.99.157 password <password> neighbor 10.140.99.157 advertisement-interval 5 neighbor 10.140.99.157 timers 60 180 neighbor 10.140.99.157 timers connect 10 neighbor 10.140.99.157 distribute-list 1 out ! access-list 1 permit 10.140.99.153 ! line vty ! end
可以使用 show bgp neighbors 命令检查 BGP 对等连接状态:
10-140-4-220# *show bgp neighbors* BGP neighbor is 10.140.60.155, remote AS 3, local AS 65000, external link BGP version 4, remote router ID 0.0.0.0 BGP state = Active* Last read 03w5d06h, hold time is 180, keepalive interval is 60 seconds Configured hold time is 180, keepalive interval is 60 seconds Message statistics: Inq depth is 0 Outq depth is 0 Sent Rcvd Opens: 0 0 Notifications: 0 0 Updates: 0 0 Keepalives: 0 0 Route Refresh: 0 0 Capability: 0 0 Total: 0 0 Minimum time between advertisement runs is 5 seconds For address family: IPv4 Unicast Community attribute sent to this neighbor(both) Outbound path policy configured Outgoing update network filter list is 2 0 accepted prefixes Connections established 0; dropped 0 Last reset never Next connect timer due in 3 seconds Read thread: off Write thread: off BGP neighbor is 10.140.99.157, remote AS 2, local AS 65000, external link BGP version 4, remote router ID 10.140.6.28 BGP state = Established, up for 03w6d03h* Last read 00:00:48, hold time is 180, keepalive interval is 60 seconds Configured hold time is 180, keepalive interval is 60 seconds Neighbor capabilities: 4 Byte AS: advertised and received Route refresh: advertised and received(old & new) Address family IPv4 Unicast: advertised and received Graceful Restart Capabilty: advertised and received Remote Restart timer is 120 seconds Address families by peer: none Graceful restart informations: End-of-RIB send: IPv4 Unicast End-of-RIB received: IPv4 Unicast Message statistics: Inq depth is 0 Outq depth is 0 Sent Rcvd Opens: 6 3 Notifications: 3 0 Updates: 4 1 Keepalives: 39103 39102 Route Refresh: 0 0 Capability: 0 0 Total: 39116 39106 Minimum time between advertisement runs is 5 seconds For address family: IPv4 Unicast Community attribute sent to this neighbor(both) Outbound path policy configured Outgoing update network filter list is *1 0 accepted prefixes Connections established 1; dropped 0 Last reset never Local host: 10.140.99.156, Local port: 179 Foreign host: 10.140.99.157, Foreign port: 54566 Nexthop: 10.140.99.156 Nexthop global: :: Nexthop local: :: BGP connection: non shared network Read thread: on Write thread: off