部署数据工厂 ARM 模板时出错
Error While deploying Data Factory ARM template
一直在将 ADFv2 ARM 模板部署到同一资源组中的另一个数据工厂,并且存储帐户也在同一 RG 中,当我部署时,我遇到了一些链接服务的错误。
我有链接服务来使用 Selfhosted-IR 连接我的计算机和本地数据库服务器,两者都失败了。
我正在为链接服务传递覆盖参数。
非常感谢任何帮助。
谢谢。
"error": {
"code": "BadRequest",
"message": "Failed to encrypt`` sub-resource payload {\r\n \"Id\": \"/subscriptions/xxxxxxxxx/resourceGroups/rgvs/providers/Microsoft.DataFactory/factories/TestADF/linkedservices/ConnOnPremComputer\",\r\n \"Name\": \"ConnOnPremComputer\",\r\n \"Properties\": {\r\n \"annotations\": [],\r\n \"type\": \"FileServer\",\r\n \"typeProperties\": {\r\n \"host\": \"****************\",\r\n \"userId\": \"************\",\r\n \"password\": \"*************\"\r\n },\r\n \"connectVia\": {\r\n \"referenceName\": \"OnPremToAzure\",\r\n \"type\": \"IntegrationRuntimeReference\"\r\n }\r\n }\r\n} and error is: Failed to encrypted linked service credentials on self-hosted IR 'OnPremToAzure', reason is: NotFound, error message is: No online instance..",
"target": "/subscriptions/xxxxxxxxxx/resourceGroups/rgvs/providers/Microsoft.DataFactory/factories/TestADF/linkedservices/ConnOnPremComputer",
"details": null
}
} undefined
2019-06-24T13:54:48.9695328Z ##[error]BadRequest: {
"error": {
"code": "BadRequest",
"message": "Failed to encrypt sub-resource payload {\r\n \"Id\": \"/subscriptions/xxxxxxxxx/resourceGroups/rgvs/providers/Microsoft.DataFactory/factories/balptestadf/linkedservices/ConnLocalHostBackOffice\",\r\n \"Name\": \"ConnLocalHostBackOffice\",\r\n \"Properties\": {\r\n \"parameters\": {\r\n \"Password\": {\r\n \"type\": \"String\",\r\n \"defaultValue\": \"Password@1234\"\r\n }\r\n },\r\n \"annotations\": [],\r\n \"type\": \"SqlServer\",\r\n \"typeProperties\": {\r\n \"connectionString\": \"***************\",\r\n \"userName\": \"***************\",\r\n \"password\": \"*****************\"\r\n },\r\n \"connectVia\": {\r\n \"referenceName\": \"OnPremToAzure\",\r\n \"type\": \"IntegrationRuntimeReference\"\r\n }\r\n }\r\n} and error is: Format of the initialization string does not conform to specification starting at index 0..",
"target": "/subscriptions/xxxxxxxxxxxx/resourceGroups/rgvs/providers/Microsoft.DataFactory/factories/testADF/linkedservices/ConnLocalHost",
"details": null
}
} undefined
出现此错误消息的原因有很多:
来自错误消息“无法在 self-hosted IR 'OnPremToAzure' 上加密链接服务凭证,原因是:NotFound,错误消息是:无在线实例
确保 self-hosted IR 在部署时在线。否则您可能会收到此错误消息,因为 self-hosted IR 将用于加密您的有效负载。
要在 on-premises self-hosted 集成 运行 时间,运行 New-AzDataFactoryV2LinkedServiceEncryptedCredential 上加密来自 JSON 负载的敏感数据,并传递JSON 负载。此 cmdlet 确保凭据使用 DPAPI 加密并存储在本地 self-hosted 集成 运行 时间节点上。包含对凭据的加密引用的输出负载可以重定向到另一个 JSON 文件(在本例中为 'encryptedLinkedService.json')。
New-AzDataFactoryV2LinkedServiceEncryptedCredential -DataFactoryName $dataFactoryName -ResourceGroupName $ResourceGroupName -Name "SqlServerLinkedService" -DefinitionFile ".\SQLServerLinkedService.json" > encryptedSQLServerLinkedService.json
详情请参考“Encrypt credentials for on-premise data stores in ADF”。
希望对您有所帮助。
一直在将 ADFv2 ARM 模板部署到同一资源组中的另一个数据工厂,并且存储帐户也在同一 RG 中,当我部署时,我遇到了一些链接服务的错误。
我有链接服务来使用 Selfhosted-IR 连接我的计算机和本地数据库服务器,两者都失败了。 我正在为链接服务传递覆盖参数。
非常感谢任何帮助。
谢谢。
"error": {
"code": "BadRequest",
"message": "Failed to encrypt`` sub-resource payload {\r\n \"Id\": \"/subscriptions/xxxxxxxxx/resourceGroups/rgvs/providers/Microsoft.DataFactory/factories/TestADF/linkedservices/ConnOnPremComputer\",\r\n \"Name\": \"ConnOnPremComputer\",\r\n \"Properties\": {\r\n \"annotations\": [],\r\n \"type\": \"FileServer\",\r\n \"typeProperties\": {\r\n \"host\": \"****************\",\r\n \"userId\": \"************\",\r\n \"password\": \"*************\"\r\n },\r\n \"connectVia\": {\r\n \"referenceName\": \"OnPremToAzure\",\r\n \"type\": \"IntegrationRuntimeReference\"\r\n }\r\n }\r\n} and error is: Failed to encrypted linked service credentials on self-hosted IR 'OnPremToAzure', reason is: NotFound, error message is: No online instance..",
"target": "/subscriptions/xxxxxxxxxx/resourceGroups/rgvs/providers/Microsoft.DataFactory/factories/TestADF/linkedservices/ConnOnPremComputer",
"details": null
}
} undefined
2019-06-24T13:54:48.9695328Z ##[error]BadRequest: {
"error": {
"code": "BadRequest",
"message": "Failed to encrypt sub-resource payload {\r\n \"Id\": \"/subscriptions/xxxxxxxxx/resourceGroups/rgvs/providers/Microsoft.DataFactory/factories/balptestadf/linkedservices/ConnLocalHostBackOffice\",\r\n \"Name\": \"ConnLocalHostBackOffice\",\r\n \"Properties\": {\r\n \"parameters\": {\r\n \"Password\": {\r\n \"type\": \"String\",\r\n \"defaultValue\": \"Password@1234\"\r\n }\r\n },\r\n \"annotations\": [],\r\n \"type\": \"SqlServer\",\r\n \"typeProperties\": {\r\n \"connectionString\": \"***************\",\r\n \"userName\": \"***************\",\r\n \"password\": \"*****************\"\r\n },\r\n \"connectVia\": {\r\n \"referenceName\": \"OnPremToAzure\",\r\n \"type\": \"IntegrationRuntimeReference\"\r\n }\r\n }\r\n} and error is: Format of the initialization string does not conform to specification starting at index 0..",
"target": "/subscriptions/xxxxxxxxxxxx/resourceGroups/rgvs/providers/Microsoft.DataFactory/factories/testADF/linkedservices/ConnLocalHost",
"details": null
}
} undefined
出现此错误消息的原因有很多:
来自错误消息“无法在 self-hosted IR 'OnPremToAzure' 上加密链接服务凭证,原因是:NotFound,错误消息是:无在线实例
确保 self-hosted IR 在部署时在线。否则您可能会收到此错误消息,因为 self-hosted IR 将用于加密您的有效负载。
要在 on-premises self-hosted 集成 运行 时间,运行 New-AzDataFactoryV2LinkedServiceEncryptedCredential 上加密来自 JSON 负载的敏感数据,并传递JSON 负载。此 cmdlet 确保凭据使用 DPAPI 加密并存储在本地 self-hosted 集成 运行 时间节点上。包含对凭据的加密引用的输出负载可以重定向到另一个 JSON 文件(在本例中为 'encryptedLinkedService.json')。
New-AzDataFactoryV2LinkedServiceEncryptedCredential -DataFactoryName $dataFactoryName -ResourceGroupName $ResourceGroupName -Name "SqlServerLinkedService" -DefinitionFile ".\SQLServerLinkedService.json" > encryptedSQLServerLinkedService.json
详情请参考“Encrypt credentials for on-premise data stores in ADF”。
希望对您有所帮助。