Help us improve your experience.

Let us know what you think.

Do you have time for a two-minute survey?

 
 

port (Services NAT)

Syntax

Hierarchy Level

Description

Specify the NAT pool port or range. You can configure an automatically assigned port or specify a range with minimum and maximum values.

Note:

Starting in Junos OS Release 14.2R1, the sequential option is introduced to enable you to configure sequential allocation of ports. The sequential and random-allocation options available with the port automatic statement at the [edit services nat pool nat-pool-name] hierarchy level are mutually exclusive. You can include the sequential option for sequential allocation and the random-allocation option for random delegation of ports. By default, sequential allocation of ports takes place if you include only the port automatic statement at the [edit services nat pool nat-pool- name] hierarchy level.

For releases earlier than Junos OS Release 14.2R1, configure automatic sequential port assignment by using the auto option at the [edit services nat pool nat-pool-name port automatic] hierarchy level.

If you upgrade a router running a Junos OS release earlier than Release 14.2R1 to Release 14.2 and if the router contains the port automatic statement defined without the auto option included with the configuration, the router validates the auto option present in the configuration for sequential allocation of ports.

Options

Note:

Starting with Junos OS Release 15.1R1, the preserve-port and preserve-range functionalities are supported on MX Series routers with MS-MPCs and MS-MICs.

automatic

Cause the port assignment type to be automatically performed by the router.

sequential

Allocate ports in a sequential manner. With sequential allocation, the next available address in the NAT pool is selected only when all the ports available from an address are exhausted.

minimum-value

Lower boundary for the port range.

maximum-value

Upper boundary for the port range.

preserve-parity

Allocate ports with same parity as the original port.

preserve-range

Preserve privileged port range after translation.

random-allocation

Allocate ports within a specified range randomly.

Other options are described separately.

Required Privilege Level

interface—To view this statement in the configuration.

interface-control—To add this statement to the configuration.

Release Information

port statement introduced before Junos OS Release 7.4.

random-allocation statement introduced in Junos OS Release 9.3.

secured-port-block-allocation statement introduced in Junos OS Release 11.2.

deterministic-port-block-allocation statement introduced in Junos OS Release 12.1.

sequential statement introduced in Junos OS Release 14.2R1.