assign interface

Function

The assign interface command assigns interface resources to a VS.

The undo assign interface command deletes the interface resources that have been assigned to a VS.

By default, all interface resources belong to admin VS.

Format

assign interface { interface-name | interface-type interface-number }

undo assign interface { interface-name | interface-type interface-number }

Parameters

Parameter Description Value
interface interface-type interface-number

Specifies the type and number of an interface assigned to a VS.

-

Views

VS view

Default Level

2: Configuration level

Task Name and Operations

Task Name Operations
interface-mgr write

Usage Guidelines

Usage Scenario

A VS is a system with simulated software and hardware. VSs share all resources, such as IPU, except for physical and logical interfaces. That is, VSs can share the IPU resources.

Prerequisites

Interface resources to be allocated do not belong to any VS. An attempt to assign interface resources that have been assigned to a VS causes a resource allocation failure.

If the specified VS does not exist, run the virtual-system command in the admin view to create a VS.

  • If an interface to be assigned has a sub-interface, the system prompts you with a message that all the configurations on the interface will be deleted after the allocation succeeds.
  • If a sub-interface is allocated, the vlan-type dot1q command configured on this sub-interface will not be deleted.
  • Trunk interfaces and Virtual-Ethernet interfaces cannot be assigned to VSs. Trunk sub-interfaces can be assigned to VSs. However, if Admin-VS is connected to VSs on the same device, trunk sub-interfaces cannot be assigned to VSs. Otherwise, MAC address conflicts will occur and the ARP information of the opposite side will not be learned between Admin-VS and VSs, resulting in service interruption.

Follow-up Procedure

Perform configurations, such as the interface status and IP address on the newly assigned interface.

Precautions

In VS mode, this command is supported only by the admin VS.

  • The interface resources of a VS can be assigned by a PS administrator only. An interface can be allocated only to a single VS.
  • An interface that has been deleted from a VS is automatically assigned to the Admin-VS. The configurations about the original VS are deleted from this interface.
  • A sub-interface that has been deleted from a VS is automatically allocated to the Admin-VS. The vlan-type dot1q command configuration on the sub-interface will not be deleted.

Example

# Assign GE 0/1/1 to a VS named vs1.
<HUAWEI> system-view
[~HUAWEI] admin
[~HUAWEI-admin] virtual-system vs1
[*HUAWEI-admin-vs:vs1] port-mode port
[*HUAWEI-admin-vs:vs1] assign interface GigabitEthernet0/1/1
Warning: All configurations of this interface will be deleted! Continue? [Y/N]:y
Copyright © Huawei Technologies Co., Ltd.
Copyright © Huawei Technologies Co., Ltd.
< Previous topic Next topic >