Stopping an Instance

You can stop an instance using OCI tools or from the operating system.

Shutting Down or Restarting an Instance Using the Instance's OS

You can shut down and restart instances using the commands available in the OS when you're signed in to the instance. Shutting down an instance using the instance's OS doesn't stop billing for that instance. If you shut down an instance this way, be sure to also stop it from the Console or API.

    1. Navigate to the Compute Instances list page. If you need help finding the list page, see Listing Instances.
    2. From the Actions menu Actions Menu for the instance, select Stop.

      By default, the Console gracefully restarts the instance by sending a shutdown command to the OS. The system waits for up to 15 minutes for the OS to shut down. The instance is powered off and then powered back on.

      Note

      If the applications that run on the instance take more than 15 minutes to shut down, improperly stopping them might result in data corruption. To avoid this, shut down the instance using the commands available in the OS before you stop the instance using the Console.
      Caution

      To stop the instance immediately, without waiting for the OS to respond, select the Force stop the instance by immediately powering off checkbox. Improperly stopping an instance might result in data corruption.
    3. Select Stop instance.
  • Use the instance action command and required parameters to stop an instance:

    oci compute instance action --instance-id <instance_OCID> --action SOFTSTOP

    To power off the instance immediately, use the STOP action.

    For a complete list of parameters and values for CLI commands, see the CLI Command Reference.

  • For information about using the API and signing requests, see REST API documentation and Security Credentials. For information about SDKs, see SDKs and the CLI.

    Use the InstanceAction operation to stop an instance, passing the value SOFTSTOP as the action to perform.

    To power off the instance immediately, use the STOP action.