What are different types of DNS records

Types of DNS Records

A Record
An A record or address record. Address Record, assigns an IP address to a domain or subdomain name.Suppose we have xyz.com domain and want to assign IP address to your web server, then weshould create an A record with xyz.com as Fully Qualified Domain Name and “” in the value field.

CNAME Record
A CNAME record or canonical name record makes one domain name an alias of another. e.g.

mail.xyz.com IN CNAME mail.xyz.net

MX Record
An MX record or mail exchange record maps a domain name to a list of mail exchange servers

xyz.com. 3600 IN MX 0 xyz.com.

The first entry 3600 is the TTL (Time to Live). This record tells other DNS-servers (and clients) that it is OK to cache the above record for up to 3600 seconds (or one hour). The second numerical value is ‘0’ and is the MX-record priority. In this example, it doesn’t matter, as we only have one record, but if we were to have multiple records, it would determine the priority order of the servers. If the first one fails, the second one will be used, and so on.

It is important that there be a dot(“.”) after the domain name in the MX record. If the dot is absent, it routes to “xyz.com.xyz.com”. The number 0, indicates Preferance number. Mail is always routed to the server which has the lowest Preferance number. If there is only one mail server, it is safe to mark it 0.

Example – Multiple mail servers

xyz.com. 14400 IN MX 0 xyz.com.
xyz.com. 14400 IN MX 30 server2.xyz.com

PTR Record
A PTR record is reverse DNS lookup for an address. e.g. xyz.com has the IP address, a PTR record would be IN PTR xyz.com

Many email servers do a reverse DNS lookup to check if the host is actually coming from where it claims to come from. It is always advisable to have a proper reverse PTR record when you are running a mail / smtp server.

NS Record
An NS record or name server record maps a domain name to a list of DNS servers authoritative for that domain. Delegations depend on NS records.
Example of NS Record With syntax

xyz.com. IN NS ns1.xyz.com.

IN indicates the Internet
NS indicates the type of record which Name Server record
The above indicates that the ns1.xyz.com is the authoritative server for the domain xyz.com

SOA Record
An SOA record or start of authority record specifies the DNS server providing authoritative information about an Internet domain, the email of the domain administrator, the domain serial number, and several timers relating to refreshing the zone.

TXT Record
A TXT record allows an administrator to insert arbitrary text into a DNS record. For example, this record is used to implement the Sender Policy Framework specification.

SPF domains have to publish at least two directives: a version identifier and a default mechanism.

xyz.com. TXT “v=spf1 -all”

This is the simplest possible SPF record: it means your domain xyz.com never sends mail. It makes sense to do this when a domain is only used for web services and doesn’t do email. If MX servers send mail, designate them.

xyz.com. TXT “v=spf1 mx -all”

Let’s pretend xyz.com has two MX servers, mx1 and mx2. They would both be allowed to send mail from wyz.com.

xyz.com. TXT “v=spf1 mx ptr -all”



Create a Distribution & Security Group using Exchange Management Shell

How to Create a Distribution & Security Group using Exchange Management Shell

Using Exchange Management Shell Create a Distribution Group

New-DistributionGroup -Name “PD-TEST” -DomainController server1.domain.com -OrganizationalUnit “domain.com/OU name” -SAMAccountName “PD-TEST” -Type “Distribution”


Note : Any value marked in red is a variable and has to be altered as per requirement

Using Exchange Management Shell Create a Security Group

New-DistributionGroup -Name “PD-TEST” -DomainController server1.domain.com -OrganizationalUnit “domain.com/OU name” -SAMAccountName “PD-TEST” -Type “Security”


Note : Any value marked in red is a variable and has to be altered as per requirement

