microsoft/SDN

Cannot make Network Controller backup with New-NetworkControllerBackup

petkodeivn opened this issue · 0 comments

Win 2019 Server with SDN and a single node NC install, ApplicationTypeVersion : 12.0.26.0; running the command as per https://docs.microsoft.com/en-us/windows-server/networking/sdn/manage/update-backup-restore

$Backup = New-NetworkControllerBackup -ConnectionURI $URI -Credential $Credential -Properties $BackupProperties
-ResourceId $BackupTime -Force

results is:

New-NetworkControllerBackup : Terminating error was thrown while executing
'C:\Windows\system32\WindowsPowerShell\v1.0\Modules\NetworkController\Microsoft.NetworkController.Powershell.dll'
operation on the server side endpoint
'https://nce-ncvm01.dswe.local/networking/V3/networkcontrollerbackup/2021-01-20T00_01_46'.
At line:1 char:11
+ $Backup = New-NetworkControllerBackup -ConnectionURI $URI -Credential ...
+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+ CategoryInfo : InvalidOperation: (https://nce-ncv...-01-20T00_01_46:String) [New-NetworkControllerBackup], InvalidOperationException
+ FullyQualifiedErrorId : ODataEndpointProxyInvokeFailure,New-NetworkControllerBackup

In NetworkController-SDNAPIEvents/Admin event log the message is:

The following information was included with the event:

Request: PUT https://nce-ncvm01.dswe.local/networking/V3/networkcontrollerbackup/2021-01-20T00_01_46
Connection: Keep-Alive
Host: nce-ncvm01.dswe.local
User-Agent: Mozilla/5.0,(Windows NT; Windows NT 10.0; en-US),WindowsPowerShell/5.1.17763.1490
Content-Length: 514
Content-Type: application/json; charset=utf-8

{"ResourceId":"2021-01-20T00_01_46","ResourceId:Key":"2021-01-20T00_01_46","Properties":{"BackupPath":"\\storage.dswe.local\tfs_bkp\2021-01-20T00_01_46","Credential":{"ResourceRef":"/credentials/BackupUser","InstanceId":"369244e2-386d-4234-8e19-10cfc85be772","Etag":"W/"3e3d01b5-010c-4c20-a009-0a6b33f7994b"","ResourceId":"BackupUser","Properties":{"Type":"usernamePassword","UserName":"dswe\domainAdmin1","Value":"jrrqgJFghjktGh+LZ7ItPJw/RfgTyjkkL2woA=","ProvisioningState":"Succeeded","Networks":[]}}}}
Response: x-ms-request-id: fdf16b43-5a94-475c-ba44-b6024664f722
Content-Type: application/json; charset=utf-8

{
"error": {
"code": "AnotherOperationInProgress",
"message": "Another operation on this or dependent resource is in progress. To retrieve status of the operation use uri: .",
"innerError": "Microsoft.WindowsAzure.Networking.Nrp.Frontend.Common.NrpException: Another operation on this or dependent resource is in progress. To retrieve status of the operation use uri: .\r\n at Microsoft.WindowsAzure.Networking.Nrp.Frontend.Operations.OperationBase1.ThrowAnotherOperationInProgress(IOperation inprogressOperation)\r\n at Microsoft.Windows.Networking.NetworkController.Framework.Operations.PutNetworkControllerBackupOperation.ExecuteInternal(NetworkControllerBackup resource, ITransaction transaction)\r\n at Microsoft.Windows.Networking.NetworkController.RestApi.Common.Operations.PutResourceDefaultOperation1.DefaultExecuteTopLevelResource()\r\n at Microsoft.Windows.Networking.NetworkController.RestApi.Common.Operations.PutResourceDefaultOperation1.Execute()\r\n at Microsoft.WindowsAzure.Networking.Nrp.Frontend.Operations.OperationBase1.Run()"
}
}
HttpStatusCode: Conflict

It looks like the auto-backup also stopped working as on https://nce-ncvm01.dswe.local/networking/V3/networkcontrollerbackup/ the last entry by date is

{
      "resourceRef": "/networkControllerBackup/AutoBackup_2020-02-13T03-38-40",
      "resourceId": "AutoBackup_2020-02-13T03-38-40",
      "etag": "W/\"821b14c6-92bb-4d97-8444-b7c235d825b3\"",
      "instanceId": "379c34f7-cf1e-4de1-aa63-c44f4af0966a",
      "properties": {
        "provisioningState": "Updating",
        "backupPath": "C:\\Windows\\tracing\\SDNDiagnostics\\AutoBackups\\AutoBackup_2020-02-13T03-38-40",
        "errorMessage": ""
      }
    }

Tried running below command but it failed with the same error:

Invoke-WebRequest -Method Delete -Uri https://nce-ncvm01.dswe.local/networking/V3/networkcontrollerbackup/AutoBackup_2020-02-13T03-38-40

Invoke-WebRequest : { "error": { "code": "AnotherOperationInProgress", "message": "Another operation on this or
dependent resource is in progress. To retrieve status of the operation use uri: .", "innerError":
"Microsoft.WindowsAzure.Networking.Nrp.Frontend.Common.NrpException: Another operation on this or dependent resource
is in progress. To retrieve status of the operation use uri: .\r\n at

Any tips or hints as to where the problem might be are highly welcomed. I can provide more info on our SND deployment if needed. Thanks.