Cisco Support Community
Showing results for 
Search instead for 
Did you mean: 

BGP Confusion

Hi Guys,

I m little bit confused about the network command used in bgp,as the theory says that it is different from which is used in IGP's.

Please explain.



Community Member

Re: BGP Confusion

In IGPs the network command enables the protocol on certain interfaces.But in case of BGP it advertises the network to its peers.So the network needs to be available in your routing table.

For exterior protocols, a reference to an IP network from the network router configuration command controls only which networks are advertised. This behavior is in contrast to IGP, such as IGRP, which also use the network command to determine where to send updates.



Note The network command is used to inject IGP routes into the BGP table. The network-mask portion of the command allows supernetting and subnetting. The resources of the router, such as configured NVRAM or RAM, determine the upper limit of the number of network commands you can use. Alternatively, you could use the redistribute router configuration command to achieve the same result.

Pls chk this link.

Re: BGP Confusion

Hi Mahmood,

Totally agree with Arivudainambi, think of BGP as an application, and the network commands tells it to advertise what networks (these network must have exact IGP routes in the routing table to do the real routing), on the other hand the network command with IGP, just tells the router to run the routing protocol on this interface and advertise this interface in the routing updates (using the subnetmask of the interface itself - except with OSPF and loopback interfaces which are advertised as host routes /32 by default).


Mohammed Mahmoud.

Hall of Fame Super Blue

Re: BGP Confusion

Hi Mahmood

In addition to the other post an example might help.

router eigrp 1


router bgp 1

network mask

The network statement under EIGRP tells the router to start the EIGRP routing protocol on any interfaces that have an IP address that falls within the subnet range.

Any interface in that range will start EIGRP and form adjancencies with any other EIGRP speaking routers with interfaces in that subnet.

The BGP statement network statement tells te router to advertise the network to any configured BGP peers. So the network statements under BGP really are telling the router which networks to advertise out.



Community Member

Re: BGP Confusion

Its a good explanation but to be a little more specific.

The network command in an IGP such as OSPF or EIGRP, enables routing advertisements out of interfaces within the network range specified in the network command and so broadcasts find neighbors and exchange routing (if various paramters exist and the feeling is mutual).

With BGP the network command and specific mask matches an already existing route in your IGP or static route and places it into the BGP routing table. Specific mask is important as it only matches the one mask.

There are many ways to do this but the network command is pretty specific and originates the route from the router where the network command placed the route into BGP. This is generally preferred over redistribution and filtering where possible.

CreatePlease to create content