Question

I'm trying to sync an app pool from my local machine to a remote server using IIS Credentials

this is the command I run

msdeploy.exe 
          -verb:sync 
          -source:appPoolConfig='MyAppPool' 
          -dest:appPoolConfig,
                 computerName='https://remoteserver.com:8172/MSDeploy.axd',
                 userName='WebDeploy',
                 password='Pa$$word',
                 authtype='Basic',
                 includeAcls='False' 
          -enableLink:AppPoolExtension  
          -disableLink:CertificateExtension 
          -allowUntrusted 

but I keep getting

Error Code: ERROR_USER_UNAUTHORIZED
More Information: Connected to the remote computer ("dev.dash.exceptron.com") using the Web Management Service, but could not authorize. Make sure that you are using the correct user name and password, that the site you are connecting to exists, and that the credentials represent a user who has permissions to access the site.  Learn more at: http://go.microsoft.com/fwlink/?LinkId=221672#ERROR_USER_UNAUTHORIZED.
Error: The remote server returned an error: (401) Unauthorized.
Error count: 1.

I can sync existing sites just fine, but I can't create sites or app pools. I'm thinking it might have something to do with the fact that my user has a level of "Site", and app pool doesn't fit that level.

Was it helpful?

Solution

Found the problem, it seems like IIS credentials don't have permission do do many tasks, using authtype='NTLM' and a Windows username and password fixed the issue.

This link also seems useful, http://blog.scnetstudio.com/post/2011/01/08/How-to-Configure-Windows-Server-2008-R2-to-support-Web-Deploy-(for-Web-Matrix).aspx

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top