XCOPY与远程计算机上的凭据 [英] xcopy with credentials on remote machine

查看:645
本文介绍了XCOPY与远程计算机上的凭据的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我试图通过其IP地址不同的域名访问远程服务器。在运行命令我输入了以下

I am trying to access a remote server on a different domain through its IP address. In run command I entered the following

\\XXX.XXX.XXX.XXX\C$\Program Files\

我收到一个弹出窗口,询问用户名和密码。我进入它,访问的路径。当我尝试访问该文件夹重新它不问我的密码。但是,当我重​​新启动,它确实又给弹出。

I get a pop up window asking for username and password. I enter it, and accessed the path. When I try accessing the folder again it do not ask for my password. But when I restart, it does give the popup again.

有没有办法来添加我的凭据?比方说我的域\\用户名是 MYDOMAIN \\ RapsyTree 。我试过如下:

Is there a way to add my credentials?? Lets say my domain\username is MyDomain\RapsyTree. I tried the following:

cmdkey /generic:TERMSRV/YYY.YY.YYY.YYY /user:YourDomain\rapsalands /pass:secretPass

凭据获取添加。但我仍然得到用户名和密码弹出。

The credentials are getting added. But I am still getting the pop up for username and password.

其实我试图 XCOPY 的一些文件在不同的领域在此服务器上。但我需要不同的凭据来做到这一点。我使用批处理文件。任何指针会有很大的帮助。让我知道如果我不清晰。我使用 Windows 7的谢谢!

Actually I am trying to xcopy some files on this server on different domain. But I need to do it with different credentials. I am using batch files. Any pointers will be of great help. Let me know if I am not clear. I am using Windows 7 Thanks!

推荐答案

您只需要映射网络驱动器:

You just have to map a network drive:

net use Z: \\XXX.XXX.XXX.XXX\C$ password /user:domain\username 

如果您希望驱动器在下次登录时重新连接,添加选项 /持久:是

If you want the drive to reconnect at next logon, add the option /persistent:yes

这篇关于XCOPY与远程计算机上的凭据的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