# become with runas  method not work on some of my machines

**URL:** <https://forum.ansible.com/t/become-with-runas-method-not-work-on-some-of-my-machines/35618>\
**Category:** Ansible Project\
**Tags:** windows, awx\
**Created:** [August 13, 2021, 12:44pm UTC](https://forum.ansible.com/t/become-with-runas-method-not-work-on-some-of-my-machines/35618 "2021-08-13T12:44:32Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![java\_ran](https://avatars.discourse-cdn.com/v4/letter/j/a9a28c/32.png) [@java\_ran](https://forum.ansible.com/u/java_ran)\
**Post date:** [August 13, 2021, 12:44pm UTC](https://forum.ansible.com/t/become-with-runas-method-not-work-on-some-of-my-machines/35618/1 "2021-08-13T12:44:32Z")

</div>

hi there,

I have a playbook which set runas as the become method, as I run it with AWX it wont work on some machine to run any task which has become set to yes. and it shows error as bellow. but if I comment “become\_method” or set it to “sudo”!!! even though I am on windows machine, it runs on both groups of my machine.

I checked the web method to activated secondary logon(as regarded to error 1326) on failed machine but it did not help.

Does anybody has an Idea? thank you in advance.

Ausnahme beim Aufrufen von “CreateProcessAsUser” mit 9 Argument(en): “Failed to logon .\developer ( **Der Benutzername oder das Kennwort ist falsch, Win32ErrorCode 1326 - 0x0000052E** )”

In Zeile:103 Zeichen:5

- $result = [Ansible.Become.BecomeUtil]::CreateProcessAsUser($usern …

- 

```auto

```

- CategoryInfo : NotSpecified: (🙂 , MethodInvocationException

- FullyQualifiedErrorId : Win32Exception

ScriptStackTrace:

bei , : Zeile 103

bei , : Zeile 137

bei , : Zeile 11

System.Management.Automation.MethodInvocationException: Ausnahme beim Aufrufen von “CreateProcessAsUser” mit 9 Argument(en): "Failed to logon .\developer (Der Benutzername oder das Kennwort is…

---

<div class="post-metadata">

**Author:** ![jborean](https://sea1.discourse-cdn.com/ansible/user_avatar/forum.ansible.com/jborean/32/1525_2.png) [@jborean](https://forum.ansible.com/u/jborean)\
**Post date:** [August 16, 2021, 7:04pm UTC](https://forum.ansible.com/t/become-with-runas-method-not-work-on-some-of-my-machines/35618/2 "2021-08-16T19:04:51Z")

</div>

The error represents ERROR\_LOGON\_FAILURE which according to [https://docs.microsoft.com/en-us/openspecs/windows\_protocols/ms-erref/18d8fbe8-a967-4f1c-ae50-99ca8e491d2d](https://docs.microsoft.com/en-us/openspecs/windows_protocols/ms-erref/18d8fbe8-a967-4f1c-ae50-99ca8e491d2d) means

> Logon failure: Unknown user name or bad password.

You will want to be 100% sure you have the correct username/password set for the become user/pass set. I see you are trying to log on as ‘.\developer’, try just ‘developer’ or ‘HOSTNAME\developer’.

---

<div class="post-metadata">

**Author:** ![java\_ran](https://avatars.discourse-cdn.com/v4/letter/j/a9a28c/32.png) [@java\_ran](https://forum.ansible.com/u/java_ran)\
**Post date:** [August 20, 2021, 3:48pm UTC](https://forum.ansible.com/t/become-with-runas-method-not-work-on-some-of-my-machines/35618/3 "2021-08-20T15:48:58Z")

</div>

Thanks for the reply,  
yes I am sure that the user and pass are correct. as with the same credential other machine work. I also tried with hostname\developer but no luck!
