Schedule unused resources to be powered off or terminated
To terminate or power off an unused resource, add it to an Unused resources job, specify whether to terminate or power off, and specify when the job should run. You can also move resources from one scheduled job to a different job.
Before you begin
Run Discovery on each service account.
Ensure that the Billing Download job has completed for each provider.
Ensure that the Price Sheet Download job has completed for each provider.
Role required: insights_admin [sn_clin_core.insights_admin] or insights_owner [sn_clin_core.insights_owner]
About this task
Important: After an Unused resources job powers off or terminates a machine, the machine is added to the Excluded Resources list for Business Hours. This process ensures that the resource isn't started again in the future because it matches a Business Hours policy. The exclusion reason on the Business Hours Excluded Resources tab indicates that the resource is an unused resource.
When you change the resources that are included in a job, the app checks for the following conditions:
- A resource in the job is owned by another user (as when a insights_admin updates a job that was created by an insights_owner or an insights_owner updates a job that was created by a different insights_owner).
- The job was created by another user.
If either condition is met, the app sends an email notification to the owner of the resource or the creator of the job.
Procedure
Navigate to Cloud Cost Management Workspace > Operations > Recommendations > Unused resources.
In the list on the appropriate tab, select the check boxes for the resources to terminate.
- To create an Unused resources job for resources that are new candidates for termination: On the New Recommendations tab, select the resources and then select Schedule Job.
- To create a job for resources that had previously been scheduled but the action wasn't completed successfully: On the Declined Recommendations tab or the Failed Recommendations tab, select the resources and then select Reschedule. Note: Microsoft Azure only: The Azure Advisor service generates the recommendations that appear in Rightsizing and Unused resources reports. Cloud Cost Management doesn't generate the recommendations.
In the dialog box, fill in the fields.
| Field | Value |
|---|---|
| Job Type | Type of job action.Select Schedule job. |
| Job name | Unique and descriptive name for the Unused resources job. |
| Action | The action to take on the selected resources:- Power off machine: Power off triggers a Microsoft Azure process called deallocation to set the resource as Stopped (Deallocated). - Terminate machine: Terminated machines can't be recovered. - Terminate machine and delete storage: If the root volume isn’t automatically deleted when the VM is terminated, the job deletes the root volume. No other volumes are deleted. Note: Terminated resources or deleted volumes can't be recovered. |
| Schedule | Date and time to run the Unused resources job. |
| Approval type | Type of change request to use. Unused Machines operations are directly integrated with the ServiceNow® Change Management feature.
The Short description, Description, Assignment group, and Affected CIs fields are auto-populated. For more information, see Create a change request. |
| Change template | This field appears only when the Approval type is set to Auto approval. Change request template (Standard Change type) to be used. If no template appears in the list, you must create one. |
- Select Submit.
Result
The Unused resources job is created and runs at the scheduled time.
Parent Topic:Manage unused resources
Related topics