简体   繁体   中英

BACKUP_FAILED web deploy IIS remote server. Publishing failed. Web deployment task failed. Illegal characters in path

How can I get backup to work before deploy.

Windows Server 2008 R2 Standard

Local Machine Windows 10 Visual Studio Pro 2017

I can publish site. But backup does not work.

An error occurred when the request was processed on the remote computer.
Illegal characters in path.
   at Microsoft.Web.Deployment.BackupManager.HandleExceptionForBackupFailure(DeploymentBaseContext baseContext, BackupSettings settings, Exception ex, Boolean suppressLogging)

   at Microsoft.Web.Deployment.BackupRuleHandler.PreSync(DeploymentSyncContext syncContext)

   at Microsoft.Web.Deployment.DeploymentSyncContext.ProcessSync(DeploymentObject destinationObject, DeploymentObject sourceObject)
   at Microsoft.Web.Deployment.DeploymentObject.SyncToInternal(DeploymentObject destObject, DeploymentSyncOptions syncOptions, PayloadTable payloadTable, ContentRootTable contentRootTable, Nullable`1 syncPassId, String syncSessionId)
   at Microsoft.Web.Deployment.DeploymentAgent.HandleSync(DeploymentAgentAsyncData asyncData, Nullable`1 passId, String user, String siteName)
   at Microsoft.Web.Deployment.StatusThreadHandler.CheckForException()
   at Microsoft.Web.Deployment.AgentClientProvider.RemoteDestSync(DeploymentObject sourceObject, DeploymentSyncContext syncContext, Nullable`1 syncPass, String syncSessionId)
   at Microsoft.Web.Deployment.DeploymentObject.SyncToInternal(DeploymentObject destObject, DeploymentSyncOptions syncOptions, PayloadTable payloadTable, ContentRootTable contentRootTable, Nullable`1 syncPassId, String syncSessionId)
   at Microsoft.Web.Deployment.DeploymentObject.SyncTo(DeploymentProviderOptions providerOptions, DeploymentBaseOptions baseOptions, DeploymentSyncOptions syncOptions)
   at CallSite.Target(Closure , CallSite , Object , Object , Object , Object )
   at System.Dynamic.UpdateDelegates.UpdateAndExecuteVoid4[T0,T1,T2,T3](CallSite site, T0 arg0, T1 arg1, T2 arg2, T3 arg3)
   at Microsoft.Web.Publishing.Tasks.VSMSDeployObject.SyncTo(VSMSDeployObject destObject, Object syncOptions, IVSMSDeployHost _host)
   at CallSite.Target(Closure , CallSite , VSMSDeployObject , VSMSDeployObject , Object , IVSMSDeployHost )
   at System.Dynamic.UpdateDelegates.UpdateAndExecuteVoid4[T0,T1,T2,T3](CallSite site, T0 arg0, T1 arg1, T2 arg2, T3 arg3)
   at Microsoft.Web.Publishing.Tasks.BaseMSDeployDriver.InvokeMSdeploySync()
   at Microsoft.Web.Publishing.Tasks.VSMSDeployDriverInCmd.StartSync()
   at Microsoft.Web.Publishing.Tasks.BaseMSDeployDriver.SyncThruMSDeploy()
   at Microsoft.Web.Publishing.Tasks.VSMSDeploy.Execute()
        VSMSDeploy: Publish failed to deploy.
        Output Property: _PublishResult=False
        Done executing task "VSMSDeploy" -- FAILED.

The error was Notepad++ kept a wierd copy of the file C:\\Windows\\System32\\inetsrv\\config\\applicationHost.config on the server.

Opened it in regular notepad, and saw other content and fixed it: (Probably has something to do with the system file is locked etc)

<location path="www.xxxxx.com">
        <system.webServer>
            <security>
                <access sslFlags="Ssl" />
            </security>
            <wdeploy>
                <backup enabled="true" backupPath="E:\temp" continueSyncOnBackupFailure="false" />
            </wdeploy>
        </system.webServer>

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM