problems with exchange 2010 shell

Posted on 2013-11-08
Last Modified: 2013-11-08
im trying to run a simple script to get a list of members in a exchange dynamic distribution group
im using rthe following code

Get-DistributionGroupMember -identity “group name” | Export-CSV C:\MyFile.Csv

but it keeps giving an error saying the object cannot be found
i have tried several groups and it cant find any
these groups do exist

here is the error

The operation couldn't be performed because object 'group name' couldn't be found on ''.
    + CategoryInfo          : InvalidData: (:) [Get-DistributionGroupMember], ManagementObjectNotFoundException
    + FullyQualifiedErrorId : F05C848C,Microsoft.Exchange.Management.RecipientTasks.GetDistributionGroupMember
Question by:dougdog
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
LVL 19

Expert Comment

by:Raheman M. Abdul
ID: 39633248
Open Exchange Management Shell and run:

Set-ADServerSettings -ViewEntireForest $True
Get-DistributionGroupMember -identity “group name” | Export-CSV C:\MyFile.Csv

Author Comment

ID: 39633344
seems Get-DistributionGroupMember does not work with dynamic groups

Accepted Solution

Muralidharan R earned 500 total points
ID: 39633372
yes.  Get-DistributionGroupMember does not work with the dynamic groups.

dynamic DL's are based on specific recipient filters rather than a defined set of recipients.

you need to use Get-DynamicDistributionGroup to get hte properties of dynamic DL.

Expert Comment

ID: 39633691
Have you run it (a PS console)  an administrator?

Featured Post

MS Dynamics Made Instantly Simpler

Make Your Microsoft Dynamics Investment Count  & Drastically Decrease Training Time by Providing Intuitive Step-By-Step WalkThru Tutorials.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

A quick Powershell script I wrote to find old program installations and check versions of a specific file across the network.
In this post we will be converting StringData saved within a text file into a hash table. This can be further used in a PowerShell script for replacing settings that are dynamic in nature from environment to environment.
In this video we show how to create an Address List in Exchange 2013. We show this process by using the Exchange Admin Center. Log into Exchange Admin Center.: First we need to log into the Exchange Admin Center. Navigate to the Organization >> Ad…
In this Micro Video tutorial you will learn the basics about Database Availability Groups and How to configure one using a live Exchange Server Environment. The video tutorial explains the basics of the Exchange server Database Availability grou…

688 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question