Let's assume that I have 20 running EC2 instances and 10 active Reserved Instance reservations.
Using the AWS Console or AWS CLI, what is the fastest way to determine which of the running EC2 instances are not 'covered' by a Reserved Instance reservation?
To give more clarity on the desired result, consider the following (not possible in the AWS console that I'm aware of):
- Get a list of all
runninginstances in a region. You can do this in the AWS console today and via the AWS CLI. - Get a list of all
activeReserved Instance reservations in the same region. you can do this in the AWS console today and via the AWS CLI. - Cross-check the two lists: Every time you see a
runninginstance of size X in zone Y, and there is a Reserved Instance reservation of size X in zone Y, remove it from therunninglist. - The remainder of instances in the modified
runninglist are all those that are not covered by a Reserved Instance reservation.
I'm looking for a way to get #4 without having to manually copy the two lists available in the AWS console to Excel and manually crossing off running instances as I see a corresponding RI reservations. I could write a script that uses the CLI to do this too, but I was assuming that there might be something that already exists since this is an obvious way of analyzing cost efficiency.