Jump to content United States-English
HP.com Home Products and Services Support and Drivers Solutions How to Buy
» Contact HP
More options
HP.com home
HP-UX Reference > P

process_id_max(5)

Tunable Kernel Parameters
HP-UX 11i Version 3: February 2007
» 

Technical documentation

» Feedback
Content starts here

 » Table of Contents

 » Index

NAME

process_id_max — limit the maximum value for process IDs (PIDs)

VALUES

Failsafe

30000

Default

30000

Minimum

process_id_min + 512

Maximum

1,073,741,823

process_id_max must be greater than or equal to process_id_min + 512. If the difference between process_id_max and process_id_min inclusive is less than nproc, nproc is effectively limited to this difference.

DESCRIPTION

The process_id_max tunable allows the administrator to select a potential value range for process IDs (PIDs) as generated by fork (see fork(2)). It allows the administrator to select a balance between compatibility, capacity, and aesthetics.

Warning: Some programs cannot tolerate PID values up to the maximum. If such programs exist and are critical, the maximum PID should be appropriately constrained. For more details on these concerns, see Potential Application Issues, below.

Who is Expected to Change This Tunable?

Anyone.

Restrictions on Changing

Do not increase the maximum PID if there are critical applications which assume that PIDs fit into a restricted range. (See WARNINGS, below).

The value of process_id_max can be increased at any time, and it takes effect immediately. (However, its effect may not be noticed until a sufficient number of new processes have been created to cause the system to utilize the available higher values.)

A decrease in the value of process_id_max also takes effect immediately. However any existing processes with PIDs that are higher than the new value are not affected. The decrease will be in full effect for all processes only after a reboot.

When Should the Value of This Tunable Be Raised?

Increase the maximum PID if the range of PIDs defined by the process_id_min and process_id_max tunables needs to be increased to allow the creation of more simultaneous processes. See nproc(5) for limits on the number of processes.

Increase the maximum PID in systems which have many active processes (for example, >25,000). The larger range may increase the efficiency of creating of new processes (because it may take less work to find available PIDs).

If it is desired to validate that software programs execute properly in environments where PID values may be large, increase the process_id_max tunable along with the process_id_min tunable to force all new process IDs to take on large values. (See process_id_min(5) for more information.)

Do not increase the maximum PID if there are critical applications which assume that PIDs fit into a restricted range. (See WARNINGS below.)

What are the Side Effects of Raising the Value?

If the difference between process_id_max and process_id_min tunables is less than nproc, the number of processes allowed to exist simultaneously is limited to that difference.

When Should the Value of This Tunable Be Lowered?

Lower the maximum PID if critical applications make assumptions that the PID range is restricted.

What are the Side Effects of Lowering the Value?

If the difference between process_id_max and process_id_min tunables is less than nproc, the number of processes allowed to exist simultaneously is limited to that difference.

What Other Tunable Values Should Be Changed at the Same Time?

It may be desirable to change nproc. For program development and validation, a change in the process_id_min tunable may also be needed.

Potential Application Issues

The range of PID values has, in the past, been restricted to 0..30,000. Some programs have built-in assumptions about this range. This section briefly describes some of those assumptions.

Some application programs have a built-in assumption that a PID does not exceed 30,000 (which was the old value of the MAXPID (undocumented) and PID_MAX constants). They could fail if PIDs exceed this maximum.

Some application programs store PIDs in 16-bit variables (type short in C). Such programs could fail if the maximum PID exceeds 32,767.

Some programs provide output formats which can be sensitive to the number of digits in the PID. Such programs may produce aesthetically displeasing output if PIDs exceed 5 digits (exceed 99,999). In some cases automatic expansion of output fields can disturb column alignment. In some other cases, adjacent fields could run together, making the output incomprehensible.

Some programs or scripts parse the outputs of other programs which contain PID values. Some such programs have built-in assumptions that a PID will not exceed five character positions. Such a program could fail if the range exceeds 99,999.

Because session IDs (SIDs) and process group IDs (PGIDs) are the same as the process ID of the session or group leader, an increase in the maximum PID also increases the maximum SID and PGID. Though much less likely, the same application issues may exist for SIDs and PGIDs.

WARNINGS

All HP-UX kernel tunable parameters are release specific. This parameter may be removed or have its meaning changed in future releases of HP-UX.

The HP-UX kernel may silently round the selected values for process_id_max and/or process_id_min (e.g., to the nearest power of 2) in order to accommodate the PID generation algorithm.

Do not increase the maximum PID if there are critical applications which assume that PIDs fit into a restricted range. See the previous section, Potential Application Issues, for more details on such programmatic assumptions. The default maximum (30,000) has been selected to provide compatibility with all such programs. This value should be used if program sensitivity to larger PID values is unknown. See process_id_min(5) for information about how large PID values can be selected for software validation purposes.

Increasing the PID range does not increase the maximum number of processes in the system.

Installation of optional kernel software, from HP or other vendors, may cause changes to tunable parameter values. After installation, some tunable parameters may no longer be at the default or recommended values. For information about the effects of installation on tunable values, consult the documentation for the kernel software being installed. For information about optional kernel software that was factory installed on your system, see HP-UX Release Notes at http://docs.hp.com.

AUTHOR

process_id_max was developed by HP.

SEE ALSO

fork(2), nproc(5), process_id_min(5).

Number of Processes and Process ID Values on HP-UX whitepaper, available on http://docs.hp.com.

Printable version
Privacy statement Using this site means you accept its terms Feedback to webmaster
© 1983-2007 Hewlett-Packard Development Company, L.P.