Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

terraform plan stuck in Refreshing State for more than 2 hours #21

Open
abdennour opened this issue Jul 21, 2020 · 7 comments
Open

terraform plan stuck in Refreshing State for more than 2 hours #21

abdennour opened this issue Jul 21, 2020 · 7 comments

Comments

@abdennour
Copy link

abdennour commented Jul 21, 2020

Steps to Reproduce :

  • Set export TF_LOG=TRACE which is the most verbose logging.
  • Run terraform plan ....
  • In the log, I got the root cause of the issue and it was :
dag/walk: vertex "module.kubernetes_apps.provider.helmfile (close)" is waiting for "module.kubernetes_apps.helmfile_release_set.metrics_server"

Workaround Fix :

  • Based on these logs, I identify the state which is the cause of the issue: module.kubernetes_apps.helmfile_release_set.metrics_server.

  • I deleted its state :

terraform state rm module.kubernetes_apps.helmfile_release_set.metrics_server
  • Now run terraform plan ... it works ... but after removing state.

Expected behaviour

The issue is fixed without deleting the state

@mumoshu
Copy link
Owner

mumoshu commented Jul 21, 2020

Would u mind sharing your tf and helmfile.yaml files?

@mumoshu
Copy link
Owner

mumoshu commented Jul 22, 2020

So, I spotted a potential deadlock in our code that may end up something like this when helmfile failed in any way(user error or connection error or etc).

c26ba83 should fix that, which is available in the master branch now.

I'll keep testing it myself. But it would also help much if you could give it a try, too! Thanks for reporting 👍

@mumoshu
Copy link
Owner

mumoshu commented Jul 23, 2020

@abdennour v0.3.4 should be the most stable release ever. I'd appreciate it if you could test it out!

@abdennour
Copy link
Author

Thank you @mumoshu ! I can see v0.3.5 release as well.

@mumoshu
Copy link
Owner

mumoshu commented Jul 28, 2020

@abdennour Stay tuned I'll cut v0.3.6 shortly with even more bug fixes :) I believe I began to understand how a custom terraform provider should/must be implemented so it will gradually stabilize.

@abdennour
Copy link
Author

Any news!

@roobscoob
Copy link

Hey! I'm experiencing a deadlock I believe to be similar in nature. Any word on fixes you mentioned above?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants