Patch Name: PHKL_26404 Patch Description: s700_800 11.00 Timers disabling, early SIGXCPU Creation Date: 02/05/07 Post Date: 02/05/14 Hardware Platforms - OS Releases: s700: 11.00 s800: 11.00 Products: N/A Filesets: OS-Core.CORE2-KRN,fr=B.11.00,fa=HP-UX_B.11.00_32,v=HP OS-Core.CORE2-KRN,fr=B.11.00,fa=HP-UX_B.11.00_64,v=HP Automatic Reboot?: Yes Status: General Release Critical: No (superseded patches were critical) PHKL_23956: OTHER Sluggish DCE threads performance Category Tags: defect_repair general_release critical Path Name: /hp-ux_patches/s700_800/11.X/PHKL_26404 Symptoms: PHKL_26404: ( SR:8606231866 CR:JAGae01102 ) An application may receive a SIGXCPU signal prematurely when the RLIMIT_CPU for the application is changed through the setrlimit(2) system call. PHKL_23956: ( SR:8606183485 CR:JAGad52698 ) Virtual timers are randomly disabled causing CMA thread applications to stop context switching unexpectedly, resulting in a huge performance degradation. PHKL_19179: Sometimes SIGVTALRM or SIGPROF is delivered to a process before the timers actually have expired. Defect Description: PHKL_26404: ( SR:8606231866 CR:JAGae01102 ) When a process sets its CPU limit timer using the setrlimit(2) system call, the threads in the process may have accumulated some processor time since the last time the process was updated in the clock interrupt path. This accumulated time would then be applied to the CPU limit timer the next time the process is updated in the clock interrupt path, causing the timer to expire prematurely. Resolution: Before setting the CPU limit timer for a process, extract the processor time accumulated by its threads since the last clock interrupt, and apply the time to all existing virtual and profile timers in the process. This resets the CPU usage time for the process when enabling the CPU limit timer. PHKL_23956: ( SR:8606183485 CR:JAGad52698 ) SIGVTALRM (which CMA threads use for context switching) was being disabled because the value it_value in the struct itimerval was being zeroed thus disabling the timer. Any long lived CMA threads program (including all the DCE daemons) is susceptable to having their SIGVTALRM context switching disabled. This silent failure results in a huge CMA thread performance degradation since the programs would continue to context switch at yield points but would no longer switch at reliable time quantas intended by CMA thread scheduling. This impacts threads performance. Resolution: Add an extra interval timer if it_value becomes (0,0) to ensure SIGVTALRM is not randomly disabled causing applications to stop context switching inadvertently. PHKL_19179: HP-UX handles CLOCK_VIRTUAL and CLOCK_PROFILE timers when a thread is "caught" by a clock interrupt and decrements the timers value by the time a process spent executing in user and/or system-space. When a thread is "caught" in a clock interrupt, HP-UX calculates thread's accumulated user and system time since last clock interrupt in which this this thread was "caught." This calculation is done by subtracting user and system baselines from the current user and system times. Under certain circumstances, HP-UX does not reset the baselines, and as user and system times accumulates, baselines do not get updated. And when a thread is "caught" in a clock interrupt, the interval between current user and system times and respective baselines can be arbitrarily large. And since we decerement this interval value from the armed timers, HP-UX can expire CLOCK_VIRTUAL and CLOCK_PROFILE timers prematurely. Resolution: When calling setitimer() or timer_setitime(), for all threads reset the user and system baselines. SR: 1653277970 8606183485 8606231866 Patch Files: OS-Core.CORE2-KRN,fr=B.11.00,fa=HP-UX_B.11.00_32,v=HP: /usr/conf/lib/libhp-ux.a(pm_timers.o) /usr/conf/lib/libhp-ux.a(subr_timers.o) OS-Core.CORE2-KRN,fr=B.11.00,fa=HP-UX_B.11.00_64,v=HP: /usr/conf/lib/libhp-ux.a(pm_timers.o) /usr/conf/lib/libhp-ux.a(subr_timers.o) what(1) Output: OS-Core.CORE2-KRN,fr=B.11.00,fa=HP-UX_B.11.00_32,v=HP: /usr/conf/lib/libhp-ux.a(pm_timers.o): pm_timers.c $Date: 1999/07/12 14:54:07 $Revision: r1 1ros/7 PATCH_11.00 (PHKL_19179) /usr/conf/lib/libhp-ux.a(subr_timers.o): subr_timers.c $Date: 2002/05/05 01:10:34 $Revision: r11ros/9 PATCH_11.00 (PHKL_26404) OS-Core.CORE2-KRN,fr=B.11.00,fa=HP-UX_B.11.00_64,v=HP: /usr/conf/lib/libhp-ux.a(pm_timers.o): pm_timers.c $Date: 1999/07/12 14:54:07 $Revision: r1 1ros/7 PATCH_11.00 (PHKL_19179) /usr/conf/lib/libhp-ux.a(subr_timers.o): subr_timers.c $Date: 2002/05/05 01:10:34 $Revision: r11ros/9 PATCH_11.00 (PHKL_26404) cksum(1) Output: OS-Core.CORE2-KRN,fr=B.11.00,fa=HP-UX_B.11.00_32,v=HP: 554101831 8864 /usr/conf/lib/libhp-ux.a(pm_timers.o) 2676877130 15932 /usr/conf/lib/libhp-ux.a(subr_timers.o) OS-Core.CORE2-KRN,fr=B.11.00,fa=HP-UX_B.11.00_64,v=HP: 766044479 20456 /usr/conf/lib/libhp-ux.a(pm_timers.o) 3162990134 37320 /usr/conf/lib/libhp-ux.a(subr_timers.o) Patch Conflicts: None Patch Dependencies: s700: 11.00: PHKL_18543 s800: 11.00: PHKL_18543 Hardware Dependencies: None Other Dependencies: None Supersedes: PHKL_23956 PHKL_19179 Equivalent Patches: None Patch Package Size: 110 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. ------------------------------------------------------------ 1. Back up your system before installing a patch. 2. Login as root. 3. Copy the patch to the /tmp directory. 4. Move to the /tmp directory and unshar the patch: cd /tmp sh PHKL_26404 5. Run swinstall to install the patch: swinstall -x autoreboot=true -x patch_match_target=true \ -s /tmp/PHKL_26404.depot By default swinstall will archive the original software in /var/adm/sw/save/PHKL_26404. If you do not wish to retain a copy of the original software, include the patch_save_files option in the swinstall command above: -x patch_save_files=false WARNING: If patch_save_files is false when a patch is installed, the patch cannot be deinstalled. Please be careful when using this feature. For future reference, the contents of the PHKL_26404.text file is available in the product readme: swlist -l product -a readme -d @ /tmp/PHKL_26404.depot To put this patch on a magnetic tape and install from the tape drive, use the command: dd if=/tmp/PHKL_26404.depot of=/dev/rmt/0m bs=2k Special Installation Instructions: This patch depends on base patch PHKL_18543. For successful installation please insure that PHKL_18543 is already installed, or that PHKL_18543 is included in the same depot with this patch and PHKL_18543 is selected for installation.