< Back

Get-ADGroupMembershipAddInfo

Fri Jan 10, 2020 7:01 pm

NAME Get-ADGroupMembershipAddInfo



SYNOPSIS

Uses replication metadata to find when a member was added to a group.





SYNTAX

Get-ADGroupMembershipAddInfo [-GroupMember] <String> [-Group] <String> [[-MemberDomain] <String>] [[-GroupDomain]

<String>] [-GetLog] [-UseActiveDirectoryPowershell] [-Credential <PSCredential>] [-PassThru] [<CommonParameters>]



Get-ADGroupMembershipAddInfo [-GroupMember] <String> [-Group] <String> [[-MemberDomain] <String>] [[-GroupDomain]

<String>] [-GetLog] [-UseRepAdmin] [-Credential <PSCredential>] [-PassThru] [<CommonParameters>]





DESCRIPTION

The cmdlet gathers the replication metadata to find when a member was added to a group. This data can be used to

search the logs on the identified Domain Controller to find who added the member.





PARAMETERS

-GroupMember <String>

The Identity of the group member that was added. This can be the SAM Account Name, Display Name, Name, or CN.



Required? true

Position? 1

Default value

Accept pipeline input? false

Accept wildcard characters? false



-Group <String>

The Identity of the group. This can be the SAM Account Name, Display Name, Name, or CN.



Required? true

Position? 2

Default value

Accept pipeline input? false

Accept wildcard characters? false



-MemberDomain <String>

Optionally indicates the domain the group member exists in. If this parameter is not specified, the domain of

the local user or computer is used, depending on what is specified for

the GroupMember parameter.



Required? false

Position? 3

Default value [System.String]::Empty

Accept pipeline input? false

Accept wildcard characters? false



-GroupDomain <String>

Optionally indicates the domain the group exists in. If this parameter is not specified, the domain of the

group member is used.



Required? false

Position? 4

Default value [System.String]::Empty

Accept pipeline input? false

Accept wildcard characters? false



-GetLog [<SwitchParameter>]

Indicates whether to try and retrieve any available log files from the server matching the change. Defaults to

true.



Required? false

Position? named

Default value False

Accept pipeline input? false

Accept wildcard characters? false



-UseActiveDirectoryPowershell [<SwitchParameter>]

Uses the Active Directory Powershell module to retrieve replication metadata. The default selection.



Required? false

Position? named

Default value False

Accept pipeline input? false

Accept wildcard characters? false



-UseRepAdmin [<SwitchParameter>]

Uses the repadmin command line function and parses the output.



Required? false

Position? named

Default value False

Accept pipeline input? false

Accept wildcard characters? false



-Credential <PSCredential>

Specifies a user account that has permission to perform this action. The default is the current user.



Type a user name, such as "User01" or "Domain01\\User01", or enter a PSCredential object, such as one generated

by the Get-Credential cmdlet. If you type a user name, you will be prompted for a password.



Required? false

Position? named

Default value [System.Management.Automation.PSCredential]::Empty

Accept pipeline input? false

Accept wildcard characters? false



-PassThru [<SwitchParameter>]

If specified, will return the log object and not just display data.



Required? false

Position? named

Default value False

Accept pipeline input? false

Accept wildcard characters? false



<CommonParameters>

This cmdlet supports the common parameters: Verbose, Debug,

ErrorAction, ErrorVariable, WarningAction, WarningVariable,

OutBuffer, PipelineVariable, and OutVariable. For more information, see

about_CommonParameters (https:/go.microsoft.com/fwlink/?LinkID=113216).



INPUTS

None





OUTPUTS

System.Management.Automation.PSObject





NOTES





AUTHOR: Michael Haken

LAST UPDATE: 1/5/2017



-------------------------- EXAMPLE 1 --------------------------



PS C:\\>Get-ADGroupMembershipAddInfo -GroupMember Administrator -Group "Account Operators" -GetLog



Writes out the server and time the member was added and attempts to retrieve the log file from the specified

server for additional information which is written out to the pipeline.











RELATED LINKS