Curlftpfs 0.9 seems to work when using it from a shell but from a C program, it hangs.
My program just tries to read 2 files, and on the 2nd open, ftpfs hang and loops getting the same file over and over:
with strace it's stuck to : open("/exclude", O_RDONLY
I can only reproduce this using libcurl 7.16.0. A quick fix for you would be to use an older version of libcurl. I'll look into this to see if it's a new libcurl bug or some bug in curlftpfs that got worse with the new libcurl version.
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
Nice, with curl 7.15.5 it works.
FWI, I've managed to use Curlftpfs instead of NFS to make a disk image, using the Linbox Rescue Server ( http://lrs.linbox.org ), it includes ghost-like features to make disk images with a PXE boot.
It splits the backup in files of up to 90MB so I guess that the backuped system needs at least 128MB of RAM ?
Cheers,
Ludo.
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
Hi !
Curlftpfs 0.9 seems to work when using it from a shell but from a C program, it hangs.
My program just tries to read 2 files, and on the 2nd open, ftpfs hang and loops getting the same file over and over:
with strace it's stuck to : open("/exclude", O_RDONLY
and ethereal loops on:
18 0.058585 192.168.0.244 -> 172.20.0.123 FTP Request: PASV
19 0.058709 172.20.0.123 -> 192.168.0.244 FTP Response: 227 Entering Passive
Mode (172,20,0,123,227,135)
20 0.059708 192.168.0.244 -> 172.20.0.123 TCP 2892 > 21 [ACK] Seq=1707352969
Ack=2704235897 Win=2920 Len=0
21 0.060334 192.168.0.244 -> 172.20.0.123 TCP 2370 > 58247 [SYN] Seq=19898400
05 Ack=0 Win=5840 Len=0
22 0.060358 172.20.0.123 -> 192.168.0.244 TCP 58247 > 2370 [SYN, ACK] Seq=300
6113560 Ack=1989840006 Win=5792 Len=0
23 0.061081 192.168.0.244 -> 172.20.0.123 TCP 2370 > 58247 [ACK] Seq=19898400
06 Ack=3006113561 Win=2920 Len=0
24 0.061459 192.168.0.244 -> 172.20.0.123 FTP Request: SIZE exclude
25 0.061538 172.20.0.123 -> 192.168.0.244 FTP Response: 213 0
26 0.062206 192.168.0.244 -> 172.20.0.123 FTP Request: RETR exclude
27 0.062345 172.20.0.123 -> 192.168.0.244 FTP Response: 150 Opening BINARY mo
de data connection for exclude (0 bytes).
28 0.062373 172.20.0.123 -> 192.168.0.244 FTP Response: 226 File send OK.
29 0.062394 172.20.0.123 -> 192.168.0.244 TCP 58247 > 2370 [FIN, ACK] Seq=300
6113561 Ack=1989840006 Win=5792 Len=0
30 0.064082 192.168.0.244 -> 172.20.0.123 TCP 2370 > 58247 [ACK] Seq=19898400
06 Ack=3006113562 Win=2920 Len=0
31 0.064209 192.168.0.244 -> 172.20.0.123 TCP 2370 > 58247 [FIN, ACK] Seq=198
9840006 Ack=3006113562 Win=2920 Len=0
I use libcurl 7.16.0, libfuse 2.5.3, and a 2.6.18.2 kernel.
Any ideas ?
Ludo.
Update: the bug appears when a file is empty, and is opened 2 times.
example:
# cat exclude (0 bytes)
# cat hdmap (17 bytes)
...
contents
...
# cat exclude
FREEZE ! And loops as described above !
Any quick fix ?
Ludovic.
I can only reproduce this using libcurl 7.16.0. A quick fix for you would be to use an older version of libcurl. I'll look into this to see if it's a new libcurl bug or some bug in curlftpfs that got worse with the new libcurl version.
A quick fix could be avoiding to send a RETR when the size is 0 ?
Nice, with curl 7.15.5 it works.
FWI, I've managed to use Curlftpfs instead of NFS to make a disk image, using the Linbox Rescue Server ( http://lrs.linbox.org ), it includes ghost-like features to make disk images with a PXE boot.
It splits the backup in files of up to 90MB so I guess that the backuped system needs at least 128MB of RAM ?
Cheers,
Ludo.