List users from 3 different Active Directory Groups with PowerShell

Here is a quick sample of Power Shell snippet to list users from 3 different Active Directory groups: Import-Module ActiveDirectory $groups = "AWS-IAM-PCI-Prod-Admin","AWS-IAM-PCI-Prod-Deploy","AWS-IAM-PCI-Prod-Monitoring" foreach($group in $groups){Get-ADGroupMember -Identity $group -Recursive |…

Continue ReadingList users from 3 different Active Directory Groups with PowerShell

Find out the current version of the Active Directory Schema

Quick one liner to find out current version of the Active Directory Schema on your network especially of you have mix of servers. Using dsquery utility: dsquery * cn=schema,cn=configuration,dc=domainname,dc=local -scope…

Continue ReadingFind out the current version of the Active Directory Schema

Remove all Group Membership from Disabled user except Domain User Group in PowerShell

Here is quick PowerShell script to remove ALL Group Membership from Disabled user in Active Directory. We will remove all Group membership from this user except Domain User group. So…

Continue ReadingRemove all Group Membership from Disabled user except Domain User Group in PowerShell

Report on user count in Active Directory with PowerShell

Here is quick [easyazon_link identifier="1787122042" locale="US" tag="wn0d5-20"] PowerShell [/easyazon_link] script that provides information on user count in [easyazon_link identifier="1782175997" locale="US" tag="wn0d5-20"] Active directory [/easyazon_link]: Total Number of All user accounts…

Continue ReadingReport on user count in Active Directory with PowerShell

List Direct Reports to Manager in PowerShell

Here is the task for today to use [easyazon_link identifier="1787122042" locale="US" tag="wn0d5-20"] PowerShell [/easyazon_link]. I was asked to find the list of employees under a specific manager. In [easyazon_link identifier="1449361420"…

Continue ReadingList Direct Reports to Manager in PowerShell

Change or Update UPN for users of specific group in Active Directory

Here is a quick almost one liner in [easyazon_link identifier="B07883YKV1" locale="US" tag="wn0d5-20"] PowerShell [/easyazon_link] to update/change UPN for users of specific group in [easyazon_link identifier="1449361420" locale="US" tag="wn0d5-20"]Active Directory [/easyazon_link]. Lets…

Continue ReadingChange or Update UPN for users of specific group in Active Directory

How to install PowerShell on Google Chromebook Linux mode

Here is quick code for installation of PowerShell on Google ChromeBook Pixel when [easyazon_link identifier="1118999878" locale="US" tag="wn0d5-20"] Linux [/easyazon_link] support is turned on: [cc lang="Bash"]sudo apt install curl gnupg apt-transport-https…

Continue ReadingHow to install PowerShell on Google Chromebook Linux mode