TA-002-P · Question #50
Setting the TF_LOG environment variable to DEBUG causes debug messages to be logged into syslog.
The correct answer is A. True. Setting the TF_LOG environment variable directs Terraform's detailed logging output, which can be captured by system logging facilities like syslog depending on the execution environment.
Question
Setting the TF_LOG environment variable to DEBUG causes debug messages to be logged into syslog.
Options
- ATrue
- BFalse
How the community answered
(31 responses)- A90% (28)
- B10% (3)
Why each option
Setting the `TF_LOG` environment variable directs Terraform's detailed logging output, which can be captured by system logging facilities like syslog depending on the execution environment.
When `TF_LOG` is set to `DEBUG`, Terraform emits detailed logs to `stderr` by default; in many server environments or when run as a service, `stderr` is configured to be redirected and captured by `syslog`.
Terraform's log output often ends up in `syslog` or other system log managers indirectly via `stderr` redirection, making the statement 'False' generally incorrect in common deployment scenarios.
Concept tested: Terraform logging configuration
Source: https://developer.hashicorp.com/terraform/cli/config/environment-variables#tf_log
Topics
Community Discussion
No community discussion yet for this question.