我尝试在运行于 Ubuntu 16.04 LTS 的 SQL Server 2017 Web 版上运行 T-SQL 脚本以备份到 URL,并运行另一个脚本以还原到 URL,但没有成功。已成功创建凭据。
这是我尝试运行的 T-SQL for Backup 示例:
DECLARE @name varchar(100)
DECLARE @fileURL varchar(100)
SET @name = 'test-db'
SET @fileURL = 'https://mystorageaccountname.blob.core.windows.net/databases/test-db.BAK'
BACKUP DATABASE @name
TO URL = @fileURL
WITH CREDENTIAL = 'mycredential'
,COMPRESSION
,STATS = 5;
这是我在 MSSQL Management Studio 上遇到的错误:
Msg 3292, Level 16, State 6, Line 5
A failure occurred while attempting to execute Backup or Restore with a URL device specified. Consult the operating system error log for details.
Msg 3013, Level 16, State 1, Line 5
BACKUP DATABASE is terminating abnormally.
这是我在/var/log/syslog上遇到的错误:
#015VDI: "C:\binn\BackupToUrl.exe" "b" "p" "680074007400700073003A002F002F0073007700650065007400640061007400610062006100730065006200610063006B007500700073002E0062006C006F0062002E0063006F00720065002E00770069006E0064006F00770073002E006E00650074002F006400610074006100620061007300650073002F0068006300640061006D006F00620069006C0065002E00420041004B00" "73007700650065007400640061007400610062006100730065006200610063006B00750070007300" "01000000D08C9DDF0115D1118C7A00C04FC297EB010000008AB2169DF1DE3A45B5514DCCD09182C3000000001200000061007A007500720065006B006500790000001066000000010000200000008ECF1319A21E667E0E32E83135C57DFCAF4E3DFF2AABDA00E3E2D814B5C88D2E000000000E8000000002000020000000E9E64579DF38EA0E66886B8D454C4F4256A682A124E70D86EC0DA087112ECA0450000000F92ED8FD343DADDE9518C412CA5EAB188316B24A6A0B407CCEA9AE142A9DBC282085ABF133BFDF017A3AFA9CEB4C5039433D15FA47A64A1339F2D030ED3383C58F81A2C3634FA945B6B819F113AB22DF40000000E9CDF76A290F18299BBE99C273FCA31E4622334C645EBFE8C5AA9C4F68C1A323A2F0EED33B8F6E8D5922B5B78DE1F6DB456864A290689C98A3631EA3F62505D3" "NOFORMAT" "4D005300530051004C00530045005200560045005200" "" "DB" "68006300640061006D006F00620069006C006500" "NOTRACE"
#015BackupToUrl: couldn't load process Error Code: 80070002
#0152018-03-14 12:35:25.30 Backup Error: 3041, Severity: 16, State: 1.
#0152018-03-14 12:35:25.30 Backup BACKUP failed to complete the command BACKUP DATABASE hcdamobile. Check the backup application log for detailed messages.
你们以前有过这个问题吗?我是否需要安装任何其他软件包才能在 Linux 上运行 Backup to URL?