英文:
Sqlpackage.exe stucks on initialization
问题
使用sqlpackage.exe进行Synapse部署,版本为162.0.52.1。
在初始化过程中,它卡在这一步:
英文:
Am using sqlpackage.exe for synapse deployment, version 162.0.52.1.
During the initialization, it stucks at this step:
答案1
得分: 0
我尝试将Dacpac文件发布到Azure SQL,并通过sql.exe包和SqlAzureDacpacDeployment运行Yaml管道成功:
我在我的代理中安装了microsoft.sqlpackage,然后检查了SQL包的版本,然后我运行了sql.exe命令来发布dacpac文件到Azure SQL。您可以将我的sql.exe命令替换为您自己的。我还运行了单独的SQLAzureDacpacDeployment任务。请参考以下内容:
我的代码库:
YAML脚本:
trigger:
- master
pool:
vmImage: windows-latest
steps:
- script: echo Hello, world!
displayName: '运行一行脚本'
- task: Bash@3
inputs:
targetType: 'inline'
script: 'dotnet tool install -g microsoft.sqlpackage'
- script: SqlPackage /version
workingDirectory: $(System.DefaultWorkingDirectory)
displayName: '获取sqlpackage版本'
- script: sqlpackage.exe /action:Publish /SourceFile:"$(System.DefaultWorkingDirectory)/Database1.dacpac" /TargetServerName:"xxxxnserver.database.windows.net,1433" /TargetDatabaseName:"username" /TargetUser:"CloudSAbe337ad4" /TargetPassword:"Password"
workingDirectory: $(System.DefaultWorkingDirectory)
displayName: '运行sqlpackage命令'
- task: SqlAzureDacpacDeployment@1
inputs:
azureSubscription: 'devopsappsilicon'
AuthenticationType: 'server'
ServerName: 'xxxxserver.database.windows.net'
DatabaseName: 'silicondb'
SqlUsername: 'username'
SqlPassword: 'Password'
deployType: 'DacpacTask'
DeploymentAction: 'Publish'
DacpacFile: '$(System.DefaultWorkingDirectory)/Database1.dacpac'
IpDetectionMethod: 'IPAddressRange'
StartIpAddress: '0.0.0.0'
EndIpAddress: '255.255.255.255'
参考链接:
SqlPackage for Azure Synapse Analytics - SQL Server | Microsoft Learn
SqlPackage in development pipelines - SQL Server | Microsoft Learn
英文:
I tried publishing Dacpac File to Azure SQL and via sql.exe package and SqlAzureDacpacDeployment the Yaml pipeline ran successfully:-
I installed microsoft.sqlpackage in my agent and then checked the SQL package version, Then I ran sql.exe command to publish the dacpac file into Azure SQL. You can replace my sql.exe command below with yours. I also ran separate SQLAzureDacpacDeployment task. Refer below:-
My repository:-
YAML Script:-
trigger:
- master
pool:
vmImage: windows-latest
steps:
- script: echo Hello, world!
displayName: 'Run a one-line script'
- task: Bash@3
inputs:
targetType: 'inline'
script: 'dotnet tool install -g microsoft.sqlpackage'
- script: SqlPackage /version
workingDirectory: $(System.DefaultWorkingDirectory)
displayName: 'get sqlpackage version'
- script: sqlpackage.exe /action:Publish /SourceFile:"$(System.DefaultWorkingDirectory)/Database1.dacpac" /TargetServerName:"xxxxnserver.database.windows.net,1433" /TargetDatabaseName:"username" /TargetUser:"CloudSAbe337ad4" /TargetPassword:"Password"
workingDirectory: $(System.DefaultWorkingDirectory)
displayName: 'get sqlpackage version'
- task: SqlAzureDacpacDeployment@1
inputs:
azureSubscription: 'devopsappsilicon'
AuthenticationType: 'server'
ServerName: 'xxxxserver.database.windows.net'
DatabaseName: 'silicondb'
SqlUsername: 'username'
SqlPassword: 'Password'
deployType: 'DacpacTask'
DeploymentAction: 'Publish'
DacpacFile: '$(System.DefaultWorkingDirectory)/Database1.dacpac'
IpDetectionMethod: 'IPAddressRange'
StartIpAddress: '0.0.0.0'
EndIpAddress: '255.255.255.255'
References:-
SqlPackage for Azure Synapse Analytics - SQL Server | Microsoft Learn
SqlPackage in development pipelines - SQL Server | Microsoft Learn
答案2
得分: 0
There were to less RAM on agent for the schema comparison there.
SQLPackage.exe的模式比较步骤将RAM利用率从3GB增加到14GB:
在这种情况下,使用了Azure DevOps代理进行执行。默认情况下,托管代理只有7GB可用的RAM:
链接:https://learn.microsoft.com/en-us/azure/devops/pipelines/agents/hosted?view=azure-devops&tabs=yaml#hardware
通过集体智慧和协作来改善编程学习和解决问题的方式。致力于成为全球开发者共同参与的知识库,让每个人都能够通过互相帮助和分享经验来进步。
评论