exam questions

Exam Terraform Associate All Questions

View all questions & answers for the Terraform Associate exam

Exam Terraform Associate topic 1 question 168 discussion

Actual exam question from HashiCorp's Terraform Associate
Question #: 168
Topic #: 1
[All Terraform Associate Questions]

terraform apply is failing with the following error. What next step should you take to determine the root cause of the problem?
Error loading state: AccessDenied: Access Denied status code: 403, request id: 288766CE5CCA24A0, host id: FOOBAR

  • A. Set TF_LOG=DEBUG
  • B. Review syslog for Terraform error messages
  • C. Run terraform login to reauthenticate with the provider
  • D. Review /var/log/terraform.log for error messages
Show Suggested Answer Hide Answer
Suggested Answer: A 🗳️
Community vote distribution
A (83%)
C (17%)

Comments

Chosen Answer:
This is a voting comment. You can switch to a simple comment. It is better to Upvote an existing comment if you don't have anything to add.
Switch to a voting comment New
Burakko
Highly Voted 2 years ago
Selected Answer: A
Terraform has detailed logs which can be enabled by setting the TF_LOG environment variable to any value. This will cause detailed logs to appear on stderr. You can set TF_LOG to one of the log levels (in order of decreasing verbosity) TRACE, DEBUG, INFO, WARN or ERROR to change the verbosity of the logs.
upvoted 8 times
...
jednorozec2022
Highly Voted 1 year, 12 months ago
A A. Set TF_LOG=DEBUG >> only this one sound like correct answear B. Review syslog for Terraform error messages >> firstly you need to turn on terraform logging ref https://www.terraform.io/internals/debugging C. Run terraform login to reauthenticate with the provider >> login is used to connect with Terraform Cloud, Terraform Enterprise, or any other host that offers Terraform services ref https://www.terraform.io/cli/commands/login D. Review /var/log/terraform.log for error messages >> you would have to turn on logging and add path to logging ref https://www.terraform.io/internals/debugging
upvoted 5 times
...
Spandrop
Most Recent 9 months, 1 week ago
"A" maybe make sense, but why you would like to enable TF_LOG for a message that is crystal clear: ACCESS DENIED?!
upvoted 2 times
...
InformationOverload
1 year, 8 months ago
Selected Answer: A
A makes sense here.
upvoted 1 times
...
DerekKey
1 year, 9 months ago
A Correct C - no - provider is not responsible for managing state
upvoted 1 times
...
RVivek
1 year, 11 months ago
Selected Answer: A
to determine the root cause of the problem , we need to first enable logging
upvoted 1 times
...
jjkcoins
2 years ago
Selected Answer: C
Error loading state: AccessDenied: Access Denied status code: 403, request id: 288766CE5CCA24A0, host id: FOOBAR C. Run terraform login to reauthenticate with the provider
upvoted 2 times
...
Community vote distribution
A (35%)
C (25%)
B (20%)
Other
Most Voted
A voting comment increases the vote count for the chosen answer by one.

Upvoting a comment with a selected answer will also increase the vote count towards that answer by one. So if you see a comment that you already agree with, you can upvote it instead of posting a new comment.

SaveCancel
Loading ...
exam
Someone Bought Contributor Access for:
SAA-C03
Dublin, 1 minute ago