[quagga-dev 6960] Re: bgpd Patches for Additional 'show' Commands

paul at jakma.org paul at jakma.org
Wed Jul 29 13:12:08 BST 2009


On Wed, 28 Jan 2009, Michael Lambert wrote:

> Attached are a pair of patch files: one for bgpd/bgp_vty.c, the other for 
> bgpd/bgp_route.c.  They serve to add a number of 'show' commands to 1) better 
> support multiple instances (we use them on route servers) and 2) try to 
> improve IPv4-vs-IPv6 and unicast-vs-multicast symmetry in the commands (no 
> more 'show ip bgp' vs 'show ip mbgp').

> The added commands are (TeXinfo to be updated at some point in the future):
>
> show bgp views ! list all defined instances--submitted previously but it 
> didn't make it to the git repository

It's there now.

> show bgp ipv4 (unicast|multicast) [A.B.C.D|A.B.C.D/M]
>
> show bgp ipv6 (unicast|multicast) [X:X::X:X|X:X::X:X/M]
>
> show bgp [view WORD] (ipv4|ipv6) (unicast|multicast) rsclient 
> (A.B.C.D|X:X::X:X)
>
> show bgp [view WORD] ipv4 (unicast|multicast) rsclient (A.B.C.D|X:X::X:X) 
> A.B.C.
> D
>
> show bgp [view WORD] ipv4 (unicast|multicast) rsclient (A.B.C.D|X:X::X:X) 
> A.B.C.D/M
>
> show bgp [view WORD] ipv6 (unicast|multicast) rsclient (A.B.C.D|X:X::X:X) 
> X:X::X
> :X
>
> show bgp [view WORD] ipv6 (unicast|multicast) rsclient (A.B.C.D|X:X::X:X) 
> X:X::X
> :X/M
>
> show bgp [view WORD] (ipv4|ipv6) (unicast|multicast) [rsclient] summary
>
> The customary '() = pick one' and '[] = optional' definitions apply.

Most of these still have to be applied, it seems. You still want them 
applied, right?

Also, it really seems like we should

 	a) rationalise these commands

 	b) implement some kind of redirection in the vectors used to index
 	   commands.

B would take some thought and work, so best left for another day - we 
still have brute-force ALIASing of each command.

For A, it seems like we could rationalise things down to the 
following common prefixes for nearly all BGP commands:

 	show (ip|ipv6)? (bgp|mbgp) (view WORD)?

 	show bgp (view WORD)? (ipv4|ipv6|vpnv4)? (unicast|multicast)?

We don't support ? matches, so either that ability'd have to be added 
to the command layer, or the prefixes expanded out for each 
possibility to eliminate them..

If anyone feels like looking into that..

regards,
-- 
Paul Jakma	paul at jakma.org	Key ID: 64A2FF6A
Fortune:
An optimist believes we live in the best world possible;
a pessimist fears this is true.



More information about the Quagga-dev mailing list