No relevant resource is found in the selected language.

This site uses cookies. By continuing to browse the site you are agreeing to our use of cookies. Read our privacy policy>Search


To have a better experience, please upgrade your IE browser.


OceanStor 2200 V3 and 2600 V3 Storage System V300R005 Command Reference 06

"Based on the CLI provided by the DeviceManager, this document describes how to use variouscommands classified by functions and how to set the CLI and manage the storage system throughthese commands."
Rate and give feedback:
Huawei uses machine translation combined with human proofreading to translate this document to different languages in order to help you better understand the content of this document. Note: Even the most advanced machine translation cannot match the quality of professional translators. Huawei shall not bear any responsibility for translation accuracy and it is recommended that you refer to the English document (a link for which has been provided).
add port ipv4_route

add port ipv4_route


The add port ipv4_route command is used to add an IPv4 route for a specific Ethernet port. If the IPv4 address of the storage system and that of an application server reside on different network segments, you can run this command to add a route to connect the storage system to application server.


add port ipv4_route eth_port_id=? type=? [ target_ip=? ] [ mask=? ] gateway=?





eth_port_id=? ID of a port.

To obtain the value, run "show port general". The value contains 1 to 31 characters, including letters, digits, and periods (.).

type=? Route type.

The value can be "net", "host", or "default", where:

  • "net": indicates a route to the target network segment.
  • "host": indicates a route to the target application server.
  • "default": indicates a default route. If there is no route to the target network segment or the target application server, the target application server accesses the storage system through the default route.
target_ip=? Address of the IPv4 network segment where an application server resides. This parameter is valid only when type=? is set to "net" and "host".

Example: The value must be an IPv4 address.

mask=? IPv4 subnet mask of a host. This parameter is valid only when type=? is set to "net".

The value must be an IPv4 subnet mask.

gateway=? IPv4 gateway address of an iSCSI host port.

The value must be an IPv4 gateway address.



Usage Guidelines

  • Before running add port ipv4_route, ensure that an IP address has been assigned to the Ethernet port. To query the IP addresses of host ports, run show port general.
  • To add a route to the target network segment, run add port ipv4_route eth_port_id=? net target_ip=? mask=? gateway=?.
  • To add a route to the target application server, run add port ipv4_route eth_port_id=? host gateway=?.
  • To add a default route, run add port ipv4_route eth_port_id=? default gateway=?.


To add an IPv4 route for the port whose ID is "ENG0.A3.P0", where the target network segment address is "", the subnet mask is "", and the gateway address is "", run the following command. The ID and output vary depending on a specific product.

admin:/>add port ipv4_route eth_port_id=ENG0.A3.P0 type=net target_ip= mask= gateway=
DANGER: You are about to change the route of port. If the route is unavailable, this operation will disconnect the storage system from hosts.
Suggestion: Before performing this operation, ensure that the entered route is available.
Have you read danger alert message carefully?(y/n)y
Are you sure you really want to perform the operation?(y/n)
Command executed successfully.

System Response


Updated: 2019-07-22

Document ID: EDOC1000106139

Views: 319461

Downloads: 210

Average rating:
This Document Applies to these Products
Related Documents
Related Version
Previous Next