BGP Origin Code Attribute explained

The BGP Origin Code is one of the attributes that is used for path selection. There are three origin codes that the BGP table can show:

  • IGP (shows up as i)
  • EGP (shows up as e)
  • Incomplete (shows up as ?)

You will see IGP when you use the network command for BGP. It means you advertised the network yourself in BGP. EGP is historical and you won’t see it in the BGP table anymore. EGP is an old routing protocol we don’t use it anymore. Incomplete means you have redistributed something into BGP. Here’s a demonstration:

bgp as path prepend lab
Above you can see the topology that I will use. R1 and R3 are in AS1 and connected to R2 in AS2. Both routers have a loopback0 interface with network 1.1.1.0/24 configured on it.

R1(config)#router bgp 1
R1(config-router)#neighbor 192.168.12.2 remote-as 2
R3(config)#router bgp 1
R3(config-router)#neighbor 192.168.23.2 remote-as 2
R2(config)#router bgp 2
R2(config-router)#neighbor 192.168.12.1 remote-as 1
R2(config-router)#neighbor 192.168.23.3 remote-as 1

First we’ll configure BGP. Next step is to get network 1.1.1.0/24 in the BGP table:

R1(config)#router bgp 1
R1(config-router)#network 1.1.1.0 mask 255.255.255.0
R3(config)#router bgp 1
R3(config-router)#redistribute connected

On R1 I’ll advertise network 1.1.1.0/24 in BGP with the network command, on R3 we’ll redistribute it. Let’s see what R2 thinks of this…

We're Sorry, Full Content Access is for Members Only...

If you like to keep on reading, Become a Member Now! Here is why:

  • Learn any CCNA, CCNP and CCIE R&S Topic. Explained As Simple As Possible.
  • Try for Just $1. The Best Dollar You’ve Ever Spent on Your Cisco Career!
  • Full Access to our 740 Lessons. More Lessons Added Every Week!
  • Content created by Rene Molenaar (CCIE #41726)

556 Sign Ups in the last 30 days

satisfaction-guaranteed
100% Satisfaction Guaranteed!
You may cancel your monthly membership at any time.
No Questions Asked!

Forum Replies

  1. Hi Molenaar… Thanks a lot of this tutorial…its very helpful to who are intersted in bgp. I was facing the problem with this originate attribute when i was not read this… Now i am very happy. I never forget this concept. Once again thaks…God Bless You…

  2. Nice. I had doubt about this, now is crystal clear.

  3. Rene,

    It means Jack will reach 1.1.1.0/24 network through Jim because of this output
    *> 192.168.12.1 0 0 1 i
    However, it still learns from John but it will not install in the BGP table because of this
    * 1.1.1.0/24 192.168.23.3 0 0 1 ?
    Question is both Jim and John are advertizing 1.1.1.0/24 but why it is incomplete in Jack’s table from John’s standpoint.
    Please confirm this to me.
    Thanks
    Hamood

  4. Hi Hamood,

    It shows with the ‘?’ as incomplete because this route had been redistributed. If a route is advertised with the network command then it will show up with an ‘i’.

    Rene

25 more replies! Ask a question or join the discussion by visiting our Community Forum