Patch Name: PHCO_9630 Patch Description: s700_800 10.00 ksh(1) cumulative patch Creation Date: 96/12/19 Post Date: 96/12/24 Repost: 01/10/26 The patch documentation was modified to remove references to a here-document related defect that is not fully addressed. The defect described in Service Request 1653182162 (JAGaa53550/DSDe430660) is not fully addressed in the patch so references to this defect fix were removed from the patch documentation. Hardware Platforms - OS Releases: s700: 10.00 s800: 10.00 Products: N/A Filesets: OS-Core.UX-CORE Automatic Reboot?: No Status: General Superseded Critical: No Path Name: /hp-ux_patches/s700_800/10.X/PHCO_9630 Symptoms: PHCO_9630: 1) While using in-line command editing, characters would sometimes appear that had not been typed by the user, most commonly ^B. Also, in editing long history lines, especially near the end of the lines, garbage characters would appear and the line couldn't be edited properly. 2) ksh was leaving fd 10 [used for history file] always open. File descriptor 10 was being reserved for use by the shell, but the file descriptor was opened in a way that it would remain open across an exec(2) system call. 3) ksh returns incorrect exit-status when it executes 'exit' command on trap. For Example, When you run the following script "trap.sh" #! /usr/bin/ksh trap "_Exit" 0 1 2 3 15 _Exit(){ exit } rm FOOOOOOOO ls FOOOOOOOO $trap.sh $echo $? 0 The exit-value of the above script should be of last command executed that is 2 (exit value of ls FOOOOOOOO), rather it will return 0. PHCO_9085: 1) Trap on EXIT set outside a function is not executed. For example, trap 'echo exiting shell' EXIT f() { exit } f should output "exiting shell" but instead produces no output. 2) cd -P and pwd -P can fail when current directory path includes symbolic links where the link starts with ../ For example: cd /tmp mkdir test cd test ln -s ../../usr lnk cd lnk pwd -P will produce the error "pwd: permission denied". 3) ksh hangs when processing "cat bigfile | while read ..." The right side of the pipe can be any shell command (while, if, for, etc.) Defect Description: PHCO_9630: 1) While using in-line command editing, untyped characters would sometimes appear, most often ^B. These occurred most typically when very long command lines had been created. Also, in editing long history lines, especially near the end of the lines, garbage characters would appear and the line couldn't be edited properly. 2) File descriptor 10 was being reserved for use by the shell, but the file descriptor was opened in a way that it would remain open across an exec(2) system call. 3) ksh returns incorrect exit-status when it executes 'exit' command on trap. PHCO_9085: 1) A trap on EXIT set outside of a function is not executed if an exit is called from within a function. 2) cd -P and pwd -P generate nonexistent path names when the logical path uses symbolic links containing .. 3) ksh hangs when processing "cat bigfile | while read ..." The right side of the pipe can be any shell command (while, if, for, etc.) SR: 4701339309 1653182162 1653164350 1653174615 Patch Files: /usr/bin/ksh /usr/bin/rksh what(1) Output: /usr/bin/ksh: $Revision: 72.40.1.9 $ Version 11/16/88 PATCH_10_0: arith.o blok.o ctype.o defs.o edit.o ech o.o expand.o fault.o io.o string.o stak.o wo rd.o emacs.o vi.o hpux_rel.o args.o builtin. o cmd.o main.o msg.o print.o xec.o name.o ma cro.o error.o service.o test.o jobs.o histor y.o 96/12/19 /usr/bin/rksh: $Revision: 72.40.1.9 $ Version 11/16/88 PATCH_10_0: arith.o blok.o ctype.o defs.o edit.o ech o.o expand.o fault.o io.o string.o stak.o wo rd.o emacs.o vi.o hpux_rel.o args.o builtin. o cmd.o main.o msg.o print.o xec.o name.o ma cro.o error.o service.o test.o jobs.o histor y.o 96/12/19 cksum(1) Output: 1134159749 155648 /usr/bin/ksh 1134159749 155648 /usr/bin/rksh Patch Conflicts: None Patch Dependencies: None Hardware Dependencies: None Other Dependencies: None Supersedes: PHCO_9085 Equivalent Patches: PHCO_9487: s700: 9.01 9.03 9.05 9.07 s800: 9.00 9.04 PHCO_9485: s700: 10.01 s800: 10.01 PHCO_9486: s700: 10.10 s800: 10.10 PHCO_9484: s700: 10.20 s800: 10.20 Patch Package Size: 210 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 PHCO_9630 5a. For a standalone system, run swinstall to install the patch: swinstall -x autoreboot=true -x match_target=true \ -s /tmp/PHCO_9630.depot 5b. For a homogeneous NFS Diskless cluster run swcluster on the server to install the patch on the server and the clients: swcluster -i -b This will invoke swcluster in the interactive mode and force all clients to be shut down. WARNING: All cluster clients must be shut down prior to the patch installation. Installing the patch while the clients are booted is unsupported and can lead to serious problems. The swcluster command will invoke an swinstall session in which you must specify: alternate root path - default is /export/shared_root/OS_700 source depot path - /tmp/PHCO_9630.depot To complete the installation, select the patch by choosing "Actions -> Match What Target Has" and then "Actions -> Install" from the Menubar. 5c. For a heterogeneous NFS Diskless cluster: - run swinstall on the server as in step 5a to install the patch on the cluster server. - run swcluster on the server as in step 5b to install the patch on the cluster clients. By default swinstall will archive the original software in /var/adm/sw/patch/PHCO_9630. If you do not wish to retain a copy of the original software, you can create an empty file named /var/adm/sw/patch/PATCH_NOSAVE. Warning: If this file exists when a patch is installed, the patch cannot be deinstalled. Please be careful when using this feature. It is recommended that you move the PHCO_9630.text file to /var/adm/sw/patch for future reference. To put this patch on a magnetic tape and install from the tape drive, use the command: dd if=/tmp/PHCO_9630.depot of=/dev/rmt/0m bs=2k Special Installation Instructions: None