Skip to main content
bksol92
Staff
Staff
May 15, 2023 5:02 AM UTC

Troubleshooting Tip: TCL Script Execution Failed

Description This article describes how to handle issues where TCL script execution failed after updating the admin password in a FortiGate.
Scope FortiManager.
Solution

According to the FortiManager administration guide, TCL Scripts use SSH to tunnel through FGFM and they require SSH authentication to do so.

 

After updating and installing the FortiGate's admin password through the Install Wizard, the following error may be presented when running a TCL script against it:

 

script fail.PNG

 

Run the following debugging command while the script is running, and the following error will appear: 'ssh authentication fail':

 

diagnose debug application dmworker -1

diagnose debug enable

 

ssh authentication fail.PNG

 

It is also possible to run the following debug command on FortiGate to confirm that the error is due to SSH authentication failure:

 

diagnose debug application sshd -1

diagnose debug console timestamp enable

diagnose debug enable

 

To stop debugging after the issue has been replicated:

 

diagnose debug reset

diagnose debug disable

 

The following error should appear:

 

sshd.PNG

 

In order to resolve this, it will be necessary to 'right-click' the FortiGate name under Managed Devices, then select Edit to update the device's admin password:

 

edit password.PNG

 

Once done, it will be possible to run the TCL script against it with the new admin password:

 

run complete.PNG

    Thought Leadership. Security Summit. Thursday, November 12th, PGA National Resort, Palm Beach Gardens, FL.
    Security Operations Summit: Modernize SecOps. Operate AI-Native.AMER: November 4 | 9:00 AM PST. India and SAARC: November 5 | 10:00 AM IST. EMEA: November 5 | 10:30 AM CET. APAC: November 5 | 11:00 AM SGT