What counts as an Elastic IP remap? How to view the number of elastic IP remaps consumed for this month?

0

Hi,

I am writing a script for a use case where we have to transfer a list of elastic IP addresses attached to a source (instance1) to a destination (instance2). The approach that I am following is:

  1. Identify the network interface addresses and private IP addresses at the destination machine where Elastic IPs have to be attached.
  2. Use the boto3 associate_address API to move the elastic IP to the destination interface.
  3. For this question, assume that the destination has enough network interfaces available to accommodate new elastic IPs.

While this process works well for our use case, my primary question is, what counts as an elastic IP remap?

Do the following cases count as an elastic IP remap:

  1. Allocating and releasing an elastic IP address?

  2. Using associate_address to associate a free elastic IP address to a private IP of a network interface?

  3. Using associate_address to associate an already associated IP address to another private IP of a different network interface? Does this count as 1 or 2 remaps (2 if automatic detachment is counted as a remap)?

  4. Detaching a network interface with 3 elastic IPs from the source instance and attaching it as it is to the destination instance, without individually modifying the private IPs or elastic IPs. Does this count as 3 remaps or no remaps?

How can I view the number of IP remaps already used, as detailed on the elastic IP pricing page:

$0.00 per Elastic IP address remap for the first 100 remaps per month

$0.10 per Elastic IP address remap for additional remaps over 100 per month

I have tried a lot of places to look for this value, including setting up a S3 billing bucket with hourly granularity, but couldn't find this.

I am trying to find this value to avoid the $0.10 per remap cost kicking up, as its pretty expensive.

Thanks in advance !!

  • from the documentation of associate_address and VpcAddress.associate, it appears that associating/disassociating an elastic IP from any state counts as a remap, since it is an idempotent operation.

    This leaves only the 4th usecase unanswered.

1 Answer
1

Hello Abhinay,

AWS did not provide a direct method to view the number of Elastic IP remaps consumed for the current month through the AWS Management Console or the AWS CLI. To monitor your Elastic IP remaps and associated costs, you had to implement your own tracking mechanism. Here's a general approach to help you track Elastic IP remaps:

  1. CloudWatch Metrics:

    You can set up custom CloudWatch metrics to track Elastic IP remaps. This requires creating a Lambda function that is triggered by CloudTrail events related to Elastic IP remaps. The Lambda function can increment a custom CloudWatch metric for each remap event.

    • Enable CloudTrail for your AWS account.
    • Create a CloudWatch metric to track remaps.
    • Create a Lambda function that processes CloudTrail events and increments the metric.
    • Set up a CloudWatch alarm to notify you when the number of remaps exceeds a certain threshold.
  2. Billing and Cost Management:

    While AWS does not provide a direct way to view remaps, you can monitor your AWS costs and track Elastic IP-related charges using AWS Cost Explorer and AWS Cost and Usage Reports. Look for "Elastic IP remap" charges in your detailed billing reports. This won't provide real-time tracking but can help you track costs historically.

  3. Third-Party Tools:

    There are third-party tools and services that can help you monitor AWS costs and usage in more detail. Tools like CloudCheckr, CloudHealth, and others can provide cost and usage analysis, including Elastic IP-related costs.

Since the AWS ecosystem is continually evolving, it's a good idea to check AWS documentation and release notes for updates on tracking Elastic IP remaps. AWS may introduce new features or improvements to help users monitor and manage their resource usage and costs more effectively.

profile picture
answered 8 months ago
  • Thanks for the quick response Gabriel! Can you please answer some questions that I have regarding what counts as a remap, as I have updated in the question description.

You are not logged in. Log in to post an answer.

A good answer clearly answers the question and provides constructive feedback and encourages professional growth in the question asker.

Guidelines for Answering Questions