After upgrade from 11.3 to 12.0 job failing with Invalid shell error
search cancel

After upgrade from 11.3 to 12.0 job failing with Invalid shell error

book

Article ID: 250274

calendar_today

Updated On:

Products

Autosys Workload Automation CA Workload Automation DE CA Workload Automation AE - System Agent (AutoSys) CA Workload Automation DE - System Agent (dSeries) Workload Automation Agent

Issue/Introduction

After upgrading agent from 11.3 to 12.0, some scripts are failing with an "Invalid shell with an error exit code 4014". 

 

Environment

Release : 12.0

Component : WAAE, WADE, Agent

Resolution

As oscomponent.checkvalidshell is enabled (oscomponent.checkvalidshell=true) in agentparm.txt, the agent performs a check against what is defined in your script and what is defined in the oscomponent.validshell parameter. These two parameters work in conjunction with each other. If the shell your script is using is not defined in the oscomponent.validshell parameter, the agent will fail the job.

  1. Identify the shell that your script is using. This can be done by viewing the contents of the script. The very first line of your script likely has something like #!/usr/bin/perl or #!/bin/ksh for example.
    Note: There are MANY shells that can be used. These are just examples.
  2. Whatever is listed at the top of the script, must be defined in the oscomponent.validshell parameter within your agentparm.txt file.

Examples:

  • If your script has !#/usr/bin/perl and is not defined in the oscomponent.validshell parameter, the agent will fail the job, resulting in 4014 exit code.
    • Resolution Steps:
      • Append /usr/bin/perl to the oscomponent.validshell parameter (separate the shell with a comma).
      • Restart agent for change to take effect.
      • Then rerun your job.
  • If your script has !#/usr/bin/ksh and is not defined in the oscomponent.validshell parameter, the agent will fail the job, resulting in 4014 exit code.
    • Resolution Steps:
      • Append /usr/bin/perl to the oscomponent.validshell parameter (separate the shell with a comma).
      • Restart agent for change to take effect.
      • Then rerun your job.

Additional Information

See oscomponent.checkvalidshell and oscomponent.validshell parameters in the
WA Agent for UNIX, Linux, Windows, or IBM i Agent Parameters
section of the Workload Automation System Agent documentation for details on these parameters.

Older versions prior to 11.4, did not honor oscomponent.checkvalidshell.
Setting oscomponent.checkvalidshell=false will bring the behavior closer to the old behavior.