Bug 199032 - wget abort with -nc option.
Summary: wget abort with -nc option.
Status: CLOSED RAWHIDE
Alias: None
Product: Fedora
Classification: Fedora
Component: wget (Show other bugs)
(Show other bugs)
Version: rawhide
Hardware: All Linux
medium
medium
Target Milestone: ---
Assignee: Karsten Hopp
QA Contact:
URL:
Whiteboard:
Keywords: Reopened
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2006-07-16 03:30 UTC by Ralph Loader
Modified: 2007-11-30 22:11 UTC (History)
1 user (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2007-02-12 13:49:35 UTC
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)
Fix (this line should be changed in wget-1.10.2-to11.patch) (335 bytes, patch)
2006-08-25 00:25 UTC, Daniel Kopeček
no flags Details | Diff

Description Ralph Loader 2006-07-16 03:30:56 UTC
Description of problem:

wget -nc on an existing file aborts:

$ wget -nc www.redhat.com/index.html
... completes successfully....

$ wget -nc www.redhat.com/index.html
....
Aborted
.... now file exists, and wget aborts.

Version-Release number of selected component (if applicable):

wget-1.10.2-5.1

backing off to wget-1.10.2-3.2.1 fixes the problem.

How reproducible:

Every time.

Comment 1 Karsten Hopp 2006-07-17 09:16:18 UTC
from the man-page:
 -nc
       --no-clobber
           If a file is downloaded more than once in the same directory,
           Wgetâs behavior depends on a few options, including -nc.  In cer-
           tain cases, the local file will be clobbered, or overwritten, upon
           repeated download.  In other cases it will be preserved.

           When running Wget without -N, -nc, or -r, downloading the same file
           in the same directory will result in the original copy of file
           being preserved and the second copy being named file.1.  If that
           file is downloaded yet again, the third copy will be named file.2,
           and so on.  When -nc is specified, this behavior is suppressed, and
           Wget will refuse to download newer copies of file.  Therefore,
           ââ"no-clobber"ââ is actually a misnomer in this mode---itâs not
           clobbering thatâs prevented (as the numeric suffixes were already
           preventing clobbering), but rather the multiple version saving
           thatâs prevented.


Especially this sentence:
When -nc is specified, this behavior is suppressed, and Wget will refuse to
download newer copies of file.

Comment 2 Ralph Loader 2006-07-17 09:25:08 UTC
No you misunderstood.

wget is crashing with an abort.

This makes a real difference if you have a list of files to download.  E.g.,

 touch index.html ; wget -nc http://www.redhat.com/ http://www.kernel.org/pub/
linux/kernel/v2.6/linux-2.6.17.tar.bz2

should skip the first URL and then download the second, but instead I get:

--21:28:25--  http://www.redhat.com/
Resolving www.redhat.com... 209.132.177.50
Connecting to www.redhat.com|209.132.177.50|:80... connected.
HTTP request sent, awaiting response... 200 OK
File `index.html' already there; not retrieving.

Aborted

Until very recently, the above worked just fine - the first url was skip and the
second was downloaded:

touch index.html ; wget -nc http://www.redhat.com/ http://www.kernel.org/pub/
linux/kernel/v2.6/linux-2.6.17.tar.bz2
File `index.html' already there; not retrieving.

--21:29:51--  http://www.kernel.org/pub/linux/kernel/v2.6/linux-2.6.17.tar.bz2
           => `linux-2.6.17.tar.bz2'
Resolving www.kernel.org... 204.152.191.37, 204.152.191.5
Connecting to www.kernel.org|204.152.191.37|:80... connected.
HTTP request sent, awaiting response... 200 OK
Length: 41,272,919 (39M) [application/x-bzip2]


In any case, wget should not be crashing with a SIGABRT.


Comment 3 Daniel Kopeček 2006-08-25 00:25:33 UTC
Created attachment 134876 [details]
Fix (this line should be changed in wget-1.10.2-to11.patch)

Comment 4 Karsten Hopp 2007-02-12 13:49:35 UTC
I've dropped the to11 patch altogether as it causes lots of other problems:
#223754, #227853, #227498


Note You need to log in before you can comment on or make changes to this bug.