PowerFlex How to tune the ephemeral port range on Linux

Summary: When a process or kernel module initiates communication over the network, a local port is allocated from the ephemeral port range as part of the socket.

This article applies to This article does not apply to This article is not tied to any specific product. Not all product versions are identified in this article.

Instructions

By default, the ephemeral port range is between 32768 and 60999.

Sometimes, it may be desirable to configure this range or reserve certain ports in this range. Third-party software may use a port in the ephemeral range, which could conflict with ScaleIO's SDC driver.

This can be achieved by:

  • Setting the ephemeral port range, from which the programs can allocate a local port
    And
  • Reserve ports from the ephemeral port range, so that they cannot be used as local port

 

Step-by-step guide

  1. To check the current ephemeral port range:

    # cat /proc/sys/net/ipv4/ip_local_port_range
    32768	60999
  2. To check the current reserved ports in the range (an empty line means that there is no reserved port):

    # cat /proc/sys/net/ipv4/ip_local_reserved_ports
     
  3. To adjust the ephemeral port range dynamically (not persistent):

    # echo 40000 60000 > /proc/sys/net/ipv4/ip_local_port_range
    # cat /proc/sys/net/ipv4/ip_local_port_range
    40000	60000
  4. To adjust the reserved ports dynamically (not persistent):

    # echo "50000,50003" > /proc/sys/net/ipv4/ip_local_reserved_ports
    # cat /proc/sys/net/ipv4/ip_local_reserved_ports
    50000,50003
  5. To change the parameters persistently across reboots, edit /etc/sysctl.conf and then use "sysctl -w" to take effect.
    The parameters and format of the values can be found using "sysctl -a | grep ip_local", for example:

    # sysctl -a|grep ip_local
    net.ipv4.ip_local_port_range = 40000	60000
    net.ipv4.ip_local_reserved_ports = 50000,50003
    sysctl: reading key "net.ipv6.conf.all.stable_secret"
    sysctl: reading key "net.ipv6.conf.default.stable_secret"
    sysctl: reading key "net.ipv6.conf.eth0.stable_secret"
    sysctl: reading key "net.ipv6.conf.lo.stable_secret"

Additional Information

Affected Products

ScaleIO, PowerFlex Software, VxFlex Ready Node
Article Properties
Article Number: 000154992
Article Type: How To
Last Modified: 06 Aug 2025
Version:  8
Find answers to your questions from other Dell users
Support Services
Check if your device is covered by Support Services.