This week's giveaway is in the Android forum.
We're giving away four copies of Android Security Essentials Live Lessons and have Godfrey Nolan on-line!
See this thread for details.
The moose likes Sockets and Internet Protocols and the fly likes FTP from Unix Server using Java Program Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Android Security Essentials Live Lessons this week in the Android forum!
JavaRanch » Java Forums » Java » Sockets and Internet Protocols
Bookmark "FTP from Unix Server using Java Program" Watch "FTP from Unix Server using Java Program" New topic
Author

FTP from Unix Server using Java Program

Vaibhav G Garg
Ranch Hand

Joined: Sep 23, 2011
Posts: 140
Hi,

Please let me know if we can ftp a file placed on a Unix Server using a java program which is running on windows machine.

Steps involved:

1. Connect to unix server
2. Go to the path of the file
3. FTP the file to local windows machine.

Any inputs will be appreciated to start with.

THanks.
Ulf Dittmer
Marshal

Joined: Mar 22, 2005
Posts: 41137
    
  45
That can be easily done. The Apache Commons Net library includes everything you need for a programmatic FTP client: http://commons.apache.org/proper/commons-net/


Ping & DNS - my free Android networking tools app
Nam Ha Minh
Ranch Hand

Joined: Oct 31, 2011
Posts: 498

Vaibhav G Garg wrote:Hi,

Please let me know if we can ftp a file placed on a Unix Server using a java program which is running on windows machine.


I think you mean to download files from the FTP server. Like Ulf suggested, we can use Apache Commons Net for FTP programming in Java. Here's an example:

Java FTP file download tutorial and example


PM Me If You Want to get Urgent Help on Java Programming
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: FTP from Unix Server using Java Program
 
Similar Threads
Unix command wiredness in OS 10.3
Need to copy from PC to UNIX
How to download Files from Remote Windows Server
Working with Java in UNIX
Tranfer files between java and unix