network

Syntax

network {[<IPV4/MASK> | <IPV6/MASK>]} [route-map <ROUTE-MAP-NAME>]

no network {[<IPV4/MASK> | <IPV6/MASK>]} [route-map <ROUTE-MAP-NAME>]

Description

This command specifies the networks to be advertised by the Border Gateway Protocol (BGP) routing processes.

The no form of this command removes an entry from the routing table.

Command context

config-bgp-ipv4-uc

Parameters

<IPV4/MASK>

Specifies the IPv4 network with mask. For example: 1.1.1.1/24

<IPV6/MASK>

Specifies the IPv6 network with mask. For example: 2001:0db8:85a3::8a2e:0370:7334/24

route-map <ROUTE-MAP-NAME>

Optional parameter. Specifies a route map to apply to the prefixes advertised by this specific network statement.

Authority

Administrators

Usage

  • This command is used to advertise prefixes currently installed in the routing table into the BGP table.

  • Use the route-map keyword to apply the specified route map to network advertisements. The mask length as configured in the network statement must match the mask length of prefixes in the routing table.

Examples

switch(config-bgp-ipv4-uc)# network 11.11.11.0/24
switch(config-bgp-ipv4-uc)# no network 11.11.11.0/24
switch(config-bgp-ipv6-uc)# network 2001:0db8:85a3::8a2e:0370:7334/24
switch(config-bgp-ipv6-uc)# no network 2001:0db8:85a3::8a2e:0370:7334/24