简体   繁体   English

如何将远程Windows上的文件复制到Linux计算机上的本地Linux?

[英]How to copy files on remote Windows to local Linux on a Linux machine?

Currently, I'm working on a local Linux machine. 目前,我正在本地Linux机器上工作。 I'm trying to use scp or similar Linux command-line tools to copy files from a remote Windows machine to my local Linux. 我正在尝试使用scp或类似的Linux命令行工具将文件从远程Windows计算机复制到我的本地Linux。 I did some searching and found that most of the solutions are for local Windows cases (like putty and winscp), which don't really help. 我进行了一些搜索,发现大多数解决方案都适用于本地Windows案例(例如,腻子和winscp),但实际上并没有帮助。

Please advise.Thank you. 请指教。谢谢。

[UPDATE] Solved by installing cygwin's sshd service on Windows. [更新]通过在Windows上安装cygwin的sshd服务来解决。

If the windows system has a shared folder you should be able access that with smbclient which is part of the terrific samba project. 如果Windows系统具有共享文件夹,则应该可以使用smbclient来访问该文件夹,这是出色的samba项目的一部分。

Usually somthing like: 通常是这样的:

smbclient //winmachine/share

Possibly using the -U username options to specifiy the username on the windows box. 可能使用-U username选项来指定Windows框中的用户名。

Once connected, you can use cd to change folders, and get to retrieve files. 一旦连接,您可以使用cd来更改文件夹,并get检索文件。

If there is no file share.... I dunno. 如果没有文件共享...。我不知道。 Create one? 创建一个?

If you really want to use SCP, you will need an SCP server (actually an SSH server) on the Windows machine. 如果您确实想使用SCP,则在Windows机器上将需要一个SCP服务器(实际上是SSH服务器)。

For example freeSSHd . 例如freeSSHd

You will need to choose one of the options based on your own needs, there are a number of similar tools and freeSSHd was the first in the list on Google. 您需要根据自己的需要选择一个选项,有很多类似的工具,并且freeSSHd在Google列表中排名第一。 I've used the Bitvise SSH Server in the past but it is only free for non-commercial use. 我过去曾使用过Bitvise SSH服务器 ,但它仅可用于非商业用途。

They are usually very easy to set up. 它们通常很容易设置。 You install them the usual way and run them for the first time. 您以通常的方式安装它们并第一次运行它们。 Depending on the tool, they may pick up your existing Windows users or you may need to manually create some users with passwords within the tool. 根据工具的不同,他们可能会选择您现有的Windows用户,或者您可能需要在工具内使用密码手动创建一些用户。 Then, armed with your PC's IP address, you should be able to connect to the PC using SSH from the Linux command line. 然后,使用PC的IP地址,您应该能够从Linux命令行使用SSH连接到PC。

暂无
暂无

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

相关问题 是否可以将文件从本地 windows 目录复制到远程 linux 目录? - Is it possible to copy files from local windows directory to remote linux directory? How ansible copy file from remote windows to remote linux without local copy and ssh install in windows - How ansible copy file from remote windows to remote linux without local copy and ssh install in windows 如何从本地计算机[windows 7]运行和恢复远程计算机[linux]中的Eclipse - How to run and restore Eclipse which in remote machine [linux] from a local machine [windows 7] 使用staf将文件从linux复制到远程Windows机器 - Copy file from linux to remote windows machine using staf 无法从本地Windows计算机连接到远程AWS Linux MySQL - Cannot connect to remote AWS Linux MySQL from local Windows machine 将文件夹从服务器(Linux)复制到python中的本地计算机(windows) - Copy folder from server(Linux) to local machine(windows) in python 如何在无头远程 Linux 服务器上运行应用程序并查看本地 Windows 机器上的 UI - How to run an application on headless remote Linux server and see the UI on my local Windows machine 如何将文件从远程Linux机器复制到JSP Web目录 - How to copy file from remote linux machine to JSP web directory 如何使用rcp将文件从linux复制到Windows - How to copy files from the linux to windows with rcp 使用Java使用Windows和Linux将本地文件复制并执行到远程服务器 - Copying and executing local files to a remote server with windows and linux using java
 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM