I am using "runas" to open command prompt as a different user but that command prompt is not running as an admin. How can I make it run as an admin?
UPDATE: I am using Windows Server 2012
UPDATE: I opened cmd for another account by running
runas /user:domain\username cmd.exe
Then I tried to run some commands in this new prompt but this is not running as an elevated user (even though it has Administrator privileges).
Summary. A Windows user can run a program or application as a different user. To do this, the user selects the Run as different user context menu command (or uses the Runas.exe command-line tool), and then specifies the credentials of an alternate account.
See here: https://superuser.com/questions/42537/is-there-any-sudo-command-for-windows
According to that the command looks like this for admin:
runas /noprofile /user:Administrator cmd
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With