search cancel

Remote Windows agents are in SRVC_DOWN status


Article ID: 89561


Updated On:


CA Automic Applications Manager (AM)


Remote Windows agents are in SRVC_DOWN status


Release: AAMOS499000-8.0-Automic Applications Manager-OS400 Agent


Detailed Description and Symptoms

After rebooting the windows server a remote agent resides on the agent itself goes into a SRVC_DOWN status. This happens when the remote agent's service is set on automatic. Once the service is restarted the agent stays running and jobs process just fine.


This appears to be a timing issue. A quick work around is to add a script to restart the remote agent's service after the masters server is rebooted.

Create a script named AWW-restart.bat file in the %AW_HOME%\bin folder on the Windows remote agent with the following information in the script.


REM ----------------------------------------------------------------------------
REM  New restart process launched by WATCHSTART.BAT, to check the latent status
REM  of the Agent's state as seen by the Master >awexe node query< then restart
REM  the Agent if in a Srvc_Down state and no recovery options on Master - v7.1
REM ----------------------------------------------------------------------------
call C:\appworx\site\sosite
%aw_home%\c\sleep 200                             
echo ------- Verify_1 at: %date% %time% -------    >>%AW_HOME%\log\AWWRestart.log
sc query AWW-%so_operator%                         >>%AW_HOME%\log\AWWRestart.log
awexe node | findstr %so_operator%                 >>%AW_HOME%\log\AWWRestart.log
awexe node | findstr %so_operator% | findstr Srvc_Down
if %errorlevel% equ 0 (
  echo ------ Restarting at: %date% %time% ------   >%AW_HOME%\log\AWWRestart.lis
  sc stop AWW-%so_operator%                        >>%AW_HOME%\log\AWWRestart.lis         
  %aw_home%\c\sleep 20
  sc start AWW-%so_operator%                       >>%AW_HOME%\log\AWWRestart.lis
  %aw_home%\c\sleep 10
  awexe node | findstr %so_operator%               >>%AW_HOME%\log\AWWRestart.lis 
echo ------- Verify_2 at: %date% %time% -------    >>%AW_HOME%\log\AWWRestart.log
sc query AWW-%so_operator%                         >>%AW_HOME%\log\AWWRestart.log

Now edit the watchstart.bat file in the %AW_HOME\bin folder of the Windows remote agent, and add the following line to the end of the watchstart.bat file. If there isn't a watchstart.bat file edit the watchstart.hold file, and rename it watchstart.bat.

start %AW_HOME%\bin\AWW-restart.bat

Go to services. and restart the AWW-<agent name> service.