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

vmware_host_active_directory: Problems with corner cases #59

Closed
mariolenz opened this issue Mar 17, 2020 · 2 comments · Fixed by #66
Closed

vmware_host_active_directory: Problems with corner cases #59

mariolenz opened this issue Mar 17, 2020 · 2 comments · Fixed by #66

Comments

@mariolenz
Copy link
Collaborator

mariolenz commented Mar 17, 2020

SUMMARY

When there's a problem with the domain membership of a host, the module always reports a change but doesn't do anything (lines 160ff).

We ran into this issue when we accidentally removed the computer account of an existing ESXi host. Our playbook reported changing the AD membership over and over again which was a bit weird. After all, after the first change I'd expect an OK on all later runs.

ISSUE TYPE
  • Bug Report
COMPONENT NAME

vmware_host_active_directory

ANSIBLE VERSION
ansible 2.9.6
  config file = None
  configured module search path = ['/root/.ansible/plugins/modules', '/usr/share/ansible/plugins/modules']
  ansible python module location = /usr/lib/python3.7/site-packages/ansible
  executable location = /usr/bin/ansible
  python version = 3.7.5 (default, Nov 14 2019, 00:43:46) [GCC 7.3.0]
CONFIGURATION
STEPS TO REPRODUCE

Join an ESXi host to AD, remove the computer account and run the task to join AD several times. It always reports changed but nothing happens.

EXPECTED RESULTS

I'm not sure... there are so many different problems that can occur (clientTrustBroken, inconsistentTrust, noServers, serverTrustBroken or even otherProblem or unknown) that it's probably impossible to deal with them. Maybe the module should simply fail in these cases with an appropriate error message. Something like "The ESXi host seems to be an AD member but reports an unkown problem". This would make it pretty obvious that manual troubleshooting is needed.

ACTUAL RESULTS

The module reports a change but doesn't do anything.

@goneri
Copy link
Member

goneri commented Mar 23, 2020

I agree with you @mariolenz. This should not happen.

@mariolenz
Copy link
Collaborator Author

I agree with you @mariolenz. This should not happen.

@goneri I've issued PR #66 to address this, maybe you can have a look and tell me what you think.

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

Successfully merging a pull request may close this issue.

2 participants