18-Application Hosting Command Reference

HomeSupportSwitchesS12500R SeriesReference GuidesCommand ReferencesH3C S12500R Switch Router Series Command References(R51xx)-6W10118-Application Hosting Command Reference
03-Common container and open application commands

Common container and open application commands

tpa data sync

Use tpa data sync to back up Guest shell container data and Docker container data.

Syntax

tpa data sync

Views

System view

Predefined user roles

network-admin

Usage guidelines

This command backs up data of Guest shell containers and user created Docker containers to the standby MPU so the containers can continue to use the data after an active/standby switchover.

Examples

# Back up Guest shell container data and Docker container data.

<Sysname> system-view

[Sysname] tpa data sync

…Synchronization succeeded.

tpa ip send-to-cpu

Use tpa ip send-to-cpu to configure the device to precondition certain incoming IPv4 packets of open applications and send the packets to its CPUs.

Use undo tpa ip send-to-cpu to restore the default.

Syntax

tpa ip send-to-cpu protocol protocol-number [ destination-port destination-port-number | source-port source-port-number ] * [ destination-ip destination-ip-address ]

undo tpa ip send-to-cpu protocol protocol-number [ destination-port destination-port-number | source-port source-port-number ] * [ destination-ip destination-ip-address ]

Default

In system view:

The device processes incoming open application IPv4 packets as follows:

·     Unicast packets that are destined for the device itself—Sends the packets to CPUs.

·     Broadcast packets—Sends the packets to CPUs.

·     Multicast packets—Does not send the packets to CPUs.

Interface view:

The configuration in system view is used.

Views

System view

Interface view

Predefined user roles

network-admin

Parameters

protocol protocol-number: Specifies a protocol number in the range of 1 to 255.

destination-port destination-port-number: Specifies a destination port number in the range of 1 to 65535. If you do not specify this option, the packet matching rule does not identify packets by destination port number. This option is supported only if the specified protocol is TCP or UDP.

source-port source-port-number: Specifies a source port number in the range of 1 to 65535. If you do not specify this option, the packet matching rule does not identify packets by source port number. This option is supported only if the specified protocol is TCP or UDP.

destination-ip destination-ip-address: Specifies a destination IP address, which can be 255.255.255.255 or in the range of 224.0.0.0 to 239.255.255.255. If you do not specify this option, the device does not send multicast packets of open applications to CPUs. This option is supported only if the specified protocol is not TCP.

Usage guidelines

You can configure the device to precondition incoming open application packets that match certain rules and then send the packets to its CPUs. Preconditioning actions include rate limiting packets to prevent open application packets from using too many CPU resources.

You can execute this command multiple times to configure multiple packet matching rules.

If you execute this command in interface view, the configuration applies to the current interface. If you execute this command in system view, the configuration applies to all interfaces. If you execute this command in both interface view and system view, the device preconditions incoming open application packets that match the rules configured in either view.

The configured rules also apply to RPM application packets. For more information about RPM applications, see "Hosting RPM applications."

Examples

# Configure the device to precondition incoming open application IPv4 packets that use protocol number 6, destination port number 50000, and source port number 40000.

<Sysname> system-view

[Sysname] tpa ip send-to-cpu protocol 6 destination-port 50000 source-port 40000

tpa ip source

Use tpa ip source to specify a source IPv4 address for outgoing open application packets.

Use undo tpa ip source to restore the default.

Syntax

tpa ip source interface interface-type interface-number

undo tpa ip source

Default

Open applications use the primary IPv4 address of interface Loopback 0 as the source IPv4 address for outgoing packets.

Views

System view

Predefined user roles

network-admin

Parameters

interface interface-type interface-number: Specifies an interface by its type and number. The primary IPv4 address of the interface will be used as the source IPv4 address for outgoing open application packets.

Usage guidelines

For the following applications to communicate with indirectly connected networks, you must specify a source IP address for their outgoing packets:

·     RPM applications.

·     Guest Shell container applications.

·     Open applications in containers that share the network namespace of Comware.

The applications will use the IPv4 address as the source IPv4 address for packets that they send.

As a best practice, specify a loopback interface as the source interface. The physical layer status of a loopback interface is always up unless the loopback interface is manually shut down.

Make sure the specified interface has an IPv4 address and is in up state. Make sure a connection is available between the interface and the destination device.

If you execute this command multiple times, the most recent configuration takes effect.

Examples

