Foreman-installer error upgrade from 3.8.0-rc2 to 3.8 GA

Problem:
When running foreman-installer --scenario katello after upgrade from 3.8.0-rc2 to 3.8.0-1
I get below error message:

Expected outcome:
No errors.
Running foreman-installer in current 3.8.0-rc2 does not generate any errors.

Foreman and Proxy versions:
3.8.0-rc2

Foreman and Proxy plugin versions:
foreman-tasks 8.2.0
foreman_ansible 12.0.7
foreman_puppet 6.0.1
foreman_remote_execution 11.0.0
foreman_rh_cloud 8.0.48
foreman_scc_manager 2.3.0
foreman_templates 9.4.0
foreman_virt_who_configure 0.5.16
katello 4.10.0.rc2

Distribution and version:

Other relevant data:

2023-10-26 13:05:53 [NOTICE] [configure] 250 configuration steps out of 1993 steps complete.
2023-10-26 13:05:59 [ERROR ] [configure] Failed to generate new keystore with temporary entry: Execution of ‘/bin/keytool -genkey -storetype pkcs12 -keystore /etc/candlepin/certs/keystore -storepass:file /etc/pki/katello/keystore_password-file -alias temporary-entry -dname CN=temporary-entry -J-Dcom.redhat.fips=false’ returned 1: keytool error: java.lang.Exception: The -keyalg option must be specified.
2023-10-26 13:06:00 [ERROR ] [configure] Failed to generate new truststore with temporary entry: Execution of ‘/bin/keytool -genkey -storetype pkcs12 -keystore /etc/candlepin/certs/truststore -storepass:file /etc/pki/katello/truststore_password-file -alias temporary-entry -dname CN=temporary-entry -J-Dcom.redhat.fips=false’ returned 1: keytool error: java.lang.Exception: The -keyalg option must be specified.
2023-10-26 13:06:01 [NOTICE] [configure] 500 configuration steps out of 1993 steps complete.
2023-10-26 13:06:02 [ERROR ] [configure] Failed to add certificate to keystore: Execution of ‘/bin/keytool -importkeystore -noprompt -srckeystore /tmp/temp_keystore20231026-328597-4bdg3g -srcstorepass:file /etc/pki/katello/keystore_password-file -destkeystore /etc/candlepin/certs/keystore -deststorepass:file /etc/pki/katello/keystore_password-file -srcalias tomcat -destalias tomcat -J-Dcom.redhat.fips=false’ returned 1: Importing keystore /tmp/temp_keystore20231026-328597-4bdg3g to /etc/candlepin/certs/keystore…
2023-10-26 13:06:02 [ERROR ] [configure] keytool error: java.lang.Exception: Keystore file exists, but is empty: /etc/candlepin/certs/keystore
2023-10-26 13:06:03 [NOTICE] [configure] 750 configuration steps out of 1998 steps complete.

There was an issue introduced in 3.8.0-rc2 that was fixed in 3.8.0 GA but as we do not test upgrades between RC versions you can wind up in this state. I would remove /etc/candlepin/certs/keystore and /etc/candlepin/certs/truststore and re-run the installer. These files will get re-built by the installer.

Thank you for fast reply.
Did as you suggested but still receive same issue.
First thing it is complaining about is that the -keyalg option is missing from the keytool -genkey … command.

Pretty sure you should just run “foreman-installer” after an upgrade → Upgrading Foreman to 3.8

… and when I do run “foreman-installer --scenario katello” after the upgrade the issue occur.

What OS are you on?

I’m on RedHat 8.8.

With the default Java? nothing customized on the system?

Thank you very much for mention java!!
That reminded me that I installed a second java version recently for use by an agent service.
I reverted default java back to 1.8 and now the installer went thru without any issues.
Again thank you for fast response.