According to the erspan protocol draft (https://tools.ietf.org/html/draft-foschiano-erspan-00), the Index field could be a random number and this field is platform independent.
I am working on a demo to implement the erspan-typeII source session.At first I just assign this index field with a random number(e.g. 1 or 0), but I found my source session demo could not work with the erspan dst-session(a catalyse 6503 switch). I mean the erspan packets(my demo send it out) can be delivered to the erspan dst-session but the dst-session would not forwarding those packets, the switch drop those packets.
So I use another catalyse 6503 switch to capture the official erspan-typeII source session packets then I found the index field must got some secrets.
I mimic the official source session packets to construct my owned and it works!
For example:
I set the value of index field equals to 0x80015
a) The dst-session would forward packets if the vlanId field of the erspan header is 21 or 22
b) The dst-session would NOT forward packets if the vlanId field of the erspan header is 201 or 100
That confuse me. Is there anyone can tell me what the index field should be?
Thanks
Sherlock