Solved

How to automate a shell with admin privs.

Posted on 2007-04-09
10
444 Views
Last Modified: 2010-05-18
In Microsoft Vista, the UAC is rapidly becoming a real PITA. In order for me to issue the command 'netsh int tcp set globalautotuninglevel=disabled' I must drill down to \windows\system32 folder, highlight cmd.exe, and right click on it to switch over to the admin security token, all just so I can run the batch file with the netsh command in it. Does anyone out there know of a command line argument I may employ in a .bat file to automate this process. It needs to be done each time I boot the Vista box so that my Wireless USB NIC will run for more than a minute without turning off the tcp stack, necessitating yet another reboot. Gotta love that UAC thingy. Any other method I may employ to automate this task will also be greatly appreciated.
0
Comment
Question by:Cameron Rowe
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
10 Comments
 
LVL 30

Expert Comment

by:SteveGTR
ID: 18878513
You can always fallback to the runas command.
0
 
LVL 30

Accepted Solution

by:
SteveGTR earned 32 total points
ID: 18878516
0
 
LVL 11

Assisted Solution

by:JamesCssl
JamesCssl earned 31 total points
ID: 18878601
press in sequence:
Winkey
cmd
Ctrl+shift+enter
Alt+c

You now have a command prompt with admin token
0
Independent Software Vendors: We Want Your Opinion

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

 
LVL 15

Assisted Solution

by:Ryan_R
Ryan_R earned 31 total points
ID: 18879050
can't remember exactly which option I used, but there's one in TweakVI that allows me to automatically run everything with the highest Admin priveleges without me using a RunAs command, etc

eg - If i go start, type   cmd   and hit enter it says 'Administrator: C:\Windows\system32\cmd.exe'

do a google on TweakVI and download the free basic version as the option is included in there somewhere (with other good tweaks)
0
 
LVL 1

Assisted Solution

by:source2k3
source2k3 earned 31 total points
ID: 18880663
If you're looking for fast, fastest thing is clicking the windows button on your keyboard, typing pro which will make command prompt appear on the list.  Right click and choose "run as administrator" this will ensure you're running the command as admin.

I personally not only turned UAC off globally but I use the Administrator account as my main account.
0
 
LVL 4

Expert Comment

by:Caudax
ID: 18884322
>>I personally not only turned UAC off globally but I use the Administrator account as my main account.

Any *nix user would lambast you for doing this.
0
 
LVL 15

Expert Comment

by:Ryan_R
ID: 18887515
source2k3 - I think you should try out TweakVI as well - that way you wouldn't have to use the local Admin account
0
 

Author Comment

by:Cameron Rowe
ID: 18921797
"I personally not only turned UAC off globally but I use the Administrator account as my main account."
While this doubtless is convenient it is also somewhat akin to using the front sight on your pistol to scratch your bum, in that should doing so result in a corrupted profile you had better hope you have at least one more local profile with admin privs already in place on the machine. Caudax is right.
0

Featured Post

Easy, flexible multimedia distribution & control

Coming soon!  Ideal for large-scale A/V applications, ATEN's VM3200 Modular Matrix Switch is an all-in-one solution that simplifies video wall integration. Easily customize display layouts to see what you want, how you want it in 4k.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

An article on effective troubleshooting
No single Antivirus application (despite claims by manufacturers) will catch or protect you from all Virus / Malware or Spyware threats. That doesn't stop you from further protecting yourself however - and this article is to show you how.
The viewer will learn how to successfully create a multiboot device using the SARDU utility on Windows 7. Start the SARDU utility: Change the image directory to wherever you store your ISOs, this will prevent you from having 2 copies of an ISO wit…
Finding and deleting duplicate (picture) files can be a time consuming task. My wife and I, our three kids and their families all share one dilemma: Managing our pictures. Between desktops, laptops, phones, tablets, and cameras; over the last decade…

752 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question