Remote Execution or Proxy job fails with the following error: Remote invocation failed java.lang.RuntimeException: java.lang.Exception: Instance id not extracted - process ID line not found

book

Article ID: 6026

calendar_today

Updated On:

Products

CA Workload Automation Agents

Issue/Introduction

We have installed the Remote Execution plugin (proxy.pak) and configured a Remote target successfully, however when we execute a Remote Execution/Proxy job, it fails with the error: Instance id not extracted - process ID line not found

CA Workload Automation DE (dSeries) example:

<Please see attached file for image>

RemoteExecError_DE.png

CA Workload Automation AE (AutoSys) example:

<Please see attached file for image>

RemoteExecError_AE.png

The System Agent spool log shows the following Java exception:

Remote invocation failed
java.lang.RuntimeException: java.lang.Exception: Instance id not extracted - process ID line not found
        at jdk.nashorn.internal.runtime.ScriptRuntime.apply(ScriptRuntime.java:397)
        at jdk.nashorn.api.scripting.ScriptObjectMirror.callMember(ScriptObjectMirror.java:199)
        at jdk.nashorn.api.scripting.NashornScriptEngine.invokeImpl(NashornScriptEngine.java:386)
        at jdk.nashorn.api.scripting.NashornScriptEngine.invokeFunction(NashornScriptEngine.java:190)
        at cybermation.plugins.proxy.ScriptProcessor.executeCommands(ScriptProcessor.java:155)
        at cybermation.plugins.proxy.RemoteExecutionHandler.run(RemoteExecutionHandler.java:290)
        at java.lang.Thread.run(Thread.java:745)
Caused by: java.lang.Exception: Instance id not extracted - process ID line not found
        at cybermation.plugins.proxy.parser.StatusProcessor.extractUnixInstanceId(StatusProcessor.java:106)
        at jdk.nashorn.internal.scripts.Script$Recompilation$3$2501AAAAAAAAA$\^eval\_.executeCommands(<eval>:196)
        at java.lang.invoke.MethodHandle.invokeWithArguments(MethodHandle.java:627)
        at jdk.nashorn.internal.runtime.ScriptFunctionData.invoke(ScriptFunctionData.java:671)
        at jdk.nashorn.internal.runtime.ScriptFunction.invoke(ScriptFunction.java:494)
        at jdk.nashorn.internal.runtime.ScriptRuntime.apply(ScriptRuntime.java:393)
        at jdk.nashorn.api.scripting.ScriptObjectMirror.callMember(ScriptObjectMirror.java:199)
        at jdk.nashorn.api.scripting.NashornScriptEngine.invokeImpl(NashornScriptEngine.java:386)
        at jdk.nashorn.api.scripting.NashornScriptEngine.invokeFunction(NashornScriptEngine.java:190)
        at cybermation.plugins.proxy.ScriptProcessor.executeCommands(ScriptProcessor.java:155)
        at cybermation.plugins.proxy.RemoteExecutionHandler.run(RemoteExecutionHandler.java:290)
        at java.lang.Thread.run(Thread.java:745)

Cause

 

The problem is caused by the limitation of characters-length on a single line imposed by the Bourne shell (/bin/sh or /usr/bin/sh) on some UNIX/Linux systems. Modern Linux distributions have replaced (symbolically linked) Bourne shell with Bourne-Again SHell which allows more characters per line, so this problem is not likely to happen on recent releases of Linux/UNIX systems.

Environment

CA Workload Automation System Agent 11.3+CA Workload Automation Agent for Remote Execution 11.3+All supported UNIX/Linux Operating Systems.

Resolution

 

This invocation error can be avoided by configuring the Remote Execution agent to switch the user shell, on the remote node, to Bash immediately after logging on. This end is achieved by means of adding a login task to the custom <remote_node>.properties file.

The following example changes the shell to Bash using SSH2:

loginTask.1.startPrompt=.* loginTask.1.startPromptRegex=true loginTask.1.endPrompt=.* loginTask.1.endPromptRegex=true loginTask.1.command=bash

Sample custom properties for CA WA System Agent installed with CA WA AE:

<Please see attached file for image>

src="/servlet/servlet.FileDownload?file=0150c000004AKExAAO" alt="RemoteExecSwitchShell.png" width="867" height="233">

Note: The CA WA System Agent needs a restart after the update to the custom properties file for your Remote system.

Additional Information

Troubleshoot CA WA Agent for Remote Execution

Attachments

1558707751546000006026_sktwi1f5rjvs16qsk.png get_app
1558707749531000006026_sktwi1f5rjvs16qsj.png get_app
1558707747582000006026_sktwi1f5rjvs16qsi.png get_app