[Documentation] full and clean uninstall process

Problem:

Hi,

There is no full and clean uninstall process for remove entirely foreman and components

Regards
Expected outcome:

Foreman and Proxy versions:

Foreman and Proxy plugin versions:

Distribution and version:

Other relevant data:

My understanding is that the installation guide assumes Foreman will be the only service running on the host you’ve selected to install Foreman on. This means that you can simply destroy the VM/format the bare metal host (and potentially start over) if you decide to stop using Foreman.

If you want to reinstall Foreman after a botched/misconfigured installation, it’s also probably best to start with a clean/fresh OS once again.

1 Like

Hi,

Thank you for your reply.

If you want to reinstall Foreman after a botched/misconfigured installation, it’s also probably best to start with a clean/fresh OS once again.

It’s the problem. In professional environment, if you don’t have access to hypervisor or bare metal you cannot wait for a “new vm”.
After a dirty installation it will be very awesome to have a process to clean foreman installation and it’s components.

The “fire&forget” method is not a solution in professional environment

regards

If you need to rerun the installation your best bet is probably just to fix whatever issue caused your installation to fail, and then simply rerun the installation. In general the installation is pretty aggressive about “correcting” whatever was there from any possible previous installation attempts.

As @quba42 said, the installer will ensure the components in a certain state. The installer does not manage the data so there is a --reset-data flag (used to be --reset I think, check your version) to remove data from databases.

I don’t really see a benefit in some cleanup script that removes all of the components. There are too many edge cases IMHO.

Hi,

Thank you for your reply, I understand why a cleanup script don’t really gives a benefit. AS @quba42 said, the installation is “pretty agressive”.
I would understand each technical installed stack to correct some dazed and confused state.

When foreman is deployed we have :

  • foreman
  • puppet
  • postgresql
  • redis
  • webrick
  • openjdk
  • dynflow sidekick
  • other things ?

Is there a documentation who list every stack installed ?

Thank you
Regards

Running foreman-maintain service list on your installation will give you a pretty good idea of what background services are part of your foreman installation.

Example:

# foreman-maintain service list
Running Service List
================================================================================
List applicable services: 
foreman-proxy.service                         enabled 
foreman.service                               enabled 
httpd.service                                 enabled 
postgresql.service                            enabled 
pulp_celerybeat.service                       enabled 
pulp_resource_manager.service                 enabled 
pulp_streamer.service                         enabled 
pulp_workers.service                          enabled 
puppetserver.service                          enabled 
qdrouterd.service                             enabled 
qpidd.service                                 enabled 
rh-mongodb34-mongod.service                   enabled 
rh-redis5-redis.service                       enabled 
smart_proxy_dynflow_core.service              enabled 
squid.service                                 enabled 
tomcat.service                                enabled

All services listed                                                   [OK]
--------------------------------------------------------------------------------
1 Like

Thank you for this usefull tips !

I forgot to specify my distribution, i run with Ubuntu and the foreman-maintain package for Ubuntu is not ready : Is foreman-maintain supported on Ubuntu? - #8 by Lud97x

If you can read Ruby, the following might be helpful.

It’s not entirely what you’re looking for, but that lists the possible services. Some of those are irrelevant since they’re Katello-only.

1 Like

Hi,

Thank you for your help it is very usefull !

regards