github.com/profects/terraform@v0.9.0-beta1.0.20170227135739-92d4809db30d/website/source/docs/commands/state/push.html.md (about)

     1  ---
     2  layout: "commands-state"
     3  page_title: "Command: state push"
     4  sidebar_current: "docs-state-sub-push"
     5  description: |-
     6    The `terraform state rm` command removes items from the Terraform state.
     7  ---
     8  
     9  # Command: state push
    10  
    11  The `terraform state push` command is used to manually upload a local
    12  state file to [remote state](/docs/state/remote.html). This command also
    13  works with local state.
    14  
    15  This command should rarely be used. It is meant only as a utility in case
    16  manual intervention is necessary with the remote state.
    17  
    18  ## Usage
    19  
    20  Usage: `terraform state push [options] PATH`
    21  
    22  This command will push the state specified by PATH to the currently
    23  configured [backend](/docs/backends).
    24  
    25  Terraform will perform a number of safety checks to prevent you from
    26  making changes that appear to be unsafe:
    27  
    28    * **Differing lineage**: If the "lineage" value in the state differs,
    29      Terraform will not allow you to push the state. A differing lineage
    30      suggests that the states are completely different and you may lose
    31      data.
    32  
    33    * **Higher remote serial**: If the "serial" value in the destination state
    34      is higher than the state being pushed, Terraform will prevent the push.
    35      A higher serial suggests that data is in the destination state that isn't
    36      accounted for in the local state being pushed.
    37  
    38  Both of these safety checks can be disabled with the `-force` flag.
    39  **This is not recommended.** If you disable the safety checks and are
    40  pushing state, the destination state will be overwritten.