I am trying to manage an IIS7 installation remotely using the Microsoft.Web.Administration library.
I'm doing this in IronPython:
import Microsoft.Web.Administration
from Microsoft.Web.Administration import ServerManager
manager = ServerManager.OpenRemote("RemoteServerName")
for site in manager.Sites:
print "Site: %(site)s" % { 'site' : site.Name }
On the last line as it attempts to communicate with the remote server I get the following error:
Retrieving the COM class factory for remote component with CLSID {2B72133B-3F5B-4602-8952-803546CE3344} from machine devdealernetsvr failed due to the following error: 80070005.
My research into the error lead me to believe that I do not have the proper credentials against the remote machine and so I would like to impersonate a user that does.
I was hard pressed to find a way to do this with IronPython. Any help is much appreciated.