Server Fault is a question and answer site for system and network administrators. It's 100% free, no registration required.

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I log on service with user in one domain (DOMAINNAME\user). and I want to use nant script to stop application pool on other server.

and I got this error

Failed stopping application pool '***********' on ''.
Access is denied. (Exception from HRESULT: 0x80070005 (E_ACCESSDENIED))

I can stop it if i set this user to be admin on that server but i don't want to. anyone have any solution for this problem? Thank you.

share|improve this question

Not sure how you are doing the app pool manipulation in your nant script, but if you call msdeploy to do it, you can pass credentials into msdeploy of a user that has permission to stop the app pool.

share|improve this answer

Your Answer


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

Not the answer you're looking for? Browse other questions tagged or ask your own question.