Runas Error: Unable to Acquire Password
Asked Answered
D

3

19

I'm trying to start visual studio 2010 from command prompt using 'RUNAS' so that I can run it as a different user. I ran the following command:

runas /profile /user:myPCName/SomeUserName "C:\Program Files (x86)\Microsoft Visual Studio 10.0\Common7\IDE\devenv.exe"

My problem is that the commandprompt says "Enter the password for myPCName/SomeUserName:" but I cannot enter the password. I just get the error "RUNAS ERROR: Unable to acquire user password"

I googled this for a while and the only answer I found was that I cannot see the password entered, but it is entered anyways, and that I must be typing the wrong password. I'm certain I'm not typing the wrong password.

Durazzo answered 18/5, 2010 at 16:42 Comment(0)
A
9

There are so many things your forgot to document:

  • what is your logon provider? Are you attached to a domain?
  • are your running this from a UAC elevated command prompt?
  • what does the real user name look like? Is it a system account?
  • does the user account actually exist on your machine?
  • can you logout and logon as that user from your machine?
  • does that also work when you disconnect from the network?
  • do you actually type this command or is it called from a .bat or script?
  • "cannot enter the password", you can't type it or it doesn't like what you typed?

Serverfault.com is a good place to ask about user authentication.

Aeciospore answered 18/5, 2010 at 18:33 Comment(3)
Wow, you are right that I need to document all of that. I will document it and then post the question on serverfault.com. Thanks!Durazzo
I am SO stupid! While I was doing the testing you recommended, I noticed that my syntax was incorrect. I used a "/" in the username instead of a "\" between the domain and username.Durazzo
John's tip solved this for me. So easy to use the wrong slash since the command's flags use /, while the domain\user specification needs \. Thanks.Faultless
E
24

Actually, I had the same problem with W7 Enterprise (connected to a domain, switching to a locally defined admin user) without UAC elevation with the command:

runas /user:.\admin cmd.exe

It did prompt me for the password.

It also worked when I changed it explicitly to:

runas /user:%COMPUTERNAME%\admin cmd.exe

Ewan answered 13/4, 2013 at 23:44 Comment(2)
Also worked if don't specify "domain". runas /user:admin cmd.exeDouche
Had the same issue using .\admin, also works to use localhost\admin.Palomino
A
9

There are so many things your forgot to document:

  • what is your logon provider? Are you attached to a domain?
  • are your running this from a UAC elevated command prompt?
  • what does the real user name look like? Is it a system account?
  • does the user account actually exist on your machine?
  • can you logout and logon as that user from your machine?
  • does that also work when you disconnect from the network?
  • do you actually type this command or is it called from a .bat or script?
  • "cannot enter the password", you can't type it or it doesn't like what you typed?

Serverfault.com is a good place to ask about user authentication.

Aeciospore answered 18/5, 2010 at 18:33 Comment(3)
Wow, you are right that I need to document all of that. I will document it and then post the question on serverfault.com. Thanks!Durazzo
I am SO stupid! While I was doing the testing you recommended, I noticed that my syntax was incorrect. I used a "/" in the username instead of a "\" between the domain and username.Durazzo
John's tip solved this for me. So easy to use the wrong slash since the command's flags use /, while the domain\user specification needs \. Thanks.Faultless
A
7

I just had this issue.

runas /username:domain/user cmd failed

but

runas /username:domain\user cmd worked.

So give your slashes a check.

Abject answered 22/7, 2019 at 0:12 Comment(0)

© 2022 - 2024 — McMap. All rights reserved.