Getting started with Amazon Compute Optimizer
When you access the Amazon Compute Optimizer console for the first time, you're asked to opt in using the account that you’re signed in with. Before you can use the service, you must opt in or out. In addition, you can also opt in or opt out using the Compute Optimizer API, Amazon Command Line Interface (Amazon CLI), or SDKs.
By opting in, you're authorizing Compute Optimizer to analyze the specifications and utilization metrics of your Amazon resources. Examples include EC2 instances and Auto Scaling groups.
Accounts supported by Compute Optimizer
The following Amazon Web Services account types can opt in to Compute Optimizer:
-
Standalone Amazon account
A standalone Amazon Web Services account that doesn't have Amazon Organizations enabled. For example, suppose that you opt in to Compute Optimizer while signed in to a standalone account. Then, Compute Optimizer analyzes the resources in the account and generates optimization recommendations for those resources.
-
Member account of an organization
An Amazon Web Services account that's a member of an organization. If you opt in to Compute Optimizer while signed in to a member account of an organization. Then, Compute Optimizer only analyzes the resources in the member account and generates optimization recommendations for those resources.
-
Management account of an organization
An Amazon Web Services account that administers an organization. If you opt in to Compute Optimizer while signed in to a management account of an organization. Then, Compute Optimizer gives you the option to opt in the management account only, or the management account and all member accounts of the organization.
Important
To opt in all member accounts for an organization, make sure that the organization has all features enabled. For more information, see Enabling All Features in Your Organization in the Amazon Organizations User Guide.
When you opt in using your organization's management account and include all member accounts within the organization, trusted access for Compute Optimizer is enabled in your organization account. For more information, see Compute Optimizer and Amazon Organizations trusted access.
Required permissions
You must have the appropriate permissions to opt in to Compute Optimizer, to view its recommendations, and to opt out. For more information, see Controlling access with Amazon Identity and Access Management.
When you opt in, Compute Optimizer automatically creates a Service-Linked Role in your account to access its data. For more information, see Using service-linked roles for Amazon Compute Optimizer.
Opting in your account
Use the following procedure to opt in your account using the Compute Optimizer console or the Amazon CLI.
Note
If your account is already opted in, but you want to opt in again to re-enable trusted
access for Compute Optimizer in your organization. You can opt in again, but this must be done using the
Amazon CLI. When you opt in using the Amazon CLI, run the update-enrollment-status
command and specify the --include-member-accounts
parameter. Alternatively, you
can enable trusted access directly in the Amazon Organizations console or by using Amazon CLI or API. For
more information, see Using Amazon Organizations
with other Amazon Web Services in the Amazon Organizations User Guide.
Consider the following after opting in:
-
After you opt in, findings and optimization recommendations can take up to 24 hours to be generated. Moreover, for optimization recommendations can be generated, sufficient metric data must be accumulated. For more information, see CloudWatch metric requirements.
-
Findings and recommendations are displayed in the dashboard and the recommendation pages of the Compute Optimizer console. For more information, see Viewing the Amazon Compute Optimizer dashboard and Viewing resource recommendations.
-
Some recommendation preferences such as the enhanced infrastructure metrics is paid feature. This feature extends the metrics analysis look-back period of EC2 instances, including instances in Auto Scaling groups, to up to three months. By default, the look-back period is 14 days. For more information, see Recommendation preferences.
Note
To improve the recommendation quality of Compute Optimizer, Amazon Web Services might use your CloudWatch metrics and
configuration data. This includes up to three months (93 days) of metrics analysis when you
activate the enhanced infrastructure metrics feature. Contact Amazon Web Services Support
Opting out your account
Use the following procedure to opt out your account from Compute Optimizer using the Amazon CLI. The same procedure also deletes your account's recommendations and related metrics data from Compute Optimizer. For more information, see update-enrollment-status in the Amazon CLI Command Reference. You can't opt out using the Compute Optimizer console.
To opt out an account
-
Open a terminal or command prompt window.
If you haven't already, install the Amazon CLI and configure it to work with Compute Optimizer. For more information, see Installing the Amazon CLI and Quickly Configuring the Amazon CLI in the Amazon Command Line Interface User Guide.
-
Enter the following command.
aws compute-optimizer update-enrollment-status --status Inactive
Note
You can't specify the
--include-member-accounts
parameter when opting out with theupdate-enrollment-status
command. If you specify this parameter when opting out with this command, an error occurs.
Your account is opted out of Compute Optimizer after running the previous command. At the same time, your account's recommendations and related metrics data are deleted from Compute Optimizer. If you access the Compute Optimizer console, the option to opt in again should be displayed.