Uploaded image for project: 'Satellite'
  1. Satellite
  2. SAT-36568

Failed to update 6.17.2 to x

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Duplicate
    • Icon: Undefined Undefined
    • None
    • 6.17.2
    • Upgrades
    • None
    • False
    • sat-rocket
    • None
    • None
    • None
    • None

      Description of problem:

      While running the update the following error occurs:
      2025-08-12 09:08:01 [ERROR ] [configure] '/usr/sbin/foreman-rake db:migrate' returned 1 instead of one of [0] 2025-08-12 09:08:01 [ERROR ] [configure] /Stage[main]/Foreman::Database/Foreman::Rake[db:migrate]/Exec[foreman-rake-db:migrate]/returns: change from 'notrun' to ['0'] failed: '/usr/sbin/foreman-rake db:migrate' returned 1 instead o f one of [0] 2025-08-12 09:08:23 [NOTICE] [configure] 3000 configuration steps out of 3248 steps complete. 2025-08-12 09:08:53 [NOTICE] [configure] System configuration has finished.Error 1: Puppet Exec resource 'foreman-rake-db:migrate' failed. Logs:   /Stage[main]/Foreman::Database/Foreman::Rake[db:migrate]/Exec[foreman-rake-db:migrate]     Adding autorequire relationship with User[foreman]     Starting to evaluate the resource (2975 of 3248)     Evaluated in 43.86 seconds   Exec[foreman-rake-db:migrate](provider=posix)     Executing check '/usr/sbin/foreman-rake db:abort_if_pending_migrations'     Executing '/usr/sbin/foreman-rake db:migrate'   /Stage[main]/Foreman::Database/Foreman::Rake[db:migrate]/Exec[foreman-rake-db:migrate]/unless     Run `bin/rails db:migrate` to update your database then try again.     You have 2 pending migrations:       20250613210050 UseBigIntForErratumPackagesId       20250714190050 AddMissingRpmsEvrIndex   /Stage[main]/Foreman::Database/Foreman::Rake[db:migrate]/Exec[foreman-rake-db:migrate]/returns     rake aborted!     StandardError: An error has occurred, this and all later migrations canceled:         PG::UniqueViolation: ERROR:  could not create unique index "katello_erratum_packages_eid_nvrea_n_f"     DETAIL:  Key (erratum_id, nvrea, name, filename)=(15395, openblas-openmp64_-0.3.3-5.el8.x86_64, openblas-openmp64_, openblas-openmp64_-0.3.3-5.el8.x86_64.rpm) is duplicated.
       
      /usr/share/gems/gems/rake-13.0.3/exe/rake:27:in `<top (required)>'
              Caused by:
          ActiveRecord::RecordNotUnique: PG::UniqueViolation: ERROR:  could not create unique index "katello_erratum_packages_eid_nvrea_n_f"
          DETAIL:  Key (erratum_id, nvrea, name, filename)=(15395, openblas-openmp64_-0.3.3-5.el8.x86_64, openblas-openmp64_, openblas-openmp64_-0.3.3-5.el8.x86_64.rpm) is duplicated.
      (See full trace by running task with --trace)     == 20250613210050 UseBigIntForErratumPackagesId: migrating ====================     -- execute("ALTER SEQUENCE katello_erratum_packages_id_seq AS bigint;")        -> 0.0136s     -- change_column(:katello_erratum_packages, :id, :bigint)     change from 'notrun' to ['0'] failed: '/usr/sbin/foreman-rake db:migrate' returned 1 instead of one of [0]1
      

      How reproducible:

      Always

      Is this issue a regression from an earlier version:

       

      Steps to Reproduce:

      1. run satellite-update 

      2.

      3.

      Actual behavior:

      Update fails

      Expected behavior:

      Update finishes without errors

      Business Impact / Additional info:

       

              Unassigned Unassigned
              rhn-gps-gsigrisi Gianfranco Sigrisi (Inactive)
              Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

                Created:
                Updated:
                Resolved: