Re-indexing the Postgres Database can not create unique index for katello_erratum_packages_eid_nvrea_n_f..

Solution Verified - Updated -

Issue

  • Re-indexing the Postgres Database can not create unique index for katello_erratum_packages_eid_nvrea_n_f.

    # runuser -u postgres -- reindexdb -a
    could not change directory to "/root": Permission denied
    reindexdb: reindexing database "candlepin"
    reindexdb: reindexing database "foreman"
    reindexdb: error: reindexing of database "foreman" failed: ERROR:  could not create unique index 
    "katello_erratum_packages_eid_nvrea_n_f"
    DETAIL:  Key (erratum_id, nvrea, name, filename)=(29867, openblas-openmp64-0.3.3-2.el7.x86_64, openblas- 
    openmp64, 
    openblas-openmp64-0.3.3-2.el7.x86_64.rpm) is duplicated.
    

Environment

  • Red Hat Satellite 6.

Subscriber exclusive content

A Red Hat subscription provides unlimited access to our knowledgebase, tools, and much more.

Current Customers and Partners

Log in for full access

Log In

New to Red Hat?

Learn more about Red Hat subscriptions

Using a Red Hat product through a public cloud?

How to access this content