Note: This is a beta release of Red Hat Bugzilla 5.0. The data contained within is a snapshot of the live data so any changes you make will not be reflected in the production Bugzilla. Also email is disabled so feel free to test any aspect of the site that you want. File any problems you find or give feedback here.
Bug 1574526 - satellite-installer imports pgsql data during new installation
Summary: satellite-installer imports pgsql data during new installation
Keywords:
Status: NEW
Alias: None
Product: Red Hat Satellite 6
Classification: Red Hat
Component: Installer
Version: 6.3.1
Hardware: All
OS: Linux
high
high vote
Target Milestone: Unspecified
Assignee: satellite6-bugs
QA Contact: Perry Gagne
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2018-05-03 13:31 UTC by Sam Yangsao
Modified: 2019-03-30 03:27 UTC (History)
4 users (show)

Fixed In Version:
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
: 1686950 1686952 1686956 1686960 1686962 1686969 1686995 1687013 1687017 1687021 (view as bug list)
Environment:
Last Closed:
Target Upstream Version:


Attachments (Terms of Use)

Description Sam Yangsao 2018-05-03 13:31:47 UTC
Description of problem:

"satellite-installer --scenario satellite" may use stale pgsql data and import the data during a new installation

Version-Release number of selected component (if applicable):

RHEL 7.5
Satellite 6.3.1

How reproducible:

Always

Steps to Reproduce:

1.  Install a new RHEL host with mounted filesystems following guidelines [1]:

/var/lib/pgsql
/var/lib/mongodb

2.  Install Satellite server bits

# yum install satellite
# satellite-installer

3.  Remove [2] Satellite 6.3 server bits:

# katello-remove

4.  Change hostname to something else

# hostnamectl set-hostname satname2

5.  Install Satellite server bits again

# yum install satellite
# satellite-installer

Actual results:

Satellite installer uses the stale data from /var/lib/pgsql and this results in two default/local capsules being created.

Install tells the user that it completes successfully, unaware of the creation of the two default/local capsules.

Expected results:

Satellite installer should detect the old /var/lib/pgsql data during a new initial installation and warn the user about the data still existing.

Option to completely remove the data during the Satellite installer process.

Additional info:

[1] https://access.redhat.com/documentation/en-us/red_hat_satellite/6.3/html-single/installation_guide/#hardware_storage_prerequisites

[2] https://access.redhat.com/documentation/en-us/red_hat_satellite/6.3/html-single/installation_guide/#uninstalling_satellite_and_capsule_servers

Comment 1 Brad Buckingham 2018-05-15 15:54:46 UTC
Hi Sam,

It looks like this bug is a side affect of bug 1574257; therefore, should we close this one?

Comment 3 Sam Yangsao 2018-05-15 16:06:45 UTC
(In reply to Brad Buckingham from comment #1)
> Hi Sam,
> 
> It looks like this bug is a side affect of bug 1574257; therefore, should we
> close this one?

It is because of it, but we should still IMHO have the installer check to make sure the filesystem is completely empty before installing the bits.

Just kind of scary that it can still import that information somehow when running a fresh installation.

Comment 4 Craig Donnelly 2018-05-15 17:45:39 UTC
Sam,

You are far from running a fresh installation if you have installed Satellite, and then performed a katello-remove.

This is not a full-service item (today) to let you cleanly start over with Satellite.

If you had previously installed Satellite, you should be using the --reset option on the next installer run which will include dropping the databases before performing installation.

This has always been the case, and often it is recommended simply to reinstall RHEL after /attempting/ an installation - because katello-remove is quite far from covering all facets of items that are added or configuring during an installation.

Comment 5 Sam Yangsao 2018-05-15 19:52:24 UTC
Craig,

Thanks I understand what you're saying.  But per the customers view, and I do tend to agree with them, they shouldn't have to reinstall everything every time something goes awry with Satellite.  

We see this quite often, "oh it's broke, just reinstall from a clean start".

Customers prefer not to reinstall because of the amount of work it took them to build the physical server from the ground up.  

In this situation, the customer and I relied on katello-remove to do its job and "remove" the data directories cleanly.  Of course, it did not and we spent a few days trying to figure out the capsule id issue and also why this occurred.

It would've been nice that the *if* the installer would've said "Hey, there's data here, should we remove this data before proceeding?" versus a few days of trying to find out why stuff didn't work and that the installer say that everything installed correctly, delaying yet another migration and causing the customer to lose additional confidence in this product.


Note You need to log in before you can comment on or make changes to this bug.