Bug 101038 - net-ftp/ftp fails retrieving files larger than 2GB
Bug#: 101038 Product:  Gentoo Linux Version: unspecified Platform: All
OS/Version: Linux Status: RESOLVED Severity: normal Priority: P2
Resolution: FIXED Assigned To: base-system@gentoo.org Reported By: maik@musall.de
Component: Applications
URL: 
Summary: net-ftp/ftp fails retrieving files larger than 2GB
Keywords:  
Status Whiteboard: 
Opened: 2005-08-01 16:29 0000
Description:   Opened: 2005-08-01 16:29 0000
ftp> get htdocs_050801.tar.gz
local: htdocs_050801.tar.gz remote: htdocs_050801.tar.gz
200 PORT command successful. Consider using PASV.
150 Opening BINARY mode data connection for htdocs_050801.tar.gz (2707419892 bytes).
htdocs_050801.tar.gz: short write
426 Failure writing network stream.
2147483064 bytes received in 212 secs (9.9e+03 Kbytes/sec)


Reproducible: Always
Steps to Reproduce:
1. prepare a file larger than 2GB on your favourite ftp server
2. GET it

Actual Results:  
see Details

Expected Results:  
complete fetch. Installed lftp as a substitute which had no problem.

------- Comment #1 From SpanKY 2005-08-02 18:47:07 0000 -------
if you put these into your CFLAGS does it work ?
-D_FILE_OFFSET_BITS=64 -D_LARGEFILE_SOURCE -D_LARGEFILE64_SOURCE

------- Comment #2 From Maik Musall 2005-08-03 01:47:27 0000 -------
Yes, confirmed, that does it.

I would suggest to put these options to default for this package, since most of
the environment around it (filesystems, vsftpd, lftp...) is already
largefile-enabled, so this comes rather unexpected.

Maik

------- Comment #3 From SpanKY 2005-08-03 16:30:19 0000 -------
added to ftp-0.17-r5

------- Comment #4 From Jakub Moc (RETIRED) 2005-08-13 16:23:24 0000 -------
*** Bug 102441 has been marked as a duplicate of this bug. ***

------- Comment #5 From Panagiotis Christopoulos 2008-08-13 11:17:49 0000 -------
*** Bug 234599 has been marked as a duplicate of this bug. ***

------- Comment #6 From Panagiotis Christopoulos 2008-08-13 11:20:53 0000 -------
Reopen as it seems that ftp-0.17-r6 and ftp-0.17-r7 have the same issue. See
bug 234599

------- Comment #7 From SpanKY 2008-08-20 06:57:59 0000 -------
new bug -> new issue ... the reason for the breakage is different as things
have changed