Azure / pcs-cli

A CLI for deploying Azure IoT PCS
MIT License
33 stars 37 forks source link

RM deployment error because ASA job failed to start. #520

Closed sakimsft closed 3 years ago

sakimsft commented 5 years ago

Type of issue

Description

While deploying RM, ASA job failed to start. This is intermittent issue and can be resolved by starting ASA job manually or redeploying RM. This ticket is created for proper fix.

{ "sdsStatus": "Failure provisioning solution: Remote Monitoring", "solutionId": "remote-monitoring", "provisioningStep": "15: Starting streaming job", "statusCode": "", "failureDetails": "The operation to start the Stream Analytics job timed out, please retry later\nLast error message:\nBadRequest: Stream Analytics job has validation errors: Error connecting to Cosmos DB Database: Message: {\"Errors\":[\"Owner resource does not exist\"]}\r\nActivityId: 3e166184-0f54-4d19-aa52-e420a309a2ee, Request URI: /apps/04b55d7c-9aae-41e1-8313-a1aad0fe0caa/services/836b7029-e7ea-4cd0-b3b2-e3d78a11a384/partitions/de9faf21-509a-4e34-bf6b-4ea5e4f63cc8/replicas/132058993789822963s//dbs/pcs-iothub-stream/colls, RequestStats: \r\nRequestStartTime: 2019-07-12T04:08:40.8671234Z, Number of regions attempted: 1\r\nResponseTime: 2019-07-12T04:08:40.8827726Z, StoreReadResult: StorePhysicalAddress: https://byaprdapp05-docdb-3.documents.azure.com:12213/apps/04b55d7c-9aae-41e1-8313-a1aad0fe0caa/services/836b7029-e7ea-4cd0-b3b2-e3d78a11a384/partitions/de9faf21-509a-4e34-bf6b-4ea5e4f63cc8/replicas/132058993789822963s//dbs/pcs-iothub-stream/colls, LSN: 3, GlobalCommittedLsn: 3, PartitionKeyRangeId: , IsValid: True, StatusCode: 404, IsGone: False, IsNotFound: True, IsInvalidPartition: False, RequestCharge: 0, ItemLSN: -1, SessionToken: , ResourceType: Collection, OperationType: Query\r\nResponseTime: 2019-07-12T04:08:40.8827726Z, StoreReadResult: StorePhysicalAddress: https://byaprdapp05-docdb-3.documents.azure.com:12214/apps/04b55d7c-9aae-41e1-8313-a1aad0fe0caa/services/836b7029-e7ea-4cd0-b3b2-e3d78a11a384/partitions/de9faf21-509a-4e34-bf6b-4ea5e4f63cc8/replicas/132071356529882791s//dbs/pcs-iothub-stream/colls, LSN: 3, GlobalCommittedLsn: 3, PartitionKeyRangeId: , IsValid: True, StatusCode: 404, IsGone: False, IsNotFound: True, IsInvalidPartition: False, RequestCharge: 0, ItemLSN: -1, SessionToken: , ResourceType: Collection, OperationType: Query\r\n, SDK: documentdb-dotnet-sdk/2.1.3 Host/64-bit MicrosoftWindowsNT/6.2.9200.0.\r\n", "sdsTask": "Provisioning", "sdsDeploymentId": "56519340-828e-49e4-9a74-068a8d25e65c", "subscriptionId": "1151f379-76cc-46d0-8594-c39b11c32621", "azureLocation": "West US", "resourceGroup": "contonso-rm", "utcTimestamp": "2019-07-12T04:08:47.9135382Z" }

Steps to reproduce

Deploy RM.

Expected behavior

No error

Current behavior <!-- The actual behavior observed --

ASA job failed to start since cosmos DB is not ready.

Known workarounds

Start ASA job manually.

Possible solution

Context and Environment