Red Hat Bugzilla – Bug 63274
lftp (2.1.5) exclude options match too loosly
Last modified: 2007-04-18 12:41:54 EDT
From Bugzilla Helper:
User-Agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:0.9.9) Gecko/20020311
Description of problem:
-x exclude options in lftp's mirror subcommand seem to match more loosly than
would be expected. Using lftp to mirror redhat's updates
(ftp.redhat.com/pub/redhat/linux/updates/) the -x option matched too loosely and
cause some packages to be missed during the mirror. I had -x .nfs* as one of my
exclude options and it cause at least 7 files to be skipped as a result.
(* is used below to omit version numbers not be inclusive of packages)
The packages skipped were:
lftp script is as follows:
mirror -e -x .nfs*
I found this problem with lftp on a 6.2 box, but it was verified by someone else
on a 7.2 box as well.
Version-Release number of selected component (if applicable):
Steps to Reproduce:
1. create appropriate directories referenced in above script
2. create and run the above shell script
3. check for existance of the above listed packages (Xconfigurator, etc)
Actual Results: it will mirror 90% of the data there, but it will leave out the
listed packages and possible others.
Expected Results: should have mirrored all the packages in that directory
including the listed ones.
lftp version: 2.1.5
it appears that it's match is too loose, like it's matching the n or the f or s.
Or something similar.
it is worked around by quoting the arguement to the mirror comamnd
mirror -e -x '.nfs*'
behavior confirmed in 7.2 x86 (lftp-2.4.0-2).
Just clearing out old bugs here .
The latest version of lftp is 3.0.6 and I have confirmed that its
mirror -x RE and mirror -X GLOB commands work OK.
This bug could have resulted from some confusion about -x option:
The -x option expects an extented regular expression as in egrep(1),
so .nfs* matches any character followed by 'nf' followed by a
(perhaps empty) sequence of 's' chars, so the following all match:
lftp now provides the mirror -X glob option so '-X *.nfs*' would
do what I think you were expecting here.