Patch Name: PHKL_3075 Patch Description: s700 9.01 Fix for select() panic and memory leak This patch fixes a problem that would panic the system when select(2) was called with no open file descriptors. Instead of returning with an invalid pointer assignment, the routine now returns EBADF and avoids panicing the system. PHKL_2348: select(2) with > 64 nfds and no timeout can cause memory leak. Known to be aggravated by Yellow Pages, NCS, and SNA products. The select(2) system call takes a number of parameters, including the number of file descriptors on which to select, and a pointer to a timeout structure; if that pointer is zero, the select(2) call has an infinite timeout. If the user specifies more than 64 file descriptors and a zero timeout pointer, and the select(2) system call blocks, then any signal to the process will interrupt the system call, causing it to terminate early without freeing some kernel memory. Over time, this will cause the system to lose enough memory to degrade performance, until there is insufficient free memory for the system to run any processes. This problem does not exist on any 8.0-based release (such as 8.01, 8.05, 8.07). This memory leak has been reported under Yellow Pages (in the NFS-RUN fileset), various SNA products, and the Network Computing System (part of the NCSNCK-RUN fileset). The amount of free memory can be checked via the "vmstat" command; over time, the "free memory" column will drop to a very small number. In addition, analysis of the kernel memory may indicate calls to the function select_many(). See the SR below for more information and details on analysis. This patch causes select(2) to free its allocated memory, even if it is interrupted by a signal. Path Name: /hp-ux_patches/s700/9.X/PHKL_3075 Effective Date: 930907 Patch Files: /system/PHKL_3075/new/sys_gen.o SR/APR#: 1653062711 "what" string/timestamp: sys_gen.o: sys_gen.c $Revision: 1.40.81.4 $ $Date: 93/09/07 11:14:23 $ PATCH_9.01 (PHKL_3075) "sum" output: 598 23 sys_gen.o Dependencies: None Supersedes: PHKL_2348 Patch Package Size: 72 Kbytes Installation Instructions: Please review all instructions and the Hewlett-Packard SupportLine User Guide or your Hewlett-Packard support terms and conditions for precautions, scope of license, restrictions, and, limitation of liability and warranties, before installing this patch. Note: Please back up your system before you patch. --------------------------------------------------------------------------- After getting the patch onto your machine, unshar the patch (sh PHKL_3075). To install this patch do the following: 1) Run /etc/update (Note: you must be logged in as root to update a system). 2) Once in the update "Main Menu" move the highlighted line to "Change Source or Destination ->" and press "Return" or "Select Item". 3) Make sure the highlighted item in the "Change Source or Destination" window is "From Tape Device to Local System ...", then press "Return" or "Select Item". 4) You should now be in the "From Tape Device to Local System" window. Change the "Source: /dev/rmt/0m" to "Source: /tmp/PHKL_3075.updt" (this assumes that you are in the /tmp directory where PHKL_3075.updt has been placed). Note: You must enter the complete path name. 5) Press "Done". 6) From here on follow the standard directions for update. The customized script that update runs will move the original software to /system/PHKL_3075/orig. HP recommends keeping this software there in order to recover from any potential problems. It is also recommended that you move the PHKL_3075.text file to /system/PHKL_3075 to be retained for future reference. If you wish to put this patch on a magnetic tape and update from the tape drive, dd a copy of the patch to the tape drive. As an example the following will create a copy of the patch that update can read: dd if=PHKL_3075.updt of=/dev/rmt/0m bs=2048