java - Error on copy folder from remote system using FTP -


find screen shot here commandsi'm trying copy folder remote system using ftp in java , getting error:

unable determine system type - response: 502 command not implemented.

how resolve issue?

this code getting 502 error:

import java.io.ioexception;  import org.apache.commons.net.ftp.ftpclient; public class test2 {      public static void main(string[] args) {         string server = "******";         int port = 21;         string user = "asassas";         string pass = "123456";          ftpclient ftpclient = new ftpclient();          try {             // connect , login server             ftpclient.connect(server, port);             ftpclient.login(user, pass);              // use local passive mode pass firewall             ftpclient.enterlocalpassivemode();              system.out.println("connected");              string remotedirpath = "/eclipse/fb010714";             string savedirpath = "d:/ftptest/download/ftp";              ftputil.downloaddirectory(ftpclient, remotedirpath, "", savedirpath);              // log out , disconnect server             ftpclient.logout();             ftpclient.disconnect();              system.out.println("disconnected");         } catch (ioexception ex) {             ex.printstacktrace();         }     } } 


Comments

Popular posts from this blog

What is happening when Matlab is starting a "parallel pool"? -

angular - DownloadURL return null in below code -

php - Cannot override Laravel Spark authentication with own implementation -