Re: How to advertise ethernet IP as /32 in BGP

From: Brian McGahan <bmcgahan_at_ine.com>
Date: Thu, 31 Mar 2011 12:44:08 -0500

What are you really trying to accomplish in the design? From what I gathered you want different routers doing NAT to /32 addresses that are within the same allocation, but you don't want to assign them to the link since you'll lose addresses from the pool, correct?

If this is the case, you can NAT to the /32 without having to assign it to the LAN interface to begin with. For example if I want to translate to 1.2.3.4/32, all I need is the NAT config, then either a Loopback with 1.2.3.4/32 assigned or a route to Null0 for 1.2.3.4/32. The loopback or route puts the address in the routing table, which means you can the advertise it into BGP. For the transit link, you could assign RFC 1918, such as 10.0.0.0/24.

If this fits your requirements let me know and I can send you a reference config.

HTH,

Brian McGahan, CCIE #8593 (R&S/SP/Security)
bmcgahan_at_INE.com
 
Internetwork Expert, Inc.
http://www.INE.com

On Mar 31, 2011, at 7:44 AM, "Mathew" <mathewfer_at_gmail.com> wrote:

> Hi Adam/All,
>
> Thank you for the reply & the configuration.
> Sorry, I am bit new to PPPoE configurations.
>
> It seems we need to get the PPPoE between the 2 routers. Yes, I see it
> is working. In my setup, I am looking a way to originate this /32
> within the router itself as this is required on a CE router connecting
> to a PE. It is not very easy to make PPPoE configurations on a PE
> router.
>
> Anyway, I will further study your configuration & also will see others
> reply if any more.
>
> Regards,
>
> Mathew
>
>
> On Thu, Mar 31, 2011 at 11:19 PM, Adam Means <adam.means_at_gmail.com> wrote:
>> Matthew,
>>
>> PPPoE w/ ip unnumbered works as described so see if this answers your
>> question. You need to apply the /32 to the loopback and then apply ip
>> unnumbered loopbackX to the virtual-template interface and respective client
>> dialer interface. Running 12.4 and it'd be something along lines of:
>>
>> R1:f0/0 <---> R2:f0/0
>>
>> R1:
>> bba-group pppoe global
>> virtual-template 1
>> int lo0
>> ip add 1.1.1.1 255.255.255.255
>> interface virtual-te1
>> ip unnumbered lo0
>> interface f0/0
>> pppoe enable group global
>> router bgp 12
>> neighbor 2.2.2.2 remote 12
>> network 1.1.1.1 mask 255.255.255.255
>> network 2.2.2.2 mask 255.255.255.255
>>
>> R2:
>> interface dialer1
>> mtu 1492
>> ip unnumbered lo0
>> encap ppp
>> dialer pool 1
>> dialer persistent
>> interface f0/0
>> pppoe enable
>> pppoe-client dial-pool-number 1
>> router bgp 12
>> neighbor 1.1.1.1 remote 12
>> network 2.2.2.2 mask 255.255.255.255
>> network 1.1.1.1 mask 255.255.255.255
>>
>>
>>
>> R1(config-router)#do sh bgp ipv4 uni
>> BGP table version is 6, local router ID is 1.1.1.1
>> Status codes: s suppressed, d damped, h history, * valid, > best, i -
>> internal,
>> r RIB-failure, S Stale
>> Origin codes: i - IGP, e - EGP, ? - incomplete
>>
>> Network Next Hop Metric LocPrf Weight Path
>> * i1.1.1.1/32 2.2.2.2 0 100 0 i
>> *> 0.0.0.0 0 32768 i
>> * i2.2.2.2/32 2.2.2.2 0 100 0 i
>> *> 0.0.0.0 0 32768 i
>>
>> R1(config-router)#do sh ip route
>> Codes: C - connected, S - static, R - RIP, M - mobile, B - BGP
>> D - EIGRP, EX - EIGRP external, O - OSPF, IA - OSPF inter area
>> N1 - OSPF NSSA external type 1, N2 - OSPF NSSA external type 2
>> E1 - OSPF external type 1, E2 - OSPF external type 2
>> i - IS-IS, su - IS-IS summary, L1 - IS-IS level-1, L2 - IS-IS level-2
>> ia - IS-IS inter area, * - candidate default, U - per-user static
>> route
>> o - ODR, P - periodic downloaded static route
>>
>> Gateway of last resort is not set
>>
>> 1.0.0.0/32 is subnetted, 1 subnets
>> C 1.1.1.1 is directly connected, Loopback0
>> 2.0.0.0/32 is subnetted, 1 subnets
>> C 2.2.2.2 is directly connected, Virtual-Access1.1
>>
>>
>>
>>
>> On Thu, Mar 31, 2011 at 12:38 AM, Mathew <mathewfer_at_gmail.com> wrote:
>>>
>>> Hi Jules,
>>>
>>> Thank you again for your reply & testing it.
>>>
>>> How did you get the loopback configured with the same IP as Ethernet
>>> with /32 mask.
>>> For me, I can not get the loopback. Did you have the Ethernet also
>>> with the same address but different mask - like 24. See below.
>>> I think if I can get the loopback interface configured, we can
>>> advertise it straight in BGP. Is'n it?
>>>
>>> What am I missing here?
>>>
>>> Please check your configuration again for me, how you tested it & let
>>> us see your full config with the IOS ver tested.
>>>
>>> Thank you again for your reply.
>>>
>>> R2#sho runn int fast 0/0
>>> Building configuration...
>>>
>>> Current configuration : 530 bytes
>>> !
>>> interface FastEthernet0/0
>>> ip address 10.100.40.2 255.255.255.0
>>> end
>>>
>>> R2#conf t
>>> Enter configuration commands, one per line. End with CNTL/Z.
>>> R2(config)#int loopback 44
>>> R2(config-if)#ip address 10.100.40.2 255.255.255.255
>>> % 10.100.40.2 overlaps with FastEthernet0/0
>>> R2(config-if)#
>>>
>>> Regards,
>>>
>>> Mathew
>>>
>>> On Thu, Mar 31, 2011 at 11:47 AM, jules NYA BAWEU <nyabaweu_at_gmail.com>
>>> wrote:
>>>> Can you try getting around with the PPPOE client config?
>>>>
>>>> loo100 -- > 10.100.40.2 255.255.255.255
>>>> dialer 1 -- > unnumbered loo100
>>>> then link fa0/0 to the dialer pool
>>>>
>>>> You should then use the /32 network in statement in the BGP section.
>>>>
>>>> I just tried it and able to advertise the /32. Sorry if I missed some
>>>> details in you requirement
>>>>
>>>> On Wed, Mar 30, 2011 at 5:33 PM, Mathew <mathewfer_at_gmail.com> wrote:
>>>>>
>>>>> Hi Aaron,
>>>>>
>>>>> Thank you for the reply.
>>>>>
>>>>> No, I did not try because I am trying to find a way to get /32. Reason
>>>>> is that this project involve many routers & we are limited with IPs.
>>>>>
>>>>> Any more ideas?
>>>>>
>>>>>
>>>>> Mathew
>>>>>
>>>>>
>>>>> On Thu, Mar 31, 2011 at 10:52 AM, Aaron <aaron1_at_gvtc.com> wrote:
>>>>>> You tried a /31?
>>>>>>
>>>>>> Aaron
>>>>>>
>>>>>> On Mar 30, 2011, at 6:21 PM, Mathew <mathewfer_at_gmail.com> wrote:
>>>>>>
>>>>>>> Hi Hubert/All,
>>>>>>>
>>>>>>> I tried the sub-interface options you suggested but it did not work,
>>>>>>> see below. I tried before to enter /32 IP under main Ethernet
>>>>>>> interface & it did not take /32 IP & it seems same with a
>>>>>>> sub-interface too.
>>>>>>>
>>>>>>> Any other ideas are welcome as I have ran out of options but I
>>>>>>> believe
>>>>>>> there should be a way to do this too.
>>>>>>>
>>>>>>> R2(config)#int FastEthernet0/0.1
>>>>>>>
>>>>>>> R2(config-subif)#encapsulation dot1Q 1
>>>>>>> R2(config-subif)#ip address 2.2.2.2 255.255.255.255
>>>>>>> Bad mask /32 for address 2.2.2.2
>>>>>>> R2(config-subif)#ip address 2.2.2.2 255.255.255.252
>>>>>>> R2(config-subif)#do sho runn int FastEthernet0/0.1
>>>>>>> Building configuration...
>>>>>>>
>>>>>>> Current configuration : 101 bytes
>>>>>>> !
>>>>>>> interface FastEthernet0/0.1
>>>>>>> encapsulation dot1Q 1 native
>>>>>>> ip address 2.2.2.2 255.255.255.252
>>>>>>> end
>>>>>>>
>>>>>>> R2(config-subif)#
>>>>>>>
>>>>>>> Regards
>>>>>>>
>>>>>>> Mathew
>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>> On Thu, Mar 31, 2011 at 9:33 AM, Hubert Hinsley
>>>>>>> <hubert.hinsley_at_gmail.com> wrote:
>>>>>>>> Hello, would it be possible to achieve the solution via
>>>>>>>> subinterfaces
>>>>>>>> on the
>>>>>>>> router ethernet interface? One with a /32 address and one with a
>>>>>>>> /24?
>>>>>>>> Or,
>>>>>>>> possibly via primary and secondary ip addresses on the same
>>>>>>>> interface?
>>>>>>>> Apologies if I have misunderstood the question.Regards, Hubert.
>>>>>>>>
>>>>>>>> On 30 Mar 2011 20:53, "Mathew" <mathewfer_at_gmail.com> wrote:
>>>>>>>>
>>>>>>>> Hi Stephen,
>>>>>>>>
>>>>>>>> Thank you for the reply.
>>>>>>>> Yes, I need to be advertise in BGP. So unfortunately, PPP idea can
>>>>>>>> not
>>>>>>>> be used here.
>>>>>>>>
>>>>>>>> Mathew
>>>>>>>>
>>>>>>>> On Wed, Mar 30, 2011 at 6:32 AM, Narbik Kocharians
>>>>>>>> <narbikk_at_gmail.com>
>>>>>>>> wrote:
>>>>>>>>> Mathew,
>>>>>>>>>
>>>>>>>>> Does it...
>>>>>>>>
>>>>>>>>> Sr. Technical Instructor
>>>>>>>>> Ask about our FREE Lab Voucher with our Boot Camps
>>>>>>>>> YES! We take Cisco...
>>>>>>>>
>>>>>>>> --
>>>>>>>>
>>>>>>>> Thanks
>>>>>>>>
>>>>>>>> Mathew
>>>>>>>>
>>>>>>>>
>>>>>>>> Blogs and organic groups at http://www.ccie.net
>>>>>>>>
>>>>>>>> __________________________________...
>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>> --
>>>>>>> Thanks
>>>>>>>
>>>>>>> Mathew
>>>>>>>
>>>>>>>
>>>>>>> Blogs and organic groups at http://www.ccie.net
>>>>>>>
>>>>>>>
>>>>>>> _______________________________________________________________________
>>>>>>> Subscription information may be found at:
>>>>>>> http://www.groupstudy.com/list/CCIELab.html
>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>
>>>>>
>>>>>
>>>>>
>>>>> --
>>>>> Thanks
>>>>>
>>>>> Mathew
>>>>>
>>>>>
>>>>> Blogs and organic groups at http://www.ccie.net
>>>>>
>>>>> _______________________________________________________________________
>>>>> Subscription information may be found at:
>>>>> http://www.groupstudy.com/list/CCIELab.html
>>>>>
>>>>>
>>>>>
>>>>>
>>>>>
>>>>>
>>>>>
>>>>
>>>>
>>>
>>>
>>>
>>> --
>>> Thanks
>>>
>>> Mathew
>>>
>>>
>>> Blogs and organic groups at http://www.ccie.net
>>>
>>> _______________________________________________________________________
>>> Subscription information may be found at:
>>> http://www.groupstudy.com/list/CCIELab.html
>>>
>>>
>>>
>>>
>>>
>>>
>>>
>>
>>
>
>
>
> --
> Thanks
>
> Mathew
>
>
> Blogs and organic groups at http://www.ccie.net
>
> _______________________________________________________________________
> Subscription information may be found at:
> http://www.groupstudy.com/list/CCIELab.html

Blogs and organic groups at http://www.ccie.net
Received on Thu Mar 31 2011 - 12:44:08 ART

This archive was generated by hypermail 2.2.0 : Fri Apr 01 2011 - 06:35:42 ART