Skip to content

How do I identify my Amazon VPC public IPv4 address charges?

3 minute read
0

I want to identify Amazon Virtual Private Cloud (Amazon VPC) public IPv4 address charges for my running and deleted AWS resources.

Resolution

Note: If you receive errors when you run AWS Command Line Interface (AWS CLI) commands, then see Troubleshooting errors for the AWS CLI. Also, make sure that you're using the most recent AWS CLI version.

Identify public IPv4 address charges for currently running resources

To identify current public IPv4 address charges across all AWS Regions, see How do I identify, monitor, and optimize my Amazon VPC public IPv4 address usage?

Identify public IPv4 address charges for deleted resources

Create a CUR

The AWS Cost and Usage Report (CUR) includes detailed usage data for public IPv4 addresses. This includes IP addresses that you currently use and ones that your resources previously used. After you create a cost and usage report, you can monitor both current and previous public IPv4 address charges.

For information about how to access and query your report, see Using your report.

Note: AWS updates the report files at least once a day with data from the beginning of the current month up to the current date.

To monitor public IPv4 address usage in your report, review the PublicIPv4:IdleAddress and PublicIPv4:InUseAddress usage types.

The lineItem/Operation column identifies the IPv4 address usage as one of the following types:

  • AllocateAddressVPC monitors idle Elastic IP addresses that don't have an associated resource.
  • AssociateAddressVPC monitors Elastic IP addresses that have an associated AWS resource.
  • RunInstances monitors Amazon Elastic Compute Cloud (Amazon EC2) public IPv4 addresses that are in VPCs.
  • DescribeNetworkInterfaces monitors service-managed public IPv4 addresses that are in VPCs.
  • CreateVpnConnection monitors public IPv4 addresses for AWS Site-to-Site VPN connections.
  • CreateAccelerator monitors public IPv4 addresses for AWS Global Accelerator.

Note: It can take up to 24 hours for AWS to deliver the report to your Amazon Simple Storage Service (Amazon S3) bucket.

Use AWS CloudTrail

To identify public IPv4 addresses for deleted resources, use AWS CloudTrail to search for IP address allocation events.

Look for the following event names:

  • AllocateAddress
  • AssociateAddress
  • RunInstances
  • CreateVpnConnection
  • CreateAccelerator
    Note: CloudTrail records CreateAccelerator events only in the US West (Oregon) Region.

To monitor IPv4 address allocation events for the last 90 days, run the lookup-events AWS CLI command:

aws cloudtrail lookup-events --lookup-attributes AttributeKey=EventName,AttributeValue=API_NAME 

Note: Replace API_NAME with the relevant event name.