Bug 1284717

Summary: On RHEL 7.2 environments, ssh access fails when a user is created using the 'user' module
Product: [Community] khaleesi Reporter: Ronelle Landy <rlandy>
Component: rdo-managerAssignee: wes hayutin <whayutin>
Status: CLOSED WONTFIX QA Contact: Attila Darazs <adarazs>
Severity: unspecified Docs Contact:
Priority: unspecified    
Version: unspecifiedCC: jschluet
Target Milestone: ---Keywords: Automation, AutomationBlocker
Target Release: ---   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2018-04-16 16:30:39 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description Ronelle Landy 2015-11-24 00:52:33 UTC
Description of problem:

On RHEL 7.2 platforms, executing:
user: name="<user-name>" state=present password=<user-password> creates the user but trying to ssh to the host with that user will fail.
The following warning is seen:

useradd: warning: the home directory already exists.
Not copying any file from skel directory into it.

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

RHEL 7.2 (RC 1-1)
Ansible 1.9.2

How reproducible:

Always on baremetal environments
Sometimes on vrt env when reprovisioning is done prior

Steps to Reproduce:
1. Install RHEL 7.2 (RC 1-1) on a host machine
2. Run an Ansible playbook that create a user like: 
user: name="<user-name>" state=present password=<user-password>
3. ssh from a remote host to the host machine as the user created

Actual results:

ssh fail authentication

Expected results:

should be able to ssh into the host machine when a user is created with reqired passwors or key files

Additional info:

workarounds:

      shell: >
        userdel -f <user>;
        rm -rf /home/<user>;
        useradd <user>

or

user: name="<user>" state=absent password=<user password> 
user: name="<user>" state=present password=<user password>