Bug 864498

Summary: yum: Error: no such table: filelist when file is not in any package
Product: [Fedora] Fedora Reporter: Matthieu Pupat <redhat_bugzilla>
Component: yumAssignee: Fedora Packaging Toolset Team <packaging-team>
Status: CLOSED NOTABUG QA Contact: Fedora Extras Quality Assurance <extras-qa>
Severity: unspecified Docs Contact:
Priority: unspecified    
Version: 17CC: ffesti, maxamillion, packaging-team, tim.lauridsen, zpavlas
Target Milestone: ---   
Target Release: ---   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2012-10-09 15:04:23 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description Matthieu Pupat 2012-10-09 13:16:42 UTC
Description of problem:

When searching for a file that is not in a package yum gives a strange messge.

If I try to search for */bin/ls everything is fine:

# yum provides */bin/ls
Loaded plugins: auto-update-debuginfo, langpacks, presto, refresh-packagekit
coreutils-8.15-6.fc17.x86_64 : A set of basic GNU tools commonly used in shell scripts
Repo        : fedora
Matched from:
Filename    : /bin/ls
Filename    : /usr/bin/ls

If I try to search for */locale/en.mo.gz then I get an error

# yum provides */locale/en.mo.gz
Loaded plugins: auto-update-debuginfo, langpacks, presto, refresh-packagekit
Error: no such table: filelist


Version-Release number of selected component (if applicable):
yum.noarch 3.4.3-29.fc17

How reproducible:
Always

Comment 1 Zdeněk Pavlas 2012-10-09 14:05:32 UTC
This is probably caused by zero-sized /gen/filelists_db.sqlite file, somewhere in your /var/cache/yum/. Try:

# find /var/cache/yum -size 0 -a -name '*filelist*'

If that's the case, rm and try again.  Should be already fixed in head (BZ 825811 and BZ 826419).

Comment 2 Matthieu Pupat 2012-10-09 15:04:23 UTC
Indeed:

# find /var/cache/yum -size 0 -a -name '*filelist*'
/var/cache/yum/x86_64/17/rpmfusion-free-updates-debuginfo/711b438763ac23a4e35f9fb7f81210887ef7f90f08da70d1201102f2a2a66d67-filelists.sqlite.bz2
/var/cache/yum/x86_64/17/rpmfusion-free-updates-debuginfo/gen/filelists_db.sqlite

I removed them and ran yum clean all. Now everything is fine