# Use the primary IPv4 address of interface HundredGigE 1/0/1 as the source IPv4 address for outgoing open application packets.  

<Sysname> system-view

[Sysname] tpa ip source interface hundredgige 1/0/1

# Use the primary IPv4 address of VLAN-interface 2 as the source IPv4 address for outgoing open application packets.  

<Sysname> system-view

[Sysname] tpa ip source interface vlan-interface 2

tpa ipv6 send-to-cpu

Use tpa ipv6 send-to-cpu to configure the device to precondition certain incoming IPv6 packets of open applications and send the packets to its CPUs.

Use undo tpa ipv6 send-to-cpu to restore the default.

Syntax

tpa ipv6 send-to-cpu protocol protocol-number [ destination-port destination-port-number | source-port source-port-number ] * [ destination-ipv6 destination-ipv6-address ]

undo tpa ipv6 send-to-cpu protocol protocol-number [ destination-port destination-port-number | source-port source-port-number ] * [ destination-ipv6 destination-ipv6-address ]

Default

In system view:

The device processes incoming open application IPv6 packets as follows:

·     Unicast packets that are destined for the device itself—Sends the packets to CPUs.

·     Multicast packets—Does not send the packets to CPUs.

Interface view:

The configuration in system view is used.

Views

System view

Interface view

Predefined user roles

network-admin

Parameters

protocol protocol-number: Specifies a protocol number in the range of 1 to 255.

destination-port destination-port-number: Specifies a destination port number in the range of 1 to 65535. If you do not specify this option, the packet matching rule does not identify packets by destination port number. This option is supported only if the specified protocol is TCP or UDP.

source-port source-port-number: Specifies a source port number in the range of 1 to 65535. If you do not specify this option, the packet matching rule does not identify packets by source port number. This option is supported only if the specified protocol is TCP or UDP.

destination-ipv6 destination-ipv6-address: Specifies a destination IPv6 address, which can be a valid multicast IPv6 address. If you do not specify this option, the device does not send multicast IPv6 packets of open applications to CPUs. This option is supported only if the specified protocol is not TCP.

Usage guidelines

You can configure the device to precondition incoming open application packets that match certain rules and then send the packets to its CPUs. Preconditioning actions include rate limiting packets to prevent open application packets from using too many CPU resources.

You can execute this command multiple times to configure multiple packet matching rules.

If you execute this command in interface view, the configuration applies to the current interface. If you execute this command in system view, the configuration applies to all interfaces. If you execute this command in both interface view and system view, the device preconditions open application packets that match the rules configured in either view.

The configured rules also apply to RPM application packets. For more information about RPM applications, see "Hosting RPM applications."

Examples

# Configure the device to precondition incoming open application IPv6 packets that use protocol number 6, destination port number 50000, and source port number 40000.

<Sysname> system-view

[Sysname] tpa ipv6 send-to-cpu protocol 6 destination-port 50000 source-port 40000

tpa ipv6 source

Use tpa ipv6 source to specify a source IPv6 address for outgoing open application packets.

Use undo tpa ipv6 source to restore the default.

Syntax

tpa ipv6 source { interface interface-type interface-number | ipv6 ipv6-address }

undo tpa ipv6 source

Default

Open applications use an IPv6 address of interface Loopback 0 is used as the source IPv6 address for outgoing packets.

Views

System view

Predefined user roles

network-admin

Parameters

interface interface-type interface-number: Specifies an interface by its type and number.

ipv6 ipv6-address: Specifies an IPv6 address, which must be an IPv6 global unicast address.

Usage guidelines

For the following applications to communicate with indirectly connected networks, you must specify a source IPv6 address for their outgoing packets:

·     RPM applications.

·     Guest Shell container applications.

·     Open applications in containers that share the network namespace of Comware.

The applications will use the IPv6 address as the source IPv6 address for packets that they send.

If you specify a source interface, the first effective IPv6 global unicast address in the output from the display ipv6 interface command is used as the source IPv6 address. Follow these guidelines:

·     Make sure the interface is in up state and a connection is available between the interface and the destination device.

As a best practice, specify a loopback interface as the source interface. The physical layer status of a loopback interface is always up unless the loopback interface is manually shut down.

·     Make sure the interface has an IPv6 global unicast address. If the interface does not have an IPv6 global unicast address, the configuration does not take effect.

·     As a best practice, make sure the interface has only one IPv6 global unicast address. If the interface has multiple IPv6 global unicast addresses, a source IPv6 address change might occur.

