You're almost there! Please answer a few more questions for access to the Applications content. Complete registration
Interested in joining? Complete your registration by providing Areas of Interest here. Register

OCI: How to Force Reboot a Linux Instance Using Ansible

Applies to: 

Oracle Cloud Infrastructure - Version N/A and later

Linux x86-64

 

Goal

Ansible is being used to manage Linux instances.

To reboot the instances, the ansible reboot module is being used.

But for some instances the normal reboot does not take place and they need to be forcefully rebooted from the OCI console by using the Force checkbox in the OCI instance reboot screen.

The question is, whether something similar be achieved from an Ansible playbook.


 

Solution

Ansible includes a reboot module since version 2.7 that allows an Ansible playbook to perform a controlled and graceful reboot, and proceed with the next play after the reboot completes without concerns.

Howdy, Stranger!

Log In

To view full details, sign in.

Register

Don't have an account? Click here to get started!