Questions tagged [ftp4j]

"The ftp4j library implements a Java full-features FTP client. With ftp4j embedded in your application you can: transfer files (upload and download), browse the remote FTP site (directory listing included), create, delete, rename and move remote directories and files." -- Sauron Software

The ftp4j library implements a Java full-features FTP client. With ftp4j embedded in your application you can: transfer files (upload and download), browse the remote FTP site (directory listing included), create, delete, rename and move remote directories and files.

Source: http://www.sauronsoftware.it/projects/ftp4j/index.php

40 questions
1
vote
1 answer

Fail to upload file using ftp4j

I'm using ftp4j as FTP client. FTPClient client = new FTPClient(); client.connect("86.22.11.178"); client.login("usr", "pwd"); client.changeDirectory("/dir"); client.upload(file); It works fine at localhost, but it does not work when enclosed in a…
Shani
  • 17
  • 1
  • 3
1
vote
1 answer

FTP server dies while ftp4j client downloads a file

I use sauronsoftware.ftp4j.FTPClient to do scheduled file downloads from FTP servers. My problem is that FTP server suddenly dies while the client downloads a file from it. This is what i do: for (FTPFile remoteFile : remoteFiles) { …
Natta
  • 715
  • 1
  • 7
  • 15
1
vote
0 answers

Download files recursively from a directory present on unix server to local directory by ftp using Java code

I need to ftp files from a directory which has many sub-directories (and in turn each directory has many other directories and files in it) from Unix server to my local machine using Java. I tried using org.apache.commons.net.ftp.FTPClient and…
1
vote
1 answer

Download an Entire Directory Using FTP4J

I have looked through the documentation and I can't seem to find a function which does this. So, I assume that I should code it myself. Looking further into the documentation, I found a list() function which lists all the files in a working…
Nyx
  • 1,273
  • 6
  • 19
  • 32
1
vote
1 answer

Java FTP not working inside SwingWorker Thread

I have a simple GUI program that does some interactions with a database then once its completed ftps up some files to a server. This has worked perfectly until I added a SwingWorker thread to keep the GUI responsive. The code I am using works fine…
1
vote
2 answers

FTP error while downloading/uploading with ftp4j library in java application

I want to download a file in java application and when I try it, it creates the file on my hard drive but then fails to download it completely. I am using the ftp4j library to do it. import it.sauronsoftware.ftp4j.*; public class Main { public…
Karuvägistaja
  • 293
  • 1
  • 8
  • 17
0
votes
1 answer

How can I upload a file from my local machine to a webservice for ftp transfer using java?

Requirement --> 1. To create a ftp file uploader application where in I can upload a file from my local machine to ftp server through a web browser. 2. TO publish a web service where in webservice client will pass the file and file will be uploaded…
AngryJS
  • 955
  • 5
  • 23
  • 47
0
votes
1 answer

Problems with connecting with it.sauronsoftware.ftp4j.FTPClient to SFTP

I am having problems connecting with it.sauronsoftware.ftp4j.FTPClient. I want to use SFTP but always get errors. If I use: sftpClient.setSecurity(FTPClient.SECURITY_FTPES) I get: ERROR c.l.datamanager.Ftp4jFTPTask -…
0
votes
1 answer

ftp4j - Too many connections exception

I am creating a sync service which will copy files to ftp folder selected by user. When i run the service, it connects with ftp and check whether file at android local storage is available at ftp or not and if not, it uploads. Below is my code. …
Panache
  • 1,701
  • 3
  • 19
  • 33
0
votes
0 answers

ftp4j download file which size is 0 byte

I download a file using ftp4j library, its size is 0 byte. I get no exception. So I use jstack pid ,here is the snippet about ftp. `"Thread-17" #63 prio=5 os_prio=0 tid=0x0000000021154000 nid=0x2bf0 runnable [0x00000000275ae000] …
Ron
  • 553
  • 2
  • 10
  • 30
0
votes
0 answers

ftp4j - FTPException [code=426, message= Data connection error.]

I am getting following error after trying to download file from FTP using ftp4j in android. W/System.err: it.sauronsoftware.ftp4j.FTPException [code=426, message= Data connection error.] 12-16 11:29:30.496 22976-23595/ W/System.err: at…
Mr. Sajid Shaikh
  • 7,051
  • 4
  • 21
  • 35
0
votes
2 answers

ftp4j - upload a file in append mode

Is there a way to upload a file with ftp4j in append mode? I can't find any reference to that in the documentation or on google. Thank you!
Alberto M
  • 1,608
  • 1
  • 18
  • 42
0
votes
0 answers

Is it possible to create or send my own custom command to work on ftp server

I am creating a Android client which successfully uploads a file to my ftp server. I am using ftp4j library and want to send my custom command like this. e.g mycustomcommand is a kind of tcp command.. FTPClient client = new FTPClient(); try…
Ravi Yadav
  • 2,296
  • 3
  • 25
  • 32
0
votes
1 answer

Android ftp4j - remote file size doesn't match local file size after upload success

I got a weird bug here. In order to upload file to my ftp server I imported ftp4j package in my android app. Problem is whenever the upload is complete the uploaded file size change, I checked the file content it does not match the original content…
rickie
  • 67
  • 1
  • 6
0
votes
1 answer

Ignore self-signed ssl cert on CentOS using ftp4j on client

Task: Connect to a CentOS box using FTP4J FTP using a self signed certificate. I am able to successfully connect to the CentOS box over FTP using org.apache.commons.net.ftp.FTPSClient however I receive the following error, which I know to be from…
Sarah Weinberger
  • 15,041
  • 25
  • 83
  • 130