• MapReduce Service

mrs
  1. Help Center
  2. MapReduce Service
  3. User Guide
  4. MRS Manager Operation Guide
  5. Alarm Reference
  6. ALM-12052 TCP Temporary Port Usage Exceeds the Threshold

ALM-12052 TCP Temporary Port Usage Exceeds the Threshold

Description

The system checks the TCP temporary port usage every 30 seconds and compares the actual usage with the threshold (the default threshold is 80%). This alarm is generated when the TCP temporary port usage exceeds the threshold for several times (5 times by default) consecutively.

To change the threshold, choose System > Threshold Configuration > Device > Host > Network Status > TCP Ephemeral Port Usage > TCP Ephemeral Port Usage.

When the hit number is 1, this alarm is cleared when the TCP temporary port usage is less than or equal to the threshold. When the hit number is greater than 1, this alarm is cleared when the TCP temporary port usage is less than or equal to 90% of the threshold.

Attribute

Alarm ID

Alarm Severity

Automatically Cleared

12052

Major

Yes

Parameters

Parameter

Description

ServiceName

Specifies the service for which the alarm is generated.

RoleName

Specifies the role for which the alarm is generated.

HostName

Specifies the host for which the alarm is generated.

Trigger Condition

Generates an alarm when the actual indicator value exceeds the specified threshold.

Impact on the System

Services on the host cannot establish external connections, and therefore they are interrupted.

Possible Causes

  • The temporary port cannot meet the current service requirements.
  • The system is abnormal.

Procedure

Expand the temporary port number range.

  1. On MRS Manager, click the alarm in the real-time alarm list. In the Alarm Details area, obtain the IP address of the host for which the alarm is generated.
  2. Use PuTTY to log in to the host for which the alarm is generated as user omm.
  3. Run the cat /proc/sys/net/ipv4/ip_local_port_range |cut -f 1 command to obtain the value of the start port and run the cat /proc/sys/net/ipv4/ip_local_port_range |cut -f 2 command to obtain the value of the end port. The total number of temporary ports is the value of the end port minus the value of the start port. If the total number of temporary ports is smaller than 28,232, the random port range of the OS is narrow. Contact the system administrator to increase the port range.
  4. Run the ss -ant 2>/dev/null | grep -v LISTEN | awk 'NR > 2 {print $4}'|cut -d ':' -f 2 | awk '$1 >"Value of the start port" {print $1}' | sort -u | wc -l command to calculate the number of used temporary ports.
  5. The formula for calculating the usage of the temporary ports is: Usage of the temporary ports = (Number of used temporary ports/Total number of temporary ports) x 100%. Check whether the temporary port usage exceeds the threshold..

  6. Wait 5 minutes and check whether the alarm is cleared.

    • If yes, no further action is required.
    • If no, go to Step 7.

Check whether the system environment is abnormal.

  1. Run the following command to import the temporary file and view the frequently used ports in the port_result.txt file:

    netstat -tnp > $BIGDATA_HOME/tmp/port_result.txt

    netstat -tnp 
    
    Active Internet connections (w/o servers)
    
    Proto Recv Send LocalAddress ForeignAddress State PID/ProgramName tcp   0   0 10-120-85-154:45433  10-120-8:25009 CLOSE_WAIT 94237/java 
    tcp   0   0 10-120-85-154:45434  10-120-8:25009 CLOSE_WAIT 94237/java 
    tcp   0   0 10-120-85-154:45435  10-120-8:25009 CLOSE_WAIT 94237/java 
    ...

  2. Run the following command to view the processes that occupy a large number of ports:

    ps -ef |grep PID

    NOTE:
    • PID is the processes ID queried in Step 7.
    • Run the following command to collect information about all processes and check the processes that occupy a large number of ports:

      ps -ef > $BIGDATA_HOME/tmp/ps_result.txt

  3. After obtaining the administrator's approval, clear the processes that occupy a large number of ports. Wait 5 minutes and check whether the alarm is cleared.

    • If yes, no further action is required.
    • If no, go to Step 11.

Collect fault information.

  1. On MRS Manager, choose System > Export Log.
  2. Contact technical support engineers for help, detail see technical support.

Related Information

N/A