awslimitchecker¶
Master:
Develop:
A script and python module to check your AWS service limits and usage, and warn when usage approaches limits.
Users building out scalable services in Amazon AWS often run into AWS’ service limits - often at the least convenient time (i.e. mid-deploy or when autoscaling fails). Amazon’s Trusted Advisor can help this, but even the version that comes with Business and Enterprise support only monitors a small subset of AWS limits and only alerts weekly. The new Service Quotas service can also help with this, but relies on CloudWatch alarms per-limit to notify you when you approach your limits; this cannot easily scale to the hundreds of current service limits. awslimitchecker provides a command line script and reusable Python package that queries your current usage of AWS resources and compares it to limits (hard-coded AWS defaults that you can override, API-based limits where available, Service Quotas data where available, or data from Trusted Advisor where available), notifying you when you are approaching or at your limits.
Full project documentation for the latest release is available at http://awslimitchecker.readthedocs.io/en/latest/.
Status¶
awslimitchecker is mature software, with approximately 13,000 downloads per month and in daily use at numerous organizations.
Development status is being tracked on a board at waffle.io: https://waffle.io/jantman/awslimitchecker
What It Does¶
- Check current AWS resource usage against AWS Service Limits
- Show and inspect current usage
- Override default Service Limits (for accounts with increased limits)
- Compare current usage to limits; return information about limits that exceed thresholds, and (CLI wrapper) exit non-0 if thresholds are exceeded
- Define custom thresholds per-limit
- where possible, pull current limits from Trusted Advisor API
- where possible, pull current limits from each service’s API (for services that provide this information)
- where possible, pull current limits from the Service Quotas service
- Supports explicitly setting the AWS region
- Supports using STS to assume roles in other accounts, including using
external_id
. - Optionally refresh Trusted Advisor “Service Limits” check before polling Trusted Advisor data, and optionally wait for the refresh to complete (up to an optional maximum time limit). See Getting Started - Trusted Advisor for more information.
- Optionally send current usage and limit metrics to a metrics store, such as Datadog.
- Optionally send warning/critical alerts to notification providers, such as PagerDuty.
Requirements¶
Either Docker in order to run via the docker image, or:
- Python 3.5 or newer.
- Python VirtualEnv and
pip
(recommended installation method; your OS/distribution should have packages for these) - boto3 >= 1.4.6 and its dependency botocore >= 1.6.0.
Alternatively, awslimitchecker may be installed through conda with conda install -c conda-forge awslimitchecker
. This will automatically install the required dependencies as well.
Installation and Usage¶
See Getting Started.
Credentials¶
See Credentials.
Getting Help and Asking Questions¶
See Getting Help.
For paid support and development options, please see the Enterprise Support Agreements and Contract Development section of the documentation.
There is also a gitter.im chat channel for support and discussion.
Contributions¶
Pull requests are most definitely welcome. Please cut them against the develop branch. For more information, see the development documentation. I’m also happy to accept contributions in the form of bug reports, feature requests, testing, etc.
License¶
awslimitchecker is licensed under the GNU Affero General Public License, version 3 or later. This shouldn’t be much of a concern to most people; see Development / AGPL for more information.
Contents¶
- Getting Started
- Docker Usage
- Command Line Usage
- Examples
- Listing Supported Services
- Listing Default Limits
- Viewing Limits
- Disabling Service Quotas service
- Disabling Trusted Advisor Checks
- Disabling Specific Services
- Disabling Specific Checks
- Checking Usage
- Overriding Limits
- Check Limits Against Thresholds
- Set Custom Thresholds
- Enable Metrics Provider
- Enable Alerts Provider
- Required IAM Policy
- Connect to a Specific Region
- Assume a Role in Another Account with STS
- Partitions and Trusted Advisor Regions
- Handling Throttling and Rate Limiting
- Examples
- Python Usage
- Full Jenkins Example
- Simple Examples
- Instantiating the Class
- Specifying a Region
- Refreshing Trusted Advisor Check Results
- Assuming a Role with STS
- Setting a Limit Override
- Setting a Threshold Override
- Checking Thresholds
- Disabling Trusted Advisor
- Disabling Service Quotas
- Partitions and Trusted Advisor Regions
- Skipping Specific Services
- Handling Throttling and Rate Limiting
- Logging
- Advanced Examples
- Required IAM Permissions
- Supported Limits
- Getting Help
- Development
- Pull Requests
- Installing for Development
- Guidelines
- Adding New EC2 Instance Types
- Adding New Limits and Checks to Existing Services
- Adding New Services
- Trusted Advisor Checks
- Adding Metrics Providers
- Adding Alert Providers
- Unit Testing
- Integration Testing
- Building Docs
- Building the Docker Image
- AGPL License
- Handling Issues and PRs
- Versioning Policy
- Release Checklist
- Internals
- API
- Changelog
- 11.0.0 (2021-04-20)
- 10.0.0 (2020-12-07)
- 9.0.0 (2020-09-22)
- 8.1.0 (2020-09-18)
- 8.0.2 (2020-03-03)
- 8.0.1 (2019-12-28)
- 8.0.0 (2019-11-03)
- 7.1.0 (2019-09-10)
- 7.0.0 (2019-08-13)
- 6.1.7 (2019-05-17)
- 6.1.6 (2019-04-19)
- 6.1.5 (2019-03-06)
- 6.1.4 (2019-03-01)
- 6.1.3 (2019-02-26)
- 6.1.2 (2019-02-19)
- 6.1.1 (2019-02-15)
- 6.1.0 (2019-01-30)
- 6.0.1 (2019-01-27)
- 6.0.0 (2019-01-01)
- 5.1.0 (2018-09-23)
- 5.0.0 (2018-07-30)
- 4.0.2 (2018-03-22)
- 4.0.1 (2018-03-09)
- 4.0.0 (2018-02-17)
- 3.0.0 (2017-12-02)
- 2.0.0 (2017-10-12)
- 1.0.0 (2017-09-21)
- 0.11.0 (2017-08-06)
- 0.10.0 (2017-06-25)
- 0.9.0 (2017-06-11)
- 0.8.0 (2017-03-11)
- 0.7.0 (2017-01-15)
- 0.6.0 (2016-11-12)
- 0.5.1 (2016-09-25)
- 0.5.0 (2016-07-06)
- 0.4.4 (2016-06-27)
- 0.4.3 (2016-05-08)
- 0.4.2 (2016-04-27)
- 0.4.1 (2016-03-15)
- 0.4.0 (2016-03-14)
- 0.3.2 (2016-03-11)
- 0.3.1 (2016-03-04)
- 0.3.0 (2016-02-18)
- 0.2.3 (2015-12-16)
- 0.2.2 (2015-12-02)
- 0.2.1 (2015-12-01)
- 0.2.0 (2015-11-29)
- 0.1.3 (2015-10-04)
- 0.1.2 (2015-08-13)
- 0.1.1 (2015-08-13)
- 0.1.0 (2015-07-25)