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

[Satellite6] Uninstalling the Foreman templates plugin failed with error.

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Duplicate
    • Icon: Normal Normal
    • None
    • 6.13.0, 6.14.0, 6.15.0
    • None
    • 0
    • False
    • Hide

      None

      Show
      None
    • False
    • 0
    • Important
    • No

      Description of problem:

      While performing uninstallation of the foreman templates plugin on the Satellite server, the foreman-rake command fails with the error:

      Documentation followed:
      https://access.redhat.com/documentation/en-us/red_hat_satellite/6.15/html/managing_hosts/synchronizing_templates_repositories_managing-hosts#Uninstalling_the_Foreman_Templates_plugin_managing-hosts

      How reproducible:

       100%

      Is this issue a regression from an earlier version:

        Red Hat Satellite 6.13, 6.14

      Steps to Reproduce:

      1. Access the CLI of the Satellite server, run the command to disable the plugin using the Satellite installer:

      ~~~
      $ satellite-installer --no-enable-foreman-plugin-templates
      ~~~

      2. Once the above command is completed, run the following command:

      ~~~
      $ foreman-rake templates:cleanup
      ~~~

      The above command fails with error.

      ===============================================
      $ foreman-rake templates:cleanup --trace

        • Invoke templates:cleanup (first_time)
        • Invoke environment (first_time)
        • Execute environment
        • Execute templates:cleanup
          Cleaning data...
          rake aborted!
          NameError: uninitialized constant Setting::TemplateSync
          /usr/share/gems/gems/foreman_hooks-0.3.17/lib/foreman_hooks/as_dependencies_hook.rb:4:in `load_missing_constant'
          /usr/share/gems/gems/foreman_templates-9.4.0/app/services/foreman_templates/cleaner.rb:10:in `remove_settings'
          /usr/share/gems/gems/foreman_templates-9.4.0/app/services/foreman_templates/cleaner.rb:4:in `clean_up!'
          /usr/share/gems/gems/foreman_templates-9.4.0/lib/tasks/foreman_templates_tasks.rake:70:in `block (2 levels) in <top (required)>'
          /usr/share/gems/gems/rake-13.0.1/lib/rake/task.rb:281:in `block in execute'
          /usr/share/gems/gems/rake-13.0.1/lib/rake/task.rb:281:in `each'
          /usr/share/gems/gems/rake-13.0.1/lib/rake/task.rb:281:in `execute'
          /usr/share/gems/gems/rake-13.0.1/lib/rake/task.rb:219:in `block in invoke_with_call_chain'
          /usr/share/gems/gems/rake-13.0.1/lib/rake/task.rb:199:in `synchronize'
          /usr/share/gems/gems/rake-13.0.1/lib/rake/task.rb:199:in `invoke_with_call_chain'
          /usr/share/gems/gems/rake-13.0.1/lib/rake/task.rb:188:in `invoke'
          /usr/share/gems/gems/rake-13.0.1/lib/rake/application.rb:160:in `invoke_task'
          /usr/share/gems/gems/rake-13.0.1/lib/rake/application.rb:116:in `block (2 levels) in top_level'
          /usr/share/gems/gems/rake-13.0.1/lib/rake/application.rb:116:in `each'
          /usr/share/gems/gems/rake-13.0.1/lib/rake/application.rb:116:in `block in top_level'
          /usr/share/gems/gems/rake-13.0.1/lib/rake/application.rb:125:in `run_with_threads'
          /usr/share/gems/gems/rake-13.0.1/lib/rake/application.rb:110:in `top_level'
          /usr/share/gems/gems/rake-13.0.1/lib/rake/application.rb:83:in `block in run'
          /usr/share/gems/gems/rake-13.0.1/lib/rake/application.rb:186:in `standard_exception_handling'
          /usr/share/gems/gems/rake-13.0.1/lib/rake/application.rb:80:in `run'
          /usr/share/gems/gems/rake-13.0.1/exe/rake:27:in `<top (required)>'
          /usr/bin/rake:23:in `load'
          /usr/bin/rake:23:in `<main>'
          Tasks: TOP => templates:cleanup
          ===============================================

      Actual behavior:
      While trying to uninstall the templates plugin on the Satellite server, the steps followed from the documentation failed with an error.

      Expected behavior:
      The command should run without any error, it should perform template cleanup on the Satellite server.

              apetrova@redhat.com Aneta Šteflová Petrová
              rhn-support-ashipati Ashish Patil
              apatil@redhat.com (Inactive)
              Votes:
              0 Vote for this issue
              Watchers:
              5 Start watching this issue

                Created:
                Updated:
                Resolved: