Project

General

Profile

Actions

Bug #21517

closed

katello-change-hostname should remove last_scenario.yml only after success of installer

Added by John Mitsch about 7 years ago. Updated over 6 years ago.

Status:
Closed
Priority:
Normal
Category:
Tooling
Target version:
Difficulty:
easy
Triaged:
Fixed in Releases:
Found in Releases:

Description

Cloned from https://bugzilla.redhat.com/show_bug.cgi?id=1507848

Some time ago I filed http://projects.theforeman.org/issues/21079, it's currently in backlog, but I'd like it to be revisited due to issues related to https://bugzilla.redhat.com/show_bug.cgi?id=1466688#c14

The above bug forces the installer and hence k-c-h to require a full path on certs tar. If you don't do this on the first try, there is no second try due to deleted last_scenario.yml

Example rename session on 6.3 capsule:

]# katello-change-hostname new.name.com -u admin -p changeme --certs-tar new.name-certs.tar
...
[ INFO 2017-10-31 05:17:16 verbose] Running installer with args "--scenario", "capsule", "-v", "--foreman-proxy-register-in-foreman", "false", "--foreman-proxy-content-certs-tar", "new.name.com-certs.tar", "--disable-system-checks"
[ERROR 2017-10-31 05:17:16 verbose] Parameter foreman-proxy-content-certs-tar invalid: new.name.com-certs.tar is not one of regexes matching /^(([a-zA-Z]:[\\\/])|([\\\/][\\\/][^\\\/]+[\\\/][^\\\/]+)|([\\\/][\\\/]\?[\\\/][^\\\/]+))/ or regexes matching /^\/([^\/\0]+\/*)+$/

now retrying with full path:

]# satellite-change-hostname new.name.com -u admin -p changeme --certs-tar /root/new.name-certs.tar
/usr/share/katello/helper.rb:4:in `readlink': No such file or directory - /etc/foreman-installer/scenarios.d/last_scenario.yaml (Errno::ENOENT)
from /usr/share/katello/helper.rb:4:in `last_scenario'
from /usr/share/katello/hostname-change.rb:21:in `initialize'
from /usr/sbin/satellite-change-hostname:20:in `new'
from /usr/sbin/satellite-change-hostname:20:in `<main>'

So if 1466688 is not fixed, we need to (a) update docs (will file a bug), (b) make sure there is an option to retry (this bug)


Related issues 1 (0 open1 closed)

Has duplicate Katello - Bug #21252: katello-change-hostname- doesn't delete last scenario fileClosedJohn Mitsch10/09/2017Actions
Actions #1

Updated by John Mitsch about 7 years ago

  • Is duplicate of Bug #21252: katello-change-hostname- doesn't delete last scenario file added
Actions #2

Updated by John Mitsch about 7 years ago

  • Is duplicate of deleted (Bug #21252: katello-change-hostname- doesn't delete last scenario file)
Actions #3

Updated by John Mitsch about 7 years ago

  • Has duplicate Bug #21252: katello-change-hostname- doesn't delete last scenario file added
Actions #4

Updated by Justin Sherrill about 7 years ago

  • Subject changed from katello-change-hostname should remove last_scenario.yml only after success of installer to katello-change-hostname should remove last_scenario.yml only after success of installer
  • Category set to Tooling
  • Translation missing: en.field_release set to 114
Actions #5

Updated by Jonathon Turel almost 7 years ago

  • Status changed from New to Assigned
  • Assignee set to Jonathon Turel
  • Difficulty set to easy
Actions #6

Updated by Jonathon Turel almost 7 years ago

  • Target version set to 242
  • Translation missing: en.field_release changed from 114 to 329
Actions #7

Updated by The Foreman Bot almost 7 years ago

  • Status changed from Assigned to Ready For Testing
  • Pull request https://github.com/theforeman/foreman-packaging/pull/2110 added
Actions #8

Updated by Brad Buckingham almost 7 years ago

  • Target version changed from 242 to 245
Actions #9

Updated by Justin Sherrill almost 7 years ago

  • Translation missing: en.field_release changed from 329 to 339
Actions #10

Updated by Jonathon Turel almost 7 years ago

  • Status changed from Ready For Testing to Closed
Actions #11

Updated by John Mitsch over 6 years ago

  • Translation missing: en.field_release changed from 339 to 338
Actions

Also available in: Atom PDF