Thursday, November 19, 2009

Access STSADM.EXE From any Directory in a Command Prompt

Access STSADM.EXE From any Directory in a Command Prompt

STSADM.EXE the main administration utility for SharePoint, is a command line utility. You'll find it in c:\program files\common files\microsoft shared\web server extensions\12\bin . To run it, you have to actually be in that directory... but its itching to go to that path and then executing the command Instead, add the directory to the PATH environment variable so you can type STSADM.EXE from any directory on your system. To do this:

Start -> All Programs -> Control Panel -> System
On the Advanced tab, click the Environment Variables button.
Select the variable Path and click the Edit button.

Add the following to the end of the Variable value field (don't forget the semicolon... the Path environment variable is a semicolon delimited string of directories):;C:\Program Files\Common Files\Microsoft Shared\web server extensions\12\BIN
OK out of all the dialogs.
Next time your system restarts, you'll be able to type STSADM.EXE at a command prompt from any directory on your system.

1 comment: