The opcode end-as command is used to configure the operation code for a static proxy SID (End.AS SID) for the SRv6 service chain.
The undo opcode end-as command is used to remove the operation code for a End.AS SID for the SRv6 service chain.
By default, no operation code is configured for a static proxy SID for the SRv6 service chain.
Usage Scenario
An SRv6 SID is a 128-bit IPv6 address expressed in the Locator:Function:Args format. The Function field is also called Opcode, and different operation codes define different functions.
Static operation codes must be configured within the static operation code segment. The length of a static operation code segment is configured through the static static-length parameter in the locator command to determine the number of static operation codes that can be configured in a specified locator range. After you run the opcode command to configure various types of operation codes, the Locator, Opcode, and Args fields form a unique SRv6 SID. The SRv6 SID is then added to the local SID table on the device. In forwarding, the Locator field in the SRv6 SID instructs other nodes to find the SRv6 SID generation node through addressing and forward SRv6 packets to the node; the Opcode field instructs the SRv6 SID generation node to implement corresponding functions.Precautions
To ensure correct forwarding, the configured static SIDs cannot conflict with each other.
<HUAWEI> system-view [~HUAWEI] segment-routing ipv6 [*HUAWEI-segment-routing-ipv6] locator test1 ipv6-prefix 2001:DB8:100:: 64 static 32 [*HUAWEI-segment-routing-ipv6-locator] opcode ::10 end-as [*HUAWEI-segment-routing-ipv6-locator-endas-::10]