[ECS] [request]: add available ENI slots in container instance election for task provisioning
- Dominant language
- Shell
- Stars
- 5.4k
- Forks
- 334
- PR merge metrics
- No merged PRs in 30d
Description
### Community Note
* Please vote on this issue by adding a 👍 [reaction](https://blog.github.com/2016-03-10-add-reactions-to-pull-requests-issues-and-comments/) to the original issue to help the community and maintainers prioritize this request
* Please do not leave "+1" or "me too" comments, they generate extra noise for issue followers and do not help prioritize the request
* If you are interested in working on this issue or have submitted a pull request, please leave a comment
**Tell us about your request**
When using `awsvpc` networking type ECS scheduler does not take into account task limit of the EC2 nodes in terms of ENI allocation when scheduling tasks.
So it often happens that tasks are failing to start and are delayed to be up ; stoppedReason being `Unable to attach network interface to unused device index.`.
I guess this could also happen when using eni trunking.
**Which service(s) is this request for?**
ECS
**Tell us about the problem you're trying to solve. What are you trying to do, and why is it hard?**
EC2 container instances are limited by cpu/memory and eni but the latest is not used for agent election by ECS scheduler.
**Are you currently working around this issue?**
Considering switching to eni trunking to mitigate the issue.
Contributor guide
Assessment
This issue has not been assessed yet.