karpenter-provider-aws: Provide More Verbose AMI Compatibility Failure Error Messaging
Tell us about your request
When an AMI fails to be compatible with any instance types during the cloudprovider.Create()
process, an error is fired with the following messaging
2023-05-03T00:10:34.633Z ERROR controller.provisioner launching machine, creating cloud provider instance, creating instance, getting launch template configs, getting launch templates, no amis exist given constraints {"commit": "beb0a64-dirty"}
Though this gives information to the user that no AMIs matched the instance types, it does not give any information on why the compatibility failure occurred. We should provide more verbose error logging in this console log so that the user gets more information on what they need to change in either their AMI selector or their diversity of instance types that are launched in their provisioner/pod combos.
A good place to start would be here, passing the errors back through the call from the failed compatibility checks across all AMIs: https://github.com/aws/karpenter/blob/main/pkg/providers/amifamily/resolver.go#L127
Tell us about the problem you’re trying to solve. What are you trying to do, and why is it hard?
N/A
Are you currently working around this issue?
N/A
Additional Context
No response
Attachments
No response
Community Note
- Please vote on this issue by adding a 👍 reaction 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
About this issue
- Original URL
- State: closed
- Created a year ago
- Reactions: 3
- Comments: 19 (8 by maintainers)
would like to work on this if no one else has already picked it up
yes will do let me update the pr for the same
I would say getting to know the attempted launch instance would make it easier to debug. but as you mentioned before the no of instances are too high so printing only a subset of it makes sense.
@jonathan-innis made a draft pr for the same do have a look
@srinchow Assigned