Description |
This article describes when running the Terraform version command during the Terraform installation, getting the error message 'command not found'. |
Scope | FortiGate, Public Cloud. |
Solution |
According to the Terraform documentation for installing Terraform on Linux, it is necessary to download a Zip archive that contains a single binary file called Terraform. Unzip the archive and move the binary file to a directory that is included in your system’s PATH environment variable, such as /usr/local/bin. It is then possible to run the terraform command from any directory without specifying the full path. If the binary file is not moved to the bin directory, a 'command not found' error will be generated when trying to run the Terraform version command, as shown in the screenshot:
To fix this error, move the binary file to the bin directory exp: sudo mv terraform /usr/local/bin/ or specify the full path of the binary file when running the command. Verify the Terraform using the following command:
terraform --version |
The Fortinet Security Fabric brings together the concepts of convergence and consolidation to provide comprehensive cybersecurity protection for all users, devices, and applications and across all network edges.
Copyright 2025 Fortinet, Inc. All Rights Reserved.