Subject: bin/7977: ftp(1) time estimation is too optimistic on slow network
To: None <gnats-bugs@gnats.netbsd.org>
From: None <itohy@netbsd.org>
List: netbsd-bugs
Date: 07/13/1999 01:20:59
>Number: 7977
>Category: bin
>Synopsis: ftp(1) time estimation is too optimistic on slow network
>Confidential: no
>Severity: non-critical
>Priority: low
>Responsible: bin-bug-people (Utility Bug People)
>State: open
>Class: change-request
>Submitter-Id: net
>Arrival-Date: Tue Jul 13 01:20:01 1999
>Last-Modified:
>Originator: ITOH Yasufumi
>Organization:
>Release: 1.4F (July 12, 1999)
>Environment:
System: NetBSD pino.my.domain 1.4F NetBSD 1.4F (PINO) #0: Tue Jul 13 14:32:23 JST 1999 itohy@pino.my.domain:/usr/src/sys/arch/i386/compile/PINO i386
a.out binaries (for now)
>Description:
ftp(1) excludes "stalled" time for calculation of
ETA (estimated time of ... (arrival?)) and the total
transfer time.
If the network is constantly stalling, the ETA is
not a good estimation of the finish of transfer,
and the total transfer time printed on the the summary line
"xxx bytes retrieved in xx:xx (xx.xx KB/s)"
is much smaller than the real time.
>How-To-Repeat:
Use ftp(1) on slow network and get irritated :-).
You must wait much longer than the ETA time.
>Fix:
By this change, ftp does not exclude the "stalled" time
for calculation of ETA and the total time.
diff -uF^[a-zA-Z_][a-z A-Z0-9_]*(.*[^;]$ util.c.orig util.c
--- util.c.orig Fri Jul 2 20:11:48 1999
+++ util.c Tue Jul 13 15:14:38 1999
@@ -849,10 +849,12 @@ progressmeter(flag)
if (cursize > lastsize) {
lastupdate = now;
lastsize = cursize;
+#if 0
if (wait.tv_sec >= STALLTIME) { /* fudge out stalled time */
start.tv_sec += wait.tv_sec;
start.tv_usec += wait.tv_usec;
}
+#endif
wait.tv_sec = 0;
}
>Audit-Trail:
>Unformatted: