No, not quite. There’s a need to add ‘eos’ if you want the label entry to match 
against that label AND against the set EOS bit. An MPLS lookup is really a 21 
bit match; 20 bits of label value and 1 bit EOS.
It only makes sense to send EOS traffic to IP lookup. Sending non-EOS traffic 
to a IP lookup would not result in something good.

If label 222 has been dedicated to 10.100.2.0/24 (i.e. when we the receiver 
gets traffic with label 222, it must be for 10.100.2.0/24) then the command you 
are looking for is;
   mpls local-label 222 10.100.2.0/24
this does what the API refers to as a ‘bind’. It says, whatever IP does for 
10.100.2.0/24, MPLS should do for label 222. It will add the eos and non-eos 
entries appropriately.

/neale


From: Michael Borokhovich <michael...@gmail.com>
Date: Monday, 14 August 2017 at 18:20
To: "Neale Ranns (nranns)" <nra...@cisco.com>
Cc: "vpp-dev@lists.fd.io" <vpp-dev@lists.fd.io>
Subject: Re: [vpp-dev] MPLS labels question

I see.. so there is a need to add the "add eos" to the "mpls local-label" 
command if I want to send the packet to the IP lookup after popping a single 
(the only) label.

Thanks, Neale!

On Mon, Aug 14, 2017 at 1:01 PM, Neale Ranns (nranns) 
<nra...@cisco.com<mailto:nra...@cisco.com>> wrote:

Hi Michael,

‘add’ is the default.
It’s necessary to specify ‘eos’ because it I the end-of-stack entry you are 
adding and the default (i.e. without ‘eos’) is to add the non-end-of-stack 
entry.

Regards,
neale

From: <vpp-dev-boun...@lists.fd.io<mailto:vpp-dev-boun...@lists.fd.io>> on 
behalf of Michael Borokhovich 
<michael...@gmail.com<mailto:michael...@gmail.com>>
Date: Monday, 14 August 2017 at 16:58
To: "vpp-dev@lists.fd.io<mailto:vpp-dev@lists.fd.io>" 
<vpp-dev@lists.fd.io<mailto:vpp-dev@lists.fd.io>>
Subject: [vpp-dev] MPLS labels question

Hi,

I'm adding a label using the following command:

ip route add 10.100.2.0/24<http://10.100.2.0/24> table 1 via 10.100.4.12 
GigabitEthernet0/6/0 out-label 222

And on the receiving side poping it with:

set interface mpls GigabitEthernet0/6/0 enable
mpls local-label 222 ip4-lookup-in-table 1

However, this didn't work until I added "add eos" to the last command, i.e., 
the following worked:

mpls local-label add eos 222 ip4-lookup-in-table 1

Why is it necessary to specify "add eos" at the receiving side? Or maybe my 
configuration of the sender's side is wrong?

Thanks,
Michael.

_______________________________________________
vpp-dev mailing list
vpp-dev@lists.fd.io
https://lists.fd.io/mailman/listinfo/vpp-dev

Reply via email to