Windows services stopped and restarted during upgrade of CA Client Automation agent
search cancel

Windows services stopped and restarted during upgrade of CA Client Automation agent

book

Article ID: 45420

calendar_today

Updated On:

Products

CA Client Automation - IT Client Manager CA Client Automation

Issue/Introduction

During upgrade of ITCM Agent, some important Windows services (like DHCP client, Windows Event Log etc...) are stopped and restarted.
In log generated by Upgrade following lines appear :
 
Action start 18:46:51: InstallValidate. 
… 
MSI (s) (B4:40) [18:46:53:208]: RESTART MANAGER: Will attempt to shut down and restart applications in no UI modes. 
MSI (c) (C8:38) [18:46:53:208]: RESTART MANAGER: Session opened. 
...
3/3/2016 18:46:53 Shutting down application or service 'DHCP Client'. 
3/3/2016 18:46:54 Shutting down application or service 'Task Scheduler'. 
3/3/2016 18:46:55 Shutting down application or service 'nxlog'. 
3/3/2016 18:46:55 Shutting down application or service 'Windows Event Log'. 
3/3/2016 18:46:56 Shutting down application or service 'TCP/IP NetBIOS Helper'. 
3/3/2016 18:46:59 Shutting down application or service 'CA Connection Broker'. 
...
MSI (s) (B4:40) [18:46:59:042]: RESTART MANAGER: Successfully shut down all applications in the service's session that held files in use. 
MSI (c) (C8:38) [18:46:59:042]: RESTART MANAGER: Successfully shut down all applications that held files in use. 
 
 
RESTART MANAGER has detected one or some locked files and has tried to restart some Windows services. 
 
                   

Environment

CA Client Automation - All Versions

Resolution

In order to minimize the risk of locked files during CA Client Automation, the following commands should be executed before upgrade in order to stop all ITCM process :
 
REM ---- stop CAF ----
caf stop
tasklist | find /I "caf.exe"
IF %ERRORLEVEL% EQU 0 caf kill all

REM ---- stop cfsystray ----
start cfsystray stop
ping 127.0.0.1 -n 5 > nul
tasklist | find /I "cfsystray.exe"
IF %ERRORLEVEL% EQU 0 taskkill /F /IM cfsystray.exe

REM ---- stop CA Performance Lite Agent (present in previous release of ITCM) ----
net stop CASPLiteAgent
tasklist | find /I "casplitegent.exe"
IF %ERRORLEVEL% EQU 0 taskkill /F /IM casplitegent.exe

REM ---- stop CAM and CA Connection Broker ----
camclose
csampmux stop


Moreover these 2 parameters could be added in the command line used for upgrade in order to avoid Windows component "RESTART MANAGER" to restart some Windows Services in case of detection of locked files : 
 
MSIRESTARTMANAGERCONTROL=Disable MSIRMSHUTDOWN=2
 
 For example these parameters could be added in a new procedure in the package : 
 
 

Additional Information

Following links give information about these 2 parameters :

https://msdn.microsoft.com/en-us/library/windows/desktop/aa370380.aspx

https://msdn.microsoft.com/en-us/library/windows/desktop/aa370377(v=vs.85).aspx