LinuxQuestions.org
Latest LQ Deal: Latest LQ Deals
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Software
User Name
Password
Linux - Software This forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.

Notices


Reply
  Search this Thread
Old 03-06-2011, 05:24 AM   #1
sinkaine
LQ Newbie
 
Registered: Mar 2011
Posts: 1

Rep: Reputation: 0
Please help me mounting a FTP Folder from a drftpd Server (PRET Transfer Required)


Hello,

my os is Debian Sid. I use curlftpfs for mounting ftp. I can mount the folder but I'm unable to make fileoperations.
My mount command is
Code:
 curlftpfs -v -o disable_eprt   -d  'usr:pass@server:1234' /mnt/ftp
that works fine:
Quote:
< 230 XXX logged in successfully.
> PWD
< 257 "/" is current directory
* Entry path is '/'
And here comes trouble:

Code:
ls /mnt/ftp/
ls: lese Verzeichnis /mnt/ftp/: Eingabe-/Ausgabefehler
That means I/O Error.

Output from server and curlftps:
Quote:
< 500 You need to use a client supporting PRET (PRE Transfer) to use PASV
* Bad PASV/EPSV response: 500
* Remembering we are in dir ""
* Connection #0 to host XXXX left intact
ftpfs: operation ftpfs_getdir failed because Input/output error
unique: 4, error: -5 (Input/output error), outsize: 16
unique: 5, opcode: RELEASEDIR (29), nodeid: 1, insize: 64
unique: 5, success, outsize: 16
Is there a way to enalbe PRET for curlftps or another tool for mounting ftp folders with PRET support?


thanking you in anticipation
porter
 
Old 01-06-2012, 11:32 AM   #2
Gfy
LQ Newbie
 
Registered: Nov 2009
Posts: 1

Rep: Reputation: 0
CurlFtpFS is based on cURL and that library supports PRET since 2010, but it's been 3 years since CurlFtpFS had a new release. You will have to do some compiling yourself.

Quote:
Daniel Stenberg (1 Jan 2010)
- Ingmar Runge enhanced libcurl's FTP engine to support the PRET command. This
command is a special "hack" used by the drftpd server, but even though it is
a custom extension I've deemed it fine to add to libcurl since this server
seems to survive and people keep using it and want libcurl to support
it. The new libcurl option is named CURLOPT_FTP_USE_PRET, and it is also
usable from the curl tool with --ftp-pret. Using this option on a server
that doesn't support this command will make libcurl fail.

I added test cases 1107 and 1108 to verify the functionality.

The PRET command is documented at
drftpd.org/index.php/Distributed_PASV
These steps will make CurlFtpFS work with DrFTPD servers. I haven't tested it myself, but it's confirmed to me that it works.

In this file: ftpfs.c

In this function:

Code:
static void set_common_curl_stuff(CURL* easy) {
add the following line:

Code:
  curl_easy_setopt_or_die(easy, CURLOPT_FTP_USE_PRET, 1);
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
file transfer program in c using FTP client and FTP server renuaseri Linux - Newbie 2 01-29-2011 05:49 AM
file transfer server required ltodd2 Linux - Software 3 06-19-2009 03:48 AM
How to configure ftp in linux Ent-4 & how to get the required folder through browser sunil007_india Linux - Networking 1 08-15-2006 01:42 PM
FTP need to transfer entire folder recursively rolster Linux - Newbie 6 02-02-2006 08:54 AM
Can I make a Cron job to synch/transfer a file from a folder to another FTP?... read efishta Linux - General 6 07-19-2003 10:03 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Software

All times are GMT -5. The time now is 03:07 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration