Solved

How to Get Acceptable Domain Names from Exchange 2010 Server

Posted on 2010-11-23
3
537 Views
Last Modified: 2012-05-10
Can anyone show how to retrieve acceptable domain names from an Exchange Server using any of the following technologies:
    * Powershell
    * SQL Server OpenQuery
    * C# Programming
I currently use the System.Management namespace within managed code (C#), along with an instance of Powershell, to get and/or add mailboxes from/to Exchange. During the process, I also utilize SQL Server's OpenQuery to ping an Active Directory for related information.

One piece that I have not been able to figure out is how to retrieve the current list of acceptable domain names from Exchange. Can someone show or explain how this can be done?
0
Comment
Question by:brian_appliedcpu
3 Comments
 
LVL 76

Accepted Solution

by:
Alan Hardisty earned 250 total points
ID: 34200737
get-accepteddomain

That should list all the accepted domains on your server.

Alan
0
 
LVL 2

Author Comment

by:brian_appliedcpu
ID: 34207125
Alan,
Thanks a bunch. That is what I needed.
I am not an Exchange admin, but I have been assigned the task of creating a GUI to retrieve basic info from Exchange without having to run powershell cmdlets. That being said, I am also trying to list the UPNs. IOWs, within the Exchange mgmt console, if you doulble-click a mailuser account, you can view the properties for that mailbox. Under the Account tab, there is the User Logon Name (user principal name). I have been trying to use Get-User -Identity ... or Get-MailUser -Identity ... (etc.) to list *all* existing UPNs. Do you have any suggestions?
TIA
0
 
LVL 49

Assisted Solution

by:Akhater
Akhater earned 250 total points
ID: 34209379
Get-user username | fl UserPrincipalName
or if you prefer

$user = Get-user username
write-host $user.UserPrincipalName
0

Featured Post

NAS Cloud Backup Strategies

This article explains backup scenarios when using network storage. We review the so-called “3-2-1 strategy” and summarize the methods you can use to send NAS data to the cloud

Question has a verified solution.

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

Learn to move / copy / export exchange contacts to iPhone without using any software. Also see the issues in configuration of exchange with iPhone to migrate contacts.
This article lists the top 5 free OST to PST Converter Tools. These tools save a lot of time for users when they want to convert OST to PST after their exchange server is no longer available or some other critical issue with exchange server or impor…
In this video we show how to create a User Mailbox 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 Recipients >> Mailb…
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…

809 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