安装网络驱动器在 DOS 中可以工作,但在 Cygwin 中会中断。为什么?

发布于 2024-12-19 19:03:10 字数 556 浏览 4 评论 0原文

我正在使用 VirtualBox 来设置 Windows 2008 服务器。我想添加共享文件夹,但遇到问题。

在 DOS 中运行它有效:

net use t: \\vboxsrv\v-root

但在 Cygwin 中:

$ net use t: "\\vboxsrv\v-root"
System error 53 has occurred.

The network path was not found.

我也尝试过这些:

$ net use t: \\vboxsrv\v-root
$ net use t: \\\\vboxsrv\\v-root

我尝试创建一个包含工作 DOS 命令的 bat 脚本,并从 cygwin 执行它。它们都因相同的错误而失败。

我需要通过Cygwin来完成,因为我通过SSH访问系统,并登陆Cygwin环境。如果有任何方法可以暂时从 Cygwin 内部“突破”cygwin,那可能是一种方法..

我错过了什么?

I'm using VirtualBox to set up a windows 2008 server. I'd like to add a shared folder, but am running into problems.

Running this in DOS works:

net use t: \\vboxsrv\v-root

But in Cygwin:

$ net use t: "\\vboxsrv\v-root"
System error 53 has occurred.

The network path was not found.

I've also tried these:

$ net use t: \\vboxsrv\v-root
$ net use t: \\\\vboxsrv\\v-root

And I've tried creating a bat script containing the working DOS command, and executing it from cygwin. They all fail with the same error.

I need to do it through Cygwin, because I access the system via SSH, and land in a Cygwin environment. If there is any way to "break out" of cygwin temporarily from within Cygwin, that might be a way to go..

What am I missing?

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

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

发布评论

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

评论(3

遗忘曾经 2024-12-26 19:03:10

在某处创建一个文件夹,例如:

gt; mkdir -p /mnt/t

现在您可以在 cygwin 中使用挂载程序,如下所示:

gt; mount \\vboxsrv\v-root /mnt/t

Easy as 1,2,3 :-)

Create a folder somewhere, like:

gt; mkdir -p /mnt/t

Now you can us the mount program in cygwin, like so:

gt; mount \\vboxsrv\v-root /mnt/t

Easy as 1,2,3 :-)

错爱 2024-12-26 19:03:10

Windows 根路径通常位于 /cygdrive/ 下。尝试类似的东西

$ net use t: /cygdrive/c/vboxsrv/v-root

The Windows root path is typically found somehwere under /cygdrive/. Try something like

$ net use t: /cygdrive/c/vboxsrv/v-root
梦忆晨望 2024-12-26 19:03:10

对于此错误,

!)使用“sudo chmod 777 -R /home/username/Shared”授予主机端共享文件夹的完全权限(Shared 是文件夹名称,我们必须共享。)

!!)在访问共享文件夹之前,在 Virtualbox 中打开 Guest。:从菜单中选择“安装 Guest Additions

!!!)单击开始,右键点击计算机,选择“映射网络驱动器

!V) 在其中选择任何驱动器,然后在该类型文件夹“\Yourhostipaddress\Shared”下。下面选择“使用凭据连接”(Yourhostipaddress 是主机 IP 地址,共享 是主机端的共享文件夹名称。)

V) 单击“连接”按钮。它会询问您主机用户名和密码。

 Put **USERNAME** Properly like "**XXXXXXXX-PC**".

V!) 它将成功映射共享驱动器!!!!!!!!!!!!!!!

如果仍然出现错误,请在下面添加评论。

For this error,

!) Give full rights to Shared folder at Host side using "sudo chmod 777 -R /home/username/Shared" (Shared is a folder name which we have to be shared.)

!!) Open Guest in Virtualbox, before accessing shared folder.: "Install Guest Additions" From Menu

!!!) Click START, Right click on Computer , Select "Map Network Drive"

!V) In that select any drive and bellow that type folder "\Yourhostipaddress\Shared". Bellow that select "connect with credential" (Yourhostipaddress is a HOST IP ADDRESS and Shared is Shared folder name at host side. )

V) Click On connect button. It will ask you host username and password.

 Put **USERNAME** Properly like "**XXXXXXXX-PC**".

V!) It will map with shared drive successfully !!!!!!!!!!!!!!!!

If still getting error, Put comments bellow this.

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