SpinTheMic
Pro

Interview practice question

Moving Terraform state from local to a remote backend

Cloud & DevOps · Terraform and IaC · Intermediate

A project has been using local state, and you want to move it to a remote backend. How do you do this safely?

What a strong answer covers

Your AI report card counts how many of these ideas you cover.

  • Back up local state.
  • Create backend storage with locking.
  • Add backend block.
  • terraform init -migrate-state.
  • Verify plan shows no changes; remove local copies.
Practise this topic

Start without signing up. Sign in free to get an AI report card on your answer.

See all topics