[PUP-4396] Group Created when "members" Parameter Contains Invalid User Created: 2015/04/09  Updated: 2017/05/17  Resolved: 2016/09/22

Status: Closed
Project: Puppet
Component/s: Windows
Affects Version/s: PUP 3.8.0
Fix Version/s: None

Type: Bug Priority: Normal
Reporter: Ryan Gard Assignee: Unassigned
Resolution: Won't Fix Votes: 0
Labels: windows
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Agent: Windows 2003 R2 x64

Attachments: PNG File win_bug_group_with_invalid_member.PNG    
Issue Links:
relates to PUP-3653 Unable to create/force empty Windows ... Closed
Team: Agent
Story Points: 2



If a user attempts to create a Windows group with a member that does not exist the group will be created, but no members will be present.


  • Screen Shot

Repro Steps

  1. Install Puppet agent on Windows node.
  2. Attempt to create a group with invalid member specified:

    puppet apply -e "group { 'Peeps': ensure => 'present', members => ['W2K8R2-1\Guest','W2K8R2-1\Meows'], }"


The Puppet run will fail and no group will be created.


The Puppet run fails, but the group is created with no members:

C:\>puppet apply -e "group { 'Peeps': ensure => 'present', members => ['xg1ongd9
bpi1rsf\Guest','xg1ongd9bpi1rsf\Meows'], }"
Notice: Compiled catalog for xg1ongd9bpi1rsf.delivery.puppetlabs.net in environm
ent production in 0.23 seconds
Error: Could not resolve username: xg1ongd9bpi1rsf\Meows
Error: /Stage[main]/Main/Group[Peeps]/ensure: change from absent to present fail
ed: Could not resolve username: xg1ongd9bpi1rsf\Meows
Notice: Finished catalog run in 0.06 seconds

Comment by Ryan Gard [ 2015/04/09 ]

Not sure what the expected behavior is, it just seemed odd to me. The "user" resource type works in a similar way so at least we are consistent.

Comment by Rob Reynolds [ 2015/04/10 ]

The group should be created. However the adding of users (and similar on the user resource) should throw an error.

Comment by Rob Reynolds [ 2015/04/10 ]

Looks like it does do that but it doesn't tell you that the group/user was created successfully. Seems like the user/group creation should be noted separately from the adding of users/groups or fail as a whole. Unfortunately I think we would be limited to the second (fail as a whole) with Puppet since it is a change to one resource.

Comment by Moses Mendoza [ 2016/09/22 ]

This ticket has not been updated in some time and is now closed due to inactivity. If any viewer/watcher feels this is inaccurate, please re-open this ticket.

Generated at Wed Apr 01 14:50:15 PDT 2020 using Jira 8.5.2#805002-sha1:a66f9354b9e12ac788984e5d84669c903a370049.