Found groups that a 365 contacts is member of
If you need to found out whitch groups (mailling groups) a contact is member of in Microsoft 365, then you case use these powershell commands: Replace [email protected] with yours mail address.
Kenneth Qvistgaard Dalbjerg, IT Konsulent i århus
If you need to found out whitch groups (mailling groups) a contact is member of in Microsoft 365, then you case use these powershell commands: Replace [email protected] with yours mail address.
If you wan to know the sync status of a always On availability group database replication, this command can be used:
This is how to get an CSV file, including user_SamAccountName;User_FullName;group1;group2;group3, etc It posible to remove the comment before break, and then break the export after 5 user, to see that it function well. It...
If you need to give auser access to users calendar, based on if there are member of an group, this is the way. Start Exchange Management Shell
1 2 3 4 5 6 7 8 9 10 11 |
$users = Get-ADGroupMember [groupname] | select -ExpandProperty name foreach ($user in $users) { $Mailbox = Get-Mailbox $user #The Calendar, is name "Kalender" in danish add-MailboxFolderPermission -identity “$($Mailbox.Name):\kalender” -AccessRights Editor -User [username] set-MailboxFolderPermission -identity “$($Mailbox.Name):\kalender” -AccessRights Editor -User [username] #English calendar add-MailboxFolderPermission -identity “$($Mailbox.Name):\calendar” -AccessRights Editor -User [username] set-MailboxFolderPermission -identity “$($Mailbox.Name):\calendar” -AccessRights Editor -User [username] } |
If you receive this warning in Group Policy Management, when you are trying to edit an Group policy object: Failed to open the Group Policy Object. You may not have appropriate rights. Details: The...
If you want to change a desktop group logoff behavior, this is done by PowerShell. To turn off shutdown af use:
1 2 |
ASNP Citrix.* Set-BrokerDesktopGroup -Name "Desktop Group Name" -ShutdownDesktopsAfterUse $FALSE |
To turn on shutdown af use:
1 2 |
ASNP Citrix.* Set-BrokerDesktopGroup -Name "Desktop Group Name" -ShutdownDesktopsAfterUse $TRUE |
If you need to get...
I need to get all mailboxes, and witch group there are member of. You need Quest ActiveRoles Management Shell for this to work: http://www.quest.com/powershell/activeroles-server.aspx
1 2 3 4 5 6 7 8 9 10 11 12 13 14 |
Add-PSSnapin Quest.ActiveRoles.ADManagement -ErrorAction SilentlyContinue $File = "C:\groupslog.txt" $Mailboxes = Get-mailbox -resultsize unlimited | select sAMAccountName,name,alias $Mailboxes | ForEach { $User = Get-QADUser -samaccountname $_.sAMAccountName | Select sAMAccountName, memberOf $Line = $_.sAMAccountName ForEach ($GroupDN In $User.memberOf) { $Group = (Get-QADGroup $GroupDN | Select sAMAccountName).sAMAccountName $Line = "$Line,$Group" } echo $Line } | out-File $File |
In the file c:\groupslog.txt each line is a mailbox,...
Sidste kommentar