This service will be undergoing maintenance at 00:00 UTC, 2017-10-23 It is expected to last about 30 minutes
Bug 1251486 - Automatic installer fails when use.same.password set to true
Automatic installer fails when use.same.password set to true
Status: CLOSED CURRENTRELEASE
Product: JBoss Data Virtualization 6
Classification: JBoss
Component: Installer (Show other bugs)
6.2.0
Unspecified Unspecified
unspecified Severity unspecified
: ER5
: 6.2.0
Assigned To: Emmett Underhill
Jan Stastny
: QA-Closed
: 1252143 (view as bug list)
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2015-08-07 09:00 EDT by Jan Stastny
Modified: 2016-02-10 03:55 EST (History)
4 users (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2016-02-10 03:55:17 EST
Type: Bug
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)

  None (edit)
Description Jan Stastny 2015-08-07 09:00:36 EDT
Description of problem:
When installing with install-script generated from installation in which was selected to use one password for all the users, the installation fails.

Best you can observe it by using such a script but don't provide the '.variables' file. In this way the installer prompts for password. When provided, installer immediately fails, the only output is:

[ Starting automated installation ]
Read pack list from xml definition.
Try to add to selection [Name: Integration Platform Console and Index: 0]
Try to add to selection [Name: Red Hat JBoss DV Platform and Index: 1]
Try to add to selection [Name: Teiid and Index: 2]
Try to add to selection [Name: ModeShape and Index: 3]
Modify pack selection.

When I used -DTRACE=TRUE argument I got a few extra lines:
.
.
.
Read pack list from xml definition.
Try to add to selection [Name: Integration Platform Console and Index: 0]
Try to add to selection [Name: Red Hat JBoss DV Platform and Index: 1]
Try to add to selection [Name: Teiid and Index: 2]
Try to add to selection [Name: ModeShape and Index: 3]
Modify pack selection.
Checking condition.
Checking condition.
UserInputPanel: setting variable use.same.password to true
UserInputPanel: setting variable addUser to true
UserInputPanel: setting variable adminUser to admin
UserInputPanel: setting variable Dashboard.admin.username to dashboardAdmin
UserInputPanel: setting variable Teiid.user.username to teiidUser
UserInputPanel: setting variable Teiid.user.odata to 
UserInputPanel: setting variable Teiid.user.logging to 
UserInputPanel: setting variable Modeshape.user to modeshapeUser
Condition () not found.
Checking condition.
Checking condition.
Checking condition.


I found out, that the only option how to make auto install work is to provide all the passwords in variables, even though only adminPassword should suffice(and installer itself asks only for this one).
This command works well:
java -jar dv-installers/jboss-dv-installer-6.2.0.ER4-redhat-1.jar tmp-workspaces/install.xml -variables Teiid.user.password=p@s\$w0rd,adminPassword=p@s\$w0rd,vault.keystorepwd=p@s\$w0rd,Modeshape.password=p@s\$w0rd

Notice that this command is similar to one used when 'use same password' was NOT selected.


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

How reproducible:
when provided only adminPassword

Steps to Reproduce:
1.Install server with 'use same passwords' option, save auto-install script
2.Start installer with this script, provide no '-variables' arguments, nor '.variables' file
3.Input the adminPassword when prompted.
4.Observe immediate ending of installer process. 

Actual results:
auto installation fails

Expected results:
server is installed

Additional info:
Comment 1 Jan Stastny 2015-08-07 09:07:49 EDT
I am sorry, I forgot to add Dashboard.admin.password to the -variables argument.

This is the workaround command:
java -jar dv-installers/jboss-dv-installer-6.2.0.ER4-redhat-1.jar tmp-workspaces/install.xml -variables Teiid.user.password=p@s\$w0rd,adminPassword=p@s\$w0rd,vault.keystorepwd=p@s\$w0rd,Modeshape.password=p@s\$w0rd,Dashboard.admin.password=p@s\$w0rd
Comment 2 Thomas Hauser 2015-08-07 10:51:28 EDT
Regression caused by https://bugzilla.redhat.com/show_bug.cgi?id=1241129
Comment 3 Emmett Underhill 2015-08-07 16:15:14 EDT
Hi Jan,

The new password validation caused a null pointer exception because some values are null during auto-installation.

I've added the appropriate null checking to the new PasswordValidator class so automated installation no longer fails to run when "use same passwords" is set and there is no variables file.

Thank you,

Emmett Underhill
Comment 4 Jan Stastny 2015-08-11 03:33:51 EDT
*** Bug 1252143 has been marked as a duplicate of this bug. ***
Comment 8 Van Halbert 2015-08-18 11:34:22 EDT
If you run the following:

java -jar jboss-dv-installer-6.2.0.ER4-redhat-1.jar dv_installer.xml

The installer assumes to find the variables file (dv_installer.xml.variables), but will fail because the installation was setup to use one password for all and to not create a new admin user.
Comment 9 Emmett Underhill 2015-08-18 17:08:56 EDT
I've run the installation without a variables file, and with one that contains the adminPassword, both of which I selected to use the same password for all users. The installation succeeds in both of these cases. So yes hopefully the issue has been addressed if I'm understanding correctly.
Comment 10 Jan Stastny 2015-08-19 01:46:57 EDT
Hi Emmett, yes, if the installer works now with both '-variables' argument and automatic script (either provided via '-variableFile' or taken by installer implicitly by filename), then the problem with 'use.same.password' seems resolved.

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