Not able to run Ping command from ITPAM through RUN_Command operator.

book

Article ID: 221683

calendar_today

Updated On:

Products

CA Process Automation Base

Issue/Introduction

We are not able to run some basic commands like ping, ipconfig from ITPAM through RUN_Script operator. But manually those commands are running on the agents both inside cmd and Powershell. Getting below error :

"ping : The term 'ping' is not recognized as the name of a cmdlet, function, 
script file, or operable program. Check the spelling of the name, or if a path 
was included, verify that the path is correct and try again.
At C:\Temp\.c2otmp\8e1a3b53-9674-4e6f-8898-c115b710dade\c2ouscript.ps1:3 char:1
+ ping ###.###.###.###
+ ~~~~
    + CategoryInfo          : ObjectNotFound: (ping:String) [], CommandNotFoundException
    + FullyQualifiedErrorId : CommandNotFoundException"
 

 

Cause

This error can occur if the path is not set appropriately. To test/verify the path used by the ITPAM touchpoint (Orchestrator or Agent), you can run a new process with the "Run Script" configured with:

  • Script extension: .ps1
  • Inline Script: $env.path

 

When you get this error it is usually an indication that C:\Windows\System32 is not in your PATH. This can happen if there is a User Environment Variable named Path with a value that does not include C:\Windows\System32 (or the path of whatever command you're trying to run that generates this message). 

 

Environment

Release : 4.3

Component : CA Process Automation

 

Resolution

To solve this problem, do one of the following:

  • Remove the User Environment Variable Path for the account that is set to start the ITPAM Orchestrator or Agent; or
  • Update the User Environment Variable Path, for the account that is set to start the ITPAM touchpoint, to include: C:\Windows\System32 (or the path of whatever command you're trying to run that generates this message). 

Once one of these solutions have been implemented, restart the ITPAM touchpoint (Orchestrator or Agent) where the change was made for it to pickup the new settings.