Take the 2-minute tour ×
SharePoint Stack Exchange is a question and answer site for SharePoint enthusiasts. It's 100% free, no registration required.

I am quite new to windows powershell. I have tried to run the following command "stsadm -o setadminport. I get the error that the Term stsadm is not a recognized cmdlet, function etc. My reading tells me I need to change the path. I'm not sure how to do that. Powershell opens to c:\Documents and Settings\Administrator.bma> The stsadm.exe file is in c:\program files\commonfiles\microsoft shared\web server extension\12\BIN I would sure appreciate some help on the steps to get this path configured so I can run the command. thanks,

share|improve this question

3 Answers 3

PowerShell is the replacement for stsadm. If you need to use stsadm, which is located at c:\program files\commonfiles\microsoft shared\web server extension\12\BIN, use a standard cmd window not PowerShell to execture your commands.

share|improve this answer

Hey, you can add the stsadm path to the system enviornment variables the same way you woud for the old command prompt. You need to right click on your Computer, go into advanced settings, and then click the Enviornment Variables button. Just add the path to stsadm to the path. Use a semi colon ; to delimit the values. This works for both power shell and cmd.

share|improve this answer

stsadm was the sp 2007 way, although it still comes with sp 2010. The new way (2010+) is powershell. Although you can do most everything with just powershell, there is a way to use powershell to run stsadm. Check out this excellent tutorial complete with screenshots. It shows you how to create an alias for stsadm so you can use its commands too.

Also note, that if you have sp 2010, your stsadm will be here, instead (notice the 14 instead of the 12): C:\Program Files\Common Files\Microsoft Shared\Web Server Extensions\14\BIN\STSADM.EXE

share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.