简体   繁体   English

如何将文件从远程Linux机器复制到JSP Web目录

[英]How to copy file from remote linux machine to JSP web directory

I want to create a JSP webpage which contains a button on click of which I want to copy a file from remote linux machine to my local directory (in windows) where JSP pages are hosted. 我想创建一个包含一个按钮的JSP网页,单击该按钮我想将文件从远程linux计算机复制到托管JSP页面的本地目录(在Windows中)。 I have the UserID and Password of that machine and I can connect to the remote server using SSH command in putty. 我具有该机器的用户名和密码,并且可以在腻子中使用SSH命令连接到远程服务器。

I am using Eclipse Indigo and Tomcat Server. 我正在使用Eclipse Indigo和Tomcat服务器。

您可以从远程计算机使用FTP吗?

You can use JSch to have a pure Java implementation of the SSH protocol and copy your file. 您可以使用JSch获得SSH协议的纯Java实现并复制文件。 File transfer ( scp command) with JSch can be a bit tricky, so you can add securechannelfacade to transfer your file properly 使用JSch进行文件传输( scp命令)可能会有些棘手,因此您可以添加securechannelfacade来正确传输文件

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

相关问题 使用 java.nio.file.Files.copy() 将文件从 Linux 复制到 Windows 远程机器 - Copy a file to a Windows remote machine from Linux using java.nio.file.Files.copy() 从一台linux机器到另一台linux机器的远程文件传输 - Remote File Transfer from one linux machine to another linux machine 如何从另一个Web应用程序在远程计算机上执行bat文件 - How to execute a bat file on remote machine from another web app 在Java中使用SFTP将目录复制到远程计算机 - Copy directory to a remote machine using SFTP in java 如何使用Java和Jackcess从Linux机器访问共享文件夹中的远程.mdb文件 - How to access the remote .mdb file in shared folder using java and jackcess from linux machine 使用JSch将一个文件从远程计算机复制到另一台远程计算机 - Using JSch to copy one file from remote machine to another remote machine 如何通过使用 Selenium Grid 将文件从本地机器传输到远程 web 服务器来上传文件 - How to upload a file by transfering the file from the local machine to the remote web server using Selenium Grid 如何使用Java11在远程机器中创建文件/目录 - How to create a file / directory in remote machine using Java11 从没有 web 服务器的远程机器读取文件 - Read file from remote machine without web server 如何获取驻留在远程计算机上的JSP页面? - how to fetch a JSP page residing on a remote machine?
 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM