opcode end-as

Function

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.

Format

opcode func-opcode1 end-as

undo opcode func-opcode1 end-as

Parameters

Parameter Description Value
func-opcode1

Specifies a static SRv6 SID operation code.

The value is a 32-digit hexadecimal number, in the format of X:X:X:X:X:X:X:X.

Views

Segment routing IPv6 locator view

Default Level

2: Configuration level

Task Name and Operations

Task Name Operations
segr write

Usage Guidelines

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.

Example

# Configure the Opcode of the End.AS SID to be ::10.
<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]
Copyright © Huawei Technologies Co., Ltd.
Copyright © Huawei Technologies Co., Ltd.
< Previous topic Next topic >