How to Export all distribution Group and All members of it (Exchange 2007 & Exchange 2010 & Exchange 2013

In some situations we had to Export all the Distribution group and all the members of it to a CSV file

 I have  a script which will make Exchange Administrators life Easy

 .Requires -version 2 – Runs in Exchange Management Shell

.\DistributionGroupMemberReport.ps1 – It Can Display all the Distribution Group and its members on a List

Or It can Export to a CSV file 

Download the Script

 Browse the Shell to the Appropriate Location 


Run it as above

 Output of CSV file look like Below

You can add some more entries if required


  Download the Script




How to Create a Distribution & Security Group using Exchange Management Shell

Using Exchange Management Shell Create a Distribution Group

New-DistributionGroup -Name “PD-TEST” -DomainController server1.domain.com -OrganizationalUnit “domain.com/OU name” -SAMAccountName “PD-TEST” -Type “Distribution”


Note : Any value marked in red is a variable and has to be altered as per requirement

Using Exchange Management Shell Create a Security Group

New-DistributionGroup -Name “PD-TEST” -DomainController server1.domain.com -OrganizationalUnit “domain.com/OU name” -SAMAccountName “PD-TEST” -Type “Security”


Note : Any value marked in red is a variable and has to be altered as per requirement

Use the Graphical Installation for your Exchange Server 2010 Deployment

I’m finally ready to install my first Microsoft Exchange 2010 Server and the easy way to remember how to do this is to do it based off the Server Roles.

For example, the core roles are the CAS, Hub Transport and Mailbox roles. These are the minimum roles you need for a working mail system. Remember it in alphabetical order.


When you do your deployment, you first need to do the CAS role, then the Hub Transport, then the Mailbox server role.

If I were doing just a single server deployment, I could put all three roles on the same box and install them all at the same time. But I’m doing a phased deployment and I’ve got my roles spread out on multiple servers.

I’ll have a group of servers run the CAS and Hub roles first.

Then, my Mailbox server roles will run on independent servers.

To get started, I’ve already downloaded and extracted my Exchange 2010 SP1 media, on the C drive under the E2010 SP1 folder.

I’ve got my prerequisites installed and I’m ready to run setup.exe. This is the Graphical Installation Wizard. If you have UAC enabled, you might want to right-click and run as administrator.

This will bring up your Exchange 2010 installation landing page.

Choose an option here for language. I’ll choose install languages only from the DVD. Then I’ll be able to install Exchange.

Once the introduction screen comes up, hit Next.

Then you’ll get the typical license agreement. Accept that. Hit Next.

Error Reporting can be On or Off.

This will send your errors out to Microsoft for review. I’ll leave this on No for now and hit Next.

Next, indicate the installation type or which roles you want to install.

The typical installation installs the core roles – Client Access, Mailbox and Hub transport roles – all on this one machine.

I don’t want to do a typical install. I want to break up the distribution of roles in my environment. I want to do a custom installation. I’ll go to the next screen and pick and choose the roles that will be installed.

The option at the bottom lets me automatically install Windows Server roles and features. There are IIS perquisites and different items that a CAS Server or a Hub Server might need that are different than the Mailbox Server. I’ll check this box, and Exchange Server will figure that out for me.

Hit Next.

The server that I’m on is my CAS/Hub server. I’ll select the Client Access role and the Hub Transport role. Notice it tells you the disk space required and the space that’s available. I’ll hit Next.

On this screen, indicate the namespace to use for external Client Access.

We’ll get into enabling CAS for Internet access in another video. Right now, I’ll leave this empty and hit Next.

Since I’m installing my first Hub transport server into an Exchange Server 2003 organization, I need to choose an Exchange 2003 Bridge Head Server.

I’ll hit Browse and select my 2003 Server. This will allow mail flow to go between Exchange 2003 and my 2010 servers, and back and forth.

For now I’m not joining the customer experience improvement program. I’ll hit Next.

Now we’ll go through some Readiness Checks. It’s going to see if I’ve got my operating system prerequisites taken care of. It’s also going to make sure that everything in Active Directory is good to go. Once that all clears out, I’ll be ready to proceed with the installation.

Now my Readiness Checks are completed. Everything looks good.

I’ll click install. Depending on the speed of this server, this could take 20-30 minutes.

Eventually, it should come back and let you know whether it was successful. Typically, the error messages will be very descriptive. If something went wrong, you’ll figure it out pretty easily.

The installation is complete now. At the top, the elapsed time was almost 12 minutes. We got green ticks on everything. Looks good, and everything installed just fine.

Before I hit Finish, I could select “Finalize this installation using the Exchange Management Console.” This would launch the graphical tools that would let let me go in and manage my Exchange environment. Because I don’t have a Mailbox role yet, I’ll uncheck that and hit Finish.

An alert comes up recommending I do a reboot before placing this server into production. I’ll need to make sure that I’ve got the latest updates for Exchange and patches in place and all that good stuff.

The next step in our deployment will be to deploy our Mailbox server role.

Deploying Exchange Server 2010 – Identify Software Requirements

For this Exchange Server 2010 training video, I’m using Windows Server 2008 R2. Let’s go into the System Properties and take a look at the configuration of this machine.

I’m running Windows Server 2008 R2 Enterprise with Service Pack 1.

This version of Windows Server has all the latest hot-fixes, and it’s the operating system most prepared for Exchange Server 2010.

You can also use Windows Server 2008 SP 2 or anything higher than that, but I would recommend you deploy on Win Server 2008 R2 SP 1. The Enterprise version is needed only if you’re going to do Database Availability Groups. We’ll get into that in a later video.

Notice I’ve named this machine CASHUB1.

This machine will run a combination of both the Client Access Service Roles and the HUB Transport Roles. From an OS perspective, I’m good to go because I’ve got 2008 R2 SP 1.

Next, I want to make sure that I’ve got the correct version of the .Net Framework.

I’ll launch PowerShell and import the Server Manager Module.

This is available on Server 2008 R2. This will give me a set of cmdlets.

Get-WindowsFeature will show me all of the roles and features out there. I can use a wild card. Get-WindowsFeature *net* will show me all the roles and features relating to .Net.

I’m interested in .Net Framework 3.5.1 Features.

As a pre‑requisite from an operating system perspective, I would need .Net Framework and then I would need other IIS components for the remainder of the roles.

Getting started, I would do Add-WindowsFearure net-framework

What’s convenient is that once I have the .Net Framework installed, based off the roles I picked to install, the Exchange Server 2010 installation will allow me to figure out the rest of the Windows roles or features needed for the pre‑requisites, and it will allow me to install them.

All I need to do is have my operating system at the correct level and have the .Net Framework 3.5.1. Then, I’m good to go. I can let Exchange Server figure out the rest for me. These cmdlets will tell you whether or not a restart is required after you do an installation. It will tell you if it was successful or if the installation failed.

The installation is completed successfully, and a restart is not required.

All of these roles and features that are required are documented on TechNet. Exchange 2010 SP 1 prerequisites.

This is all laid out for you, which makes it really easy. I know that I’m installing on Windows Server 2008 R2. I can drill down under that bullet point.

It shows me how to import the Server Manager module, and it has all the code I would need to do the prerequisites. For example, if I’m running CAS Hub Transport and Mailbox Server Roles, all the core roles, on one machine, I just want to have a single server set up.

I could just copy this code and paste it into PowerShell, which would handle the prerequisites for me.

Scrolling down is one that would have applied to what we just did.

With the new version of Exchange Server 2010 with Service Pack 1 this can all be figured out for you based on what you selected during the installation. It’s not required that I scroll through here. I only need the .Net Framework, but this is useful for scripting some of your installations.

The only other prerequisite you’ll need that’s not like an operating system prerequisite is the addition of the Microsoft Office 2010 Filter Packs. You can download them from Microsoft Technet Download Center – Microsoft Office 2010 Filter Packs

Notice that there are two architectures, a 32‑bit version and a 64‑bit version. We want to grab the 64‑bit version.

Adding the Microsoft Office 2010 Filter Packs allows Exchange to index the contents of Office documents.

Install this only on servers running either the Hub Transport Role or the Mailbox Server Role. Depending on how you have things built, you may or may not need this. For example, if you run CAS Server Role by itself, you won’t need this. This allows the Exchange Search Service to index the contents of Word Documents or Excel Spreadsheets, which helps in searches. Someone can do a search while in Outlook, and it will also search the contents of those files inside their mailbox.

The Microsoft Office 2010 Filter Packs is a simple download. Run through the installation commands to complete the install.

Once installation is complete, you’ll get this Microsoft Filter Pack 2.0 Setup Wizard.

Hit Next. Accept the license term agreement, and the installation is pretty much as simple as that.

Also, you can automate this from the command line and automate your server builds. Remember to check for any server packs available for Microsoft Office 2010 Filter Packs when you’re doing the installation. Once the prerequisites are met, we’ll be ready to install Exchange Server 2010.

Automate Exchange Server 2010 Installations and Unattended Installations

Use Scripting to Automate Microsoft Exchange Server 2010 Installations and Perform Unattended Installations

In Microsoft Exchange Server 2010, Unattended Installations or Command Line Installations aren’t built to allow you to script the install of Exchange. You can automate this by building a script of some kind that installs the roles that you define on your Exchange servers.

Right now we’ve got CAS and HUB Servers deployed for Exchange Servers 2010. We need a Mailbox Server Role defined.

I’ve gone out to MBX 1. Let’s look at the System Properties.

We can see we’re on MBX1. We’re running Windows Server 2008 R2 Enterprise SP1. I’ve got .Net Framework and the Filter Pack installed as my prerequisites. We’re ready to begin the Exchange Server installation.

I’ve extracted the Exchange Media to a folder in the C drive called E2010SP1.

At the folder, we’ll run E2020SP1>setup.com /help:install and get all the switches that we need to do an unattended install.

You’ll find that an unattended install is much faster than a graphical installation. The way we achieve this is by specifying the roles when we run setup.com.

We do a /r or /roles. The abbreviations are listed. You could do a /role and you simply pass in one or more of the roles listed below.

HubTransport is abbreviated as HT or just H.

ClientAccess is CA or C.

Mailbox is MB or M.

Next, we have the Mode.

The default is the Install Mode. So you don’t have to specify the mode unless you’re doing an uninstall.

Let’s scroll down a little bit further.

Target Directory [ /TargetDir ]: You can specify where Exchange Server 2010 will be installed. Anything available option in the graphical display when we’re doing the GUI install can be scripted through here.

Source [ /SourceDir ]: This is where we’re pulling files from.

Updates [ /UpdatesDir ]: You can slip-stream the updates into the installation.

Install Components Window [ /InstallWindowsComponents ]: This is a switch. That will go out and look for any other Windows Server Roles or features that are required by the role that you’re installing.

If you’ve already got the .Net framework and your operating system is Windows Server 2008 R2 SP1, you can simply do a command line install by specifying the role and installing the Windows components.

Next, I’ll run setup.com. I’ll tell setup.com to install the Mailbox Role, and I’ll also install Windows components,

E2010sp1>setup.com /r:m /installwindowscomponents

This will take care of any Windows components that are not already installed. Hit enter. We should get back successful. We’ve done everything right up to this point. But if any errors are encountered along the way, they’ll be reported here.

The installation is now complete.

As you can see, the initial checks were done and those completed successfully. Then we moved onto installing the roles and doing all the checks, which also completed successfully.

This is the same output you would get in the graphical installation or in setup.exe.

Finally, you get a message down at the bottom to reboot this server before putting it into production. You’ll want to patch the server and get it ready for production.

At this point, we’ve got the Client Access Service Role, the Hub Transport Role and the Mailbox Role installed. Now we can move on to the next step, confirming that Mail Flow works in Exchange Server 2010.

See The Differences between Public OWA and Internal OWA?

please see at the bottom at the Public OWA. I used Forefront Threat Management Gateway 2010 to publish OWA. You need to have a cetificates installed at the personal certificate (using MMC) and enter the private key. the certificates can be obtained from your OWA exchange server at Client Access under Server Configuration.




The public webpage looks like below.

Recovering Lost Mail/Mailbox Item

Lost Mail Item / Mailbox

This scenario is not a service failure but more of a user request (e.g. user requires recovering a mail item which he deleted and is no longer in the mail deleted item retention period; or a previously deleted mailbox needs to be restored for audit purposes). In both cases, a mailbox needs to be recovered from backup from a certain point of time. Once that mailbox is recovered, then any data in that mailbox can then be extracted and provided to the user (e.g. as a PST file).

To recover a single mailbox, a Recovery Database must be created on the server that mailbox is to be recovered to.

A recovery database (RDB) is a special kind of mailbox database that allows you to mount a restored mailbox database and extract data from the restored database as part of a recovery operation. After you’ve created an RDB, you can restore a mailbox database into the RDB by using your backup application (or if you have the database and its log files in the file system, by copying those to the RDB file structure). Then you can use the Restore-Mailbox cmdlet to extract data from the recovered database. After being extracted, the data can then be exported to a folder or merged into an existing mailbox. RDBs allow you to recover data from a backup or copy of a database without disrupting user access to current data.

The Exchange mailbox servers have been provisioned with a Recovery LUN to be used in such situations. The database in question needs to be restored to this free disk. There is no impact to live users during this operation.

Resolution Details

The procedure for recovering a mailbox is as follows:

  1. Use your backup application to restore the Mailbox database to the restore LUN on the Exchange 2010 mailbox server (drive R: on MBX SERVER NAME 1):
    1. In the backup program ensure that you are recovering to an alternate location (R:\Recovery)
    2. Create a Recovery Database on the Exchange 2010 Mailbox server.
      1. Use the New-MailboxDatabase cmdlet to create the RDB on the

New-MailboxDatabase -Recovery -Name DB01 -Server MBX SERVER NAME 1

-EdbFilePath “R:\Recovery\<db_name>.edb” -LogFolderPath “R:\Recovery”

  1. Run ESEUTIL to bring the database to a consistent state:

ESEUTIL /R E00 /l “F:\Recovery” /d “R:\Recovery”


  1. Mount the database using Mount-Database cmdlet.
  2. Use the Restore-Mailbox cmdlet to restore the required data

Once data has been restored, you can dismount the RDB and delete it and its files.

Sending ‘As’

Send As

Being able to send messages directly as the manager means that the recipient of the message will think that the manager has sent the message, even though it was actually the assistant that sent it. The key to achieving this process is the Send As permission. This is an Active Directory permission that is granted by the system administrator; it cannot be granted from within Outlook. To grant the Send As permission, the administrator needs to perform the following steps:

  1. Run the Active Directory Users and Computers snap-in.
  2. Click the View menu and then make sure that the Advanced Features option is selected. This will make sure you see the Security tab referenced later in step 4.
  3. Locate the relevant user account, in this case the manager’s user account, and bring up its properties.
  4. Go to the Security tab and click the Add button.
  5. Add in the assistant’s account that you’d like to send as the manager and make sure that you grant the assistant’s account the Send As right. This is shown in Figure 1.

Figure 1: Granting Send As Rights

Making these changes will allow the assistant to use the From field in Outlook and choose the manager’s mailbox as the sending mailbox. This is shown below in Figure 2. If you don’t see the From field when composing a new message in Outlook, click the View / From Field option in the new message window. This applies to Outlook 2003. For Outlook 2007 (beta 2 for this article), you’ll find the Show From button on the Options tab of the ribbon.

Figure 2: Using Outlook’s From Field

However, it’s important to note that it can take a while, possibly up to two hours, for the permissions changes to take effect which has proved to be the source of much frustration amongst Exchange administrators. Once the permissions changes have been made and the Outlook From field completed, it’s quite common for the assistant to receive a non-delivery report just after sending the message. These non delivery reports will look like the sample one shown below in Figure 3:

Figure 3: Permissions Failure Non-Delivery Report

Of course, the key wording above is the line that reads You do not have permission to send to this recipient. Is it possible to speed up this permissions change process? Well, I haven’t been able to get someone from Microsoft to confirm this, but I believe it’s possible via the Mailbox Cache Age Limit registry key documented in KB article 327378. The KB article mentions changing the Mailbox Cache Age Limit registry key, which according to the article is used to re-read logon quota information. In my experience, modifying this key (or creating it if it doesn’t exist) with a suitable value, in minutes, speeds up the permissions change process. Note that you must restart the Information Store service after modifying this registry key. The general consensus of opinion here is not to make this value too low; a sensible value is 15 minutes. The alternative to creating or modifying this registry key is to simply re-start the Information Store service, which appears to make the permissions changes take effect immediately. Of course, restarting the Information Store service is rarely practical during business hours and you may also not prefer to go poking around in the registry, so you can also choose to wait for the permissions to be re-read at the next interval, which, as stated earlier, could be up to 2 hours.

Once the permissions have been granted and successfully taken effect, the assistant can send the message as normal. What does the recipient of the message actually see? Quite simply, the recipient will not be able to tell that it was the assistant who actually sent this message as it will appear just as if the manager had sent it. We’ll talk about another method, the Send on Behalf of method, a little later in this article.

Sending as a Group or Public Folder

Administrators often ask how they can send as a distribution group, or even a public folder. One of the most common applications of this scenario is where an organization creates a helpdesk-style distribution group, meaning that multiple users receive messages addressed to the distribution group. It’s then typically a requirement that these users send messages so that they appear to come from the distribution group rather than from the individual members of the group. The good news is that the Send As permission works for these objects too. To send as a distribution group, the steps are identical to those that I detailed earlier, the only difference being that you’d obviously need to locate the distribution group and bring up its properties, rather than a user account. An example of this is shown below in Figure 4, where my own user account has been granted the Send As rights for the IT Consultants distribution group.

Figure 4: Send As a Distribution Group

Of course, it’s also possible to send as a public folder. In this case, the steps are a little different but the concept is the same. The steps are:

  1. Run the Exchange System Manager snap-in.
  2. Under the relevant administrative group, navigate to Folders / Public Folders and then find the relevant public folder that you’d like to send messages as.
  3. Bring up the properties of the folder and go to the Permissions tab.
  4. Click the Directory Rights button and then add your chosen user account as before, making sure that the Send As right has been granted.
  5. If the Directory Rights button is not available, make sure that the public folder is mail-enabled. This can be done by first right-clicking the public folder in Exchange System Manager, then choosing All Tasks / Mail Enable.
  6. Back in the properties of the public folder, switch to the Exchange Advanced tab and make sure that the Hide from Exchange address lists option is not selected, otherwise you won’t be able to locate the folder when clicking the From button in Outlook.

Send On Behalf Of

Now let’s go back to our manager/assistant example and consider the scenario where the manager requires the assistant to send email messages on their behalf, making sure that the recipient knows that the assistant has indeed sent the message on behalf of the manager. To achieve this, Outlook’s delegate access feature can be used.

The important difference between delegate access and the Send As permission that I covered earlier in this article is that the delegate access feature can be set by the user or by the administrator. Therefore, in our example, the manager can set delegate access by choosing Tools / Options from within Outlook and then choosing the Delegates tab. Figure 5 shows how this looks.

Figure 5: Delegate Access Tab

Clicking the Add button will then allow the manager to choose their assistant that will act as the delegate from the Global Address List (GAL). Once the assistant has been chosen, the Delegate Permissions window is displayed, an example of which is shown in Figure 6. Here you can see that the assistant has been given Editor permissions by default to the Calendar and Tasks folders, but not the Inbox folder. Therefore, the next thing to do is to ensure the assistant also has Editor permissions against the manager’s Inbox folder. Once done, this will allow the assistant to send messages on behalf of the manager.

Figure 6: Default Delegate Permissions Window

Another way to set delegate access can be performed by the Exchange administrator. This can be performed via the following series of steps:

  1. Run the Active Directory Users and Computers snap-in.
  2. Locate the relevant user, in this case the manager’s user account, and bring up its properties.
  3. Go to the Exchange General tab and click the Delivery Options button.
  4. In the Send on behalf area, click the Add button and add in the assistant’s account that you’d like to send on behalf of the manager. This is shown below in Figure 7.

Figure 7: Administrator Granting Send On Behalf Of

Once delegate access has been set, the assistant can now use the From field in Outlook as previously shown in Figure 2 above. The difference is how the message recipient sees the sender of the message. You’ll remember from earlier in the article that if the administrator grants direct Send As rights, the message will be shown as if it was sent directly by the manager. With the Send on Behalf of permission, the recipient will see that the message has been sent by the assistant on behalf of the manager. This is shown in Figure 8.

Figure 8: ‘Send on Behalf of’ Sample Message

Another useful thing that I want to mention is that it’s worth noting here what happens when the recipient replies to this message. In Figure 8 above, if I reply to the message the reply will be addressed to the manager and not the assistant. If the assistant wishes replies to go back to them, the assistant needs to make use of the Have replies sent to: option when composing the original message. This is shown in Figure 9.

Figure 9: Setting The Reply Destination

Finally, note that it’s also possible to send on behalf of a public folder. This option can be found by bringing up the properties of the public folder in Exchange System Manager, clicking the Exchange General tab, and then clicking the Delivery Options button.

%d bloggers like this: