In any environment if the employee leaves the company you have to disable the user account in active directory, all the disabled users are still there in the Distribution list and security groups and have to remove the disabled user account manually
If you want to know all the disabled users from the active directory group use the below command
This command will list the members from the active directory group with the status
Find the command to get the members status from the group (Account disabled or not)
Group name: sales_executes
Syntax:
dsquery group -samid “Group Pre-Win2k Name” | dsget group -members | dsget user -disabled -display
Example:
dsquery group -samid sales_executes | dsget group -members | dsget user -disabled -display
Related Articles
List active directory group members
HRH3U2HJWH9H
Does the battle sport a such contour?