Subject: Packet transfer in MPLS

From: "Mahesh V. Kelkar" <[email-masked]>
Date: Mon, 25 Oct 1999 11:17:56 -0400 (EDT)

Hi! 
I have few basic questions about working of LDP protocol and packet
transfer. What I have understod, is as follows. Please correct me.

Consider a linear network topology.

  _____       _____       _____       _____     
 |     |     |     |     |     |     |     |
 |     |  X  |     |     |     |     |     | Towards E
 |  A  |-->--|  B  |-->--|  C  |-->--|  D  |---->>
 |     |-->--|     |-->--|     |-->--|     |---->>
 |_____|  Y  |_____|     |_____|     |_____|  
    |
    ^ Data Comming into Edge router of
    | MPLS domain

Note: 	A, B, C , D are routers connected in a linear topology.
	X is a Data Transfer stream
	Y is a TCP stream maintained by LDP sessions.

Case I: 
-A is a edge router
-B, C, D are LSRs
-Assume that D is a destination

- A receives packets with destinstion address as D
- Using link Y , A will ask B to bind label for FEC F (ex. It is 16 bit
address match)
- In turn B will forward this request to C & C will send it to D
- Instead forwarding this request, D needs to know that this packet it
destined to him.

[ Ques 1: If packets are destined to LSRs, how will they know it? ]

- Somehow D will decipher that , it's his packet. He will allocate label
to link and adds 

entry in his table as 

   For FEC F @ LSR D : 
	Incoming	Outgoing	Interface
	Label  		Label 
	10		0		0
"Outgoing label & interface = 0" will suggests that - D will absorb the
packet

- hence for Data link C->-D, for FEC F, label 10 is attached.
- C will get notification from D saying that I'm Done allocating
- C will Create a new entry in it's table as

   For FEC F @ LSR C :
	Incoming	Outgoing	Interface
	Label  		Label 
	5		10		1

- Again C will tell (on TCP link) B that label 5 is allocated for B->-C
data link
- B will create entry in it's table as

   For FEC F @ LSR B :
	Incoming	Outgoing	Interface
	Label  		Label 
	4		5		1

- B will tell A (on TCP link) that label 4 is bound to FEC F for path
A->-B
- While all these LSRs are involved in creating entries in their tables
and allocating 

labels to path, A will accumalate all incoming packets into buffer.
- Now A, the LSR edge router, will send data on Data link to B.
- B will swap the label and send it to C
- C will follow B
- When it reaches D, by looking at the table entry setted in this fashion,
it will 

understand that "I am destination". 
- D will strip the labels & 
    move the packets to the network layer & 
    forward packets to subnets.

[Ques 2: should D work as edge LSR? or should it forward it to LSR]

That's all for now. Awaiting your replies....
Thanks

Mahesh