Azure Data Studio:无法还原SQL Server数据库 - 访问被拒绝

发布于 2025-01-29 07:20:57 字数 212 浏览 2 评论 0 原文

我正在将数据库从一台服务器迁移到另一台服务器。当我尝试在Docker中选择备份文件( .bak )时,我会收到“访问拒绝”错误。如何向Docker容器提供访问权限?

在此处输入图像描述

I'm in the process of migrating the database from one server to another. When I try to select the backup file (.bak) within Docker, I'm getting an 'Access Denied' error. How to provide access permission to the Docker container?

enter image description here

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(1

寻梦旅人 2025-02-05 07:20:57

我遇到了相同的错误,我得出的结论是,问题是该文件不应以其应有的格式,因为我使用GUI远程访问Linux服务器,所以我刚刚从该文件中复制了.bak文件Windows Machine到Linux,我不建议将其重复的方法传输到另一个OS到另一个OS。我通过在Google Drive上发布.bak,然后生成我稍后在终端中输入的下载链接来解决问题。

要从Google Drive生成适当的链接,我建议以下指南:

当您在终端中获取链接类型时:
$ curl -l -l -o the_name.bak“ the_link”

用于还原数据库,请遵循本教程:

https://learn.microsoft.com/en-en-us/sql/sql/linux/linux/tutorial-restore-restore-restore-backup-in-sql--sql--sql----------服务器范围?view = sql-server-ver16

I had the same error, and what I concluded is that the problem is the file is not in the format it should be, to be precise since I have remote access to my Linux server with GUI, I just copied the .bak file from the windows machine to Linux, which I repeat is not advised way to transfer files form one OS to another. I solved the problem by posting .bak on Google Drive and then generating a download link that I typed in the terminal later.

To generate a proper link from Google Drive I recommend the following guide:
https://bytesbin.com/skip-google-drive-virus-scan-warning-large-files/

When you get the link type in the terminal:
$ curl -L -o The_Name.bak "The_link"

For restoring the database follow this tutorial:

https://learn.microsoft.com/en-us/sql/linux/tutorial-restore-backup-in-sql-server-container?view=sql-server-ver16

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文