View a markdown version of this page

Managing IPAM policies - Amazon Virtual Private Cloud
Services or capabilities described in Amazon Web Services documentation might vary by Region. To see the differences applicable to the China Regions, see Getting Started with Amazon Web Services in China (PDF).

Managing IPAM policies

This section describes the prerequisites for IPAM policies and how to create and enable them.

Prerequisites

Before you begin, make sure that you have the following:

Creating an IPAM policy

You can create an IPAM policy by using the Amazon Web Services Management Console or the Amazon CLI.

To create an IPAM policy (console)
  1. Open the IPAM console at https://console.amazonaws.cn/ipam/.

  2. In the left navigation pane, choose Policies.

  3. Choose Create policy.

  4. Enter a Name for your policy (optional).

  5. Select the IPAM to associate with this policy.

  6. (Optional) Add tags.

  7. Choose Create policy.

To create an IPAM policy (Amazon CLI)

After you create the policy, add rules to it. For more information about allocation rules, see Defining a public IPv4 allocation strategy with IPAM policies.

Enabling an IPAM policy

Specify which accounts should use the policy. A policy's targets apply to all of the rules in the policy, and only one policy can be enabled for a given target.

To enable an IPAM policy (console)
  1. In your policy details page, choose the Targets tab.

  2. Choose Manage policy targets.

  3. Do one of the following:

    • For single account usage (IPAM not integrated with Amazon Organizations, or an account applying a policy to itself), choose Enable for your account.

    • For IPAM integrated with Amazon Organizations (when you're the delegated admin):

      • In the Organizational structure section, select the accounts or organizational units where you want to apply this policy.

      • Check the Enabled checkbox for each target.

      • Choose Save Changes.

To enable an IPAM policy (Amazon CLI)
  • Use the enable-ipam-policy command based on your setup:

    • For single account usage (IPAM not integrated with Amazon Organizations, or an account applying a policy to itself):

      aws ec2 enable-ipam-policy \ --ipam-policy-id ipam-policy-12345678
    • For IPAM integrated with Amazon Organizations (when you're the delegated admin), set a policy to target an account in the organization:

      aws ec2 enable-ipam-policy \ --ipam-policy-id ipam-policy-12345678 \ --organization-target-id 111122223333
    • For IPAM integrated with Amazon Organizations (when you're the delegated admin), set a policy to target an organizational unit:

      aws ec2 enable-ipam-policy \ --ipam-policy-id ipam-policy-12345678 \ --organization-target-id ou-123
Important

Enabling a policy for a target replaces any policy that is already enabled for that same target. Policies enabled for different targets coexist. For more information, see Which policy applies to an account.