Patches are available from
http://support.citrix.com/product/xa/
recommended use:
- download the patches
- paste the following script into a .cmd file in the patch directory (e.g, insthfx.cmd)
- the script defaults to Presentation Server version 4.5 on Win2003: if your Citrix version is different or on a different OS, edit the variables under the :setup label (hfxProductVersion or hfxOSVersion) accordingly
- logon to the Citrix server with administrative credentials
- ensure no other users are logged on
- run the script
@if .%ECHO%. equ .. echo off
rem //
rem // script to apply Citrix XenApp (nee Presentation Server) patches
rem // copy script into directory with .msp files
:setup
setlocal
rem // XenApp 5 uses prefix XAE
set hfxProductPrefix=PSE
set hfxProductVersion=450
rem // 64-bit patch version appends x64 to OS version
rem // e.g., W2K3X64
set hfxOSVersion=W2K3
set hfxRollupPrefix=%hfxProductPrefix%%hfxProductVersion%%hfxOSVersion%
:start
rem //
rem // change into the directory where this script is located
rem // (and where the patches are located)
pushd %~dp0
rem //
rem // disable logon
rem // it would also be nice to check for logged-on users
rem // -- maybe later
change logon /disable
rem //
rem // find latest rollup
rem // (iterate through all the rollups in name order
rem // the variable will be set to the latest one
rem // when the iteration is complete)
for %%a in (%hfxRollupPrefix%R*.msp) do set hfxRollup=%%~na
rem //
rem // extract rollup version number
rem // (last three characters of file name)
set hfxRVersion=%hfxRollup:~-3%
rem //
rem // install rollups first
call :hfx %hfxRollup%.msp
rem //
rem // install post-rollup hotfixes in order
for /f "tokens=*" %%a in ('dir /on /b %hfxProductPrefix%%hfxProductVersion%%hfxRVersion%%hfxOSVersion%*.msp') do call :hfx %%a
popd
change logon /enable
goto :cleanup
:cleanup
rem //
rem // reboot after 60 seconds
if /i .%1. neq .noreboot. start shutdown.exe -f -t 60 -r
goto :end
:hfx
set hfxpkg=%*
set hfxpkgname=%~n1
rem //
rem // find out whether the patch is listed in the registry
rem // reg.exe returns 1 if not found, 0 if found
reg query HKEY_LOCAL_MACHINE\SOFTWARE\Citrix\ProductCodes\Hotfixes\%hfxpkgname% > nul 2>&1
if %ERRORLEVEL% == 1 (
echo installing %hfxpkg%
start /wait msiexec /update %hfxpkg% /qn /norestart
choice /t:20 /d:y /c:y
)
goto :eof
:end
No comments:
Post a Comment