Note: This bug is displayed in read-only format because
the product is no longer active in Red Hat Bugzilla.
Red Hat Satellite engineering is moving the tracking of its product development work on Satellite to Red Hat Jira (issues.redhat.com). If you're a Red Hat customer, please continue to file support cases via the Red Hat customer portal. If you're not, please head to the "Satellite project" in Red Hat Jira and file new tickets here. Individual Bugzilla bugs will be migrated starting at the end of May. If you cannot log in to RH Jira, please consult article #7032570. That failing, please send an e-mail to the RH Jira admins at rh-issues@redhat.com to troubleshoot your issue as a user management inquiry. The email creates a ServiceNow ticket with Red Hat. Individual Bugzilla bugs that are migrated will be moved to status "CLOSED", resolution "MIGRATED", and set with "MigratedToJIRA" in "Keywords". The link to the successor Jira issue will be found under "Links", have a little "two-footprint" icon next to it, and direct you to the "Satellite project" in Red Hat Jira (issue links are of type "https://issues.redhat.com/browse/SAT-XXXX", where "X" is a digit). This same link will be available in a blue banner at the top of the page informing you that that bug has been migrated.
Description of problem:
Customer opened a case, mentioning that if /rooot/.hammer/cgi_config.yml is there, the upgrade fails with the following error:
Setup hammer: Configuring Hammer CLI...
Hammer admin password: [FAIL]
Hammer configuration failed: Is the admin password correct? (it was stored in /etc/foreman-maintain/foreman-maintain-hammer.yml)Is the server down?
--------------------------------------------------------------------------------
Scenario [preparation steps required to run the next scenarios] failed.
The following steps ended up in failing state:
[hammer-setup]
Resolve the failed steps and rerun
the command. In case the failures are false positives,
use --whitelist="hammer-setup"
katello-service restart failed! Check the output for error!
Upgrade step restart_services failed. Check logs for more information.
[FAIL]
After quite a lot of testing the upgrade from 6.3.4 to 6.4 on my side (on a pretty fresh RHSAT6.3 install) and asking the customer what he did to fix it, I had to find out that I have to remove the whole /root/.hammer directory in order for the upgrade to go through.
Version-Release number of selected component (if applicable):
RHSAT 6.4
rubygem-foreman_maintain-0.2.11-1.el7sat.noarch
How reproducible:
Always for me if .hammer/ was there.
Steps to Reproduce:
1. Install RHSAT 6.3
2. Try to upgrade to RHSAT 6.4
Actual results:
Upgrade doesn't finish successfully.
Expected results:
Upgrade should finish successfully.
Additional info:
I'm not sure what particular file in /root/.hammer causes this to happen. Only removing cli_config.yml did NOT help. I did not create that files manually, something in RHSAT 6.3 must have created that. So this could affect more users. Eventually we want to introduce an additional step in the documentation, asking the user to remove that directory?
Comment 7Martijn ten Heuvel
2018-10-17 19:14:33 UTC
Extra remarks after some discussions in the Rocketchat channel:
My satellite is a 6.2.2 (or whatever) upgrade to 6.2.x > 6.3.0 > 6.3.x > 6.3.4 > 6.4.0.
In my /root/.hammer I had the following files:
[root@satellite62 .hammerold]# tree
.
├── cli_config.yml
├── cli.modules.d
│ └── foreman.yml
├── defaults.yml
└── log
└── hammer.log
Removing the defaults.yml seems to resolve this, but I do have to test using 'foreman-maintain upgrade run --target-version 6.4.z --whitelist="disk-performance,installer-upgrade"' over and over.
I ran the upgrade command with the defaults.yml in place, it failed, same message as BZ. Then, I renamed the defaults.yml file to kaput.yml and everything worked like a charm.
Contents of the file:
[root@satellite62 .hammer]# cat kaput.yml
---
:defaults:
:organization_id:
:value: '1'
The cli_config.yaml is in place as it was when I initially ran the update, contents like this:
[root@satellite62 .hammer]# cat cli_config.yml
:foreman:
:host: 'https://satellite62.mobile.mth/'
:username: 'admin'
:password: 'password'
:request_timeout: -1
Description of problem: Customer opened a case, mentioning that if /rooot/.hammer/cgi_config.yml is there, the upgrade fails with the following error: Setup hammer: Configuring Hammer CLI... Hammer admin password: [FAIL] Hammer configuration failed: Is the admin password correct? (it was stored in /etc/foreman-maintain/foreman-maintain-hammer.yml)Is the server down? -------------------------------------------------------------------------------- Scenario [preparation steps required to run the next scenarios] failed. The following steps ended up in failing state: [hammer-setup] Resolve the failed steps and rerun the command. In case the failures are false positives, use --whitelist="hammer-setup" katello-service restart failed! Check the output for error! Upgrade step restart_services failed. Check logs for more information. [FAIL] After quite a lot of testing the upgrade from 6.3.4 to 6.4 on my side (on a pretty fresh RHSAT6.3 install) and asking the customer what he did to fix it, I had to find out that I have to remove the whole /root/.hammer directory in order for the upgrade to go through. Version-Release number of selected component (if applicable): RHSAT 6.4 rubygem-foreman_maintain-0.2.11-1.el7sat.noarch How reproducible: Always for me if .hammer/ was there. Steps to Reproduce: 1. Install RHSAT 6.3 2. Try to upgrade to RHSAT 6.4 Actual results: Upgrade doesn't finish successfully. Expected results: Upgrade should finish successfully. Additional info: I'm not sure what particular file in /root/.hammer causes this to happen. Only removing cli_config.yml did NOT help. I did not create that files manually, something in RHSAT 6.3 must have created that. So this could affect more users. Eventually we want to introduce an additional step in the documentation, asking the user to remove that directory?