If you use the tpa ipv6 source ipv6 command to specify a source IPv6 address, make sure the IPv6 address belongs to an interface on the device. If the IPv6 address does not belong to an interface on the device, the configuration does not take effect.

If you execute this command multiple times, the most recent configuration takes effect.

Examples

# Use an IPv6 address of interface HundredGigE 1/0/1 as the source IPv6 address for outgoing open application packets.  

<Sysname> system-view

[Sysname] tpa ipv6 source interface hundredgige 1/0/1

# Use an IPv6 address of VLAN-interface 2 as the source IPv6 address for outgoing open application packets.  

<Sysname> system-view

[Sysname] tpa ipv6 source interface vlan-interface 2

# Use 2001: : 1 as the source IPv6 address for outgoing open application packets.

<Sysname> system-view

[Sysname] tpa ipv6 source ipv6 2001::1

tpa socket client-port-range

Use tpa socket client-port-range to specify the range of port numbers to be reserved for open client applications.

Use undo tpa socket client-port-range to restore the default.

Syntax

tpa socket client-port-range start-port end-port

undo tpa socket client-port-range

Default

No port numbers are reserved for open client applications.

Views

System view

Predefined user roles

network-admin

Parameters

start-port: Specifies the start port number, in the range of 32768 to 65535.

end-port: Specifies the end port number, in the range of 32768 to 65535. The end port number must be equal to or greater than the start port number.

Usage guidelines

The device forwards received packets to applications based on the destination port numbers in the packets. To avoid port conflicts and to correctly forward packets destined for open client applications, reserve port numbers for the open client applications.

The reserved port numbers cannot include the port numbers being used by Comware client applications. Before executing this command, execute the following commands to identify the TCP and UDP port numbers that Comware applications are using:

·     display system internal tcp port-info

·     display system internal udp port-info

To change the reserved port number range while one or more open client applications are running:

1.     Identify whether the new range includes the port numbers that the open client applications are using.

2.     If not, stop the open client applications that are using an out-of-range port number. You can restart the applications after you change the reserved port number range.

If you execute this command multiple times, the most recent configuration takes effect.

Examples

# Reserve port numbers 32768 through 60999 for open client applications.

<Sysname> system-view

[Sysname] tpa socket client-port-range 32768 60999

tpa socket server-port

Use tpa socket server-port-range to specify the port numbers to be reserved for open server applications.

Use undo tpa socket server-port to delete port numbers reserved for open server applications.

Syntax

tpa socket server-port port-id1 [ to port-id2 ]

undo tpa socket server-port [ port-id1 [ to port-id2 ] ]

Default

No port numbers are reserved for open server applications.

Views

System view

Predefined user roles

network-admin

Parameters

port-id1: Specifies a port number in the range of 1024 to 65535.

port-id1 to port-id2: Specifies a range of port numbers. The port-id1 and port-id2 arguments represent the start port number and end port number, respectively. Both port numbers are in the range of 1024 to 65535. The end port number must be equal to or greater than the start port number.

Usage guidelines

The device forwards received packets to applications based on the destination port numbers in the packets. To avoid port conflicts and to correctly forward packets destined for open server applications, reserve port numbers for the open server applications.

The reserved port numbers cannot include the port numbers being used by Comware client applications. Before executing this command, execute the following commands to identify the TCP and UDP port numbers that Comware applications are using:

·     display system internal tcp port-info

·     display system internal udp port-info

If you execute this command multiple times, all of the specified port numbers are reserved for open server applications.

If you do not specify an option for the undo tpa socket server-port command, the command deletes all port numbers reserved for open server applications.

Examples

# Reserve port number 10000 for open server applications.

<Sysname> system-view

[Sysname] tpa socket server-port 10000

# Reserve port numbers 10000 through 10010 for open server applications.

<Sysname> system-view

[Sysname] tpa socket server-port 10001 to 10010

  • Cloud & AI
  • InterConnect
  • Intelligent Computing
  • Security
  • SMB Products
  • Intelligent Terminal Products
  • Product Support Services
  • Technical Service Solutions
All Services
  • Resource Center
  • Policy
  • Online Help
All Support
  • Become a Partner
  • Partner Resources
  • Partner Business Management
All Partners
  • Profile
  • News & Events
  • Online Exhibition Center
  • Contact Us
All About Us
新华三官网