Patch Name: PHCO_30365 Patch Description: s700_800 11.04 (VVOS) /etc/default/tz patch Creation Date: 04/01/23 Post Date: 04/02/09 Hardware Platforms - OS Releases: s700: 11.04 s800: 11.04 Products: N/A Filesets: OS-Core.SYS-ADMIN,fr=B.11.04,fa=HP-UX_B.11.04_32/64,v=HP Automatic Reboot?: No Status: General Release Critical: No Category Tags: defect_repair general_release Path Name: /hp-ux_patches/s700_800/11.X/PHCO_30365 Symptoms: PHCO_30365: Repackaged HP-UX patch PHCO_23652 for VVOS Based on HP-UX patch PHCO_23652: When environment variable TZ is not set, the variables tzname[2] and timezone is set to hard coded values corresponding to Eastern Standard Time. JAGab20870 Defect Description: PHCO_30365: Repackaged HP-UX patch PHCO_23652 for VVOS Based on HP-UX patch PHCO_23652: When the variable TZ is not set in the environment, in HP-UX it defaults to EST5EDT which is the east coast time in US. This poses problem in the environment of the processes that (a) are started by init(1m) (b) clear their environment (e.g. login (1), sendmail(1m) ) The hard coded value is inappropriate for any timezone other than east coast of US and the difference is difficult to track for countries like Australia which frequently update their daylight timing rules. Resolution: When the environment variable TZ is not set, tzset() checks the default file /etc/default/tz for the timezone value and sets timezone values based on that. The file /etc/default/tz contains the timezone value set by tzset() when the environment variable TZ is not set. The format for the file is same as TZ format without the prefix "TZ=". Please check environ(5) for TZ format. The order of TZ setting is as follows. 1) if the environment variable TZ is present, it takes the precedence. 2) if TZ is not present, then the value contained in /etc/default/tz is used for default. 3) if /etc/default/tz is not set, then the default value is equivalent to EST5EDT (Eastern Standard Time) of US. JAGab20870 Enhancement: No SR: 8606239637 Patch Files: OS-Core.SYS-ADMIN,fr=B.11.04,fa=HP-UX_B.11.04_32/64,v=HP: /usr/newconfig/etc/default/tz what(1) Output: OS-Core.SYS-ADMIN,fr=B.11.04,fa=HP-UX_B.11.04_32/64,v=HP: /usr/newconfig/etc/default/tz: None cksum(1) Output: OS-Core.SYS-ADMIN,fr=B.11.04,fa=HP-UX_B.11.04_32/64,v=HP: 372853650 8 /usr/newconfig/etc/default/tz Patch Conflicts: None Patch Dependencies: s700: 11.04: PHCO_30191 s800: 11.04: PHCO_30191 Hardware Dependencies: None Other Dependencies: None Supersedes: None Equivalent Patches: PHCO_23652: s700: 11.00 s800: 11.00 PHCO_24396: s700: 11.11 s800: 11.11 PHCO_25214: s700: 11.20 s800: 11.20 Patch Package Size: 30 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_30365 5. Run swinstall to install the patch: swinstall -x autoreboot=true -x patch_match_target=true \ -s /tmp/PHCO_30365.depot By default swinstall will archive the original software in /var/adm/sw/save/PHCO_30365. 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 PHCO_30365.text file is available in the product readme: swlist -l product -a readme -d @ /tmp/PHCO_30365.depot To put this patch on a magnetic tape and install from the tape drive, use the command: dd if=/tmp/PHCO_30365.depot of=/dev/rmt/0m bs=2k Special Installation Instructions: PHCO_30365: JAGab20870 The /etc/default/tz included in the patch contains the earlier default value ie., EST5EDT. So unless the user explicitly changes the value contained in the file the tzset changes are transparent to the user. The file /etc/default/tz contains the timezone value set by tzset() when the environment variable TZ is not set. The format for the file is same as TZ format without the prefix "TZ=". Please check environ(5) for TZ format. The order of TZ setting is as follows. 1) if the environment variable TZ is present, it takes the precedence. 2) if TZ is not present, then the value contained in /etc/default/tz is used for default. 3) if /etc/default/tz is not set, then the default value is equivalent to EST5EDT (Eastern Standard Time) of US.