I have an EB application that is stuck with this error: Failed Environment update activity. Reason: Internal Failure. I can not abort anything and I cannot change any configuration.. I dont know what to do, because every thing I do, it says: Could not abort the current environment operation for environment-xxxxxx: Environment named environment-xxxx is in an invalid state for this operation. Must be pending deployment.

I want to destroy the application or remove everything to start again, but I cannot do that.

Does anyone know how to unlock this?

Thanks in advance!

  • I decided to remove every DB, load balancer, security group, S3 bucket related to this environment.. I don't know if it is ok, but I'm quite desperate.. At least, it is not consuming anything (apparently)
    – adiego73
    Nov 4, 2017 at 22:03

1 Answer 1


If you know how to fix the source of problem (for example: change application settings in Beanstalk Environment variables or deploy fixed version of your application), then:

  1. Go to page Auto Scaling Group, choose your region, find Auto Scaling Group by Beanstalk Environment ID (like e-abcd12345).
  2. In Details tab, push "edit", set Desired, Min and Max to 0. Remember previous settings.
  3. In Beanstalk page, wait for message like "Removed instances [i-xxx, i-yyy] from your environment."
  4. Change settings or deploy your application
  5. Return Autoscaling settings back.
  6. Be patient, it may took 5-10 minutes to change Beanstalk health to "Ok".
  • thanks.. you made my day Sep 17, 2019 at 10:50
  • This answer saved my job. ;) Thanks. Apr 4, 2021 at 18:12
  • 2
    I had this happen in my production environment, so setting desired capacity to 0 wasn't an option. Instead I terminated the new instance created by the deployment from the Monitoring tab, and then I followed your directions but set min and desired capacity the pre-deployment values. After about 8 minutes, EB recovered from the stuck state like you said it would. Thank you! Aug 31, 2021 at 21:09

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.