Showing posts with label Windows. Show all posts
Showing posts with label Windows. Show all posts

Thursday, 22 September 2011

How do I... Install and configure a DNS server in Windows Server 2008?


Installation

You can install a DNS server from the Control Panel or when promoting a member server to a domain controller (DC) (Figure A). During the promotion, if a DNS server is not found, you will have the option of installing it.

Figure A

Domain controller
To install a DNS server from the Control Panel, follow these steps:
  • From the Start menu, select | Control Panel | Administrative Tools | Server Manager.
  • Expand and click Roles (Figure B).
  • Choose Add Roles and follow the wizard by selecting the DNS role (Figure C).
  • Click Install to install DNS in Windows Server 2008 (Figure D).

Figure B

Expand and click Roles

Figure C

DNS role

Figure D

Install DNS

DNS console and configuration

After installing DNS, you can find the DNS console from Start | All Programs | Administrative Tools | DNS. Windows 2008 provides a wizard to help configure DNS.
When configuring your DNS server, you must be familiar with the following concepts:
  • Forward lookup zone
  • Reverse lookup zone
  • Zone types
A forward lookup zone is simply a way to resolve host names to IP addresses. A reverse lookup zone allows a DNS server to discover the DNS name of the host. Basically, it is the exact opposite of a forward lookup zone. A reverse lookup zone is not required, but it is easy to configure and will allow for your Windows Server 2008 Server to have full DNS functionality.
When selecting a DNS zone type, you have the following options: Active Directory (AD) Integrated, Standard Primary, and Standard Secondary. AD Integrated stores the database information in AD and allows for secure updates to the database file. This option will appear only if AD is configured. If it is configured and you select this option, AD will store and replicate your zone files.
A Standard Primary zone stores the database in a text file. This text file can be shared with other DNS servers that store their information in a text file. Finally, a Standard Secondary zone simply creates a copy of the existing database from another DNS server. This is primarily used for load balancing.
To open the DNS server configuration tool:
  1. Select DNS from the Administrative Tools folder to open the DNS console.
  2. Highlight your computer name and choose Action | Configure a DNS Server… to launch the Configure DNS Server Wizard.
  3. Click Next and choose to configure the following: forward lookup zone, forward and reverse lookup zone, root hints only (Figure E).
  4. Click Next and then click Yes to create a forward lookup zone (Figure F).
  5. Select the appropriate radio button to install the desired Zone Type (Figure G).
  6. Click Next and type the name of the zone you are creating.
  7. Click Next and then click Yes to create a reverse lookup zone.
  8. Repeat Step 5.
  9. Choose whether you want an IPv4 or IPv6 Reverse Lookup Zone (Figure H).
  10. Click Next and enter the information to identify the reverse lookup zone (Figure I).
  11. You can choose to create a new file or use an existing DNS file (Figure J).
  12. On the Dynamic Update window, specify how DNS accepts secure, nonsecure, or no dynamic updates.
  13. If you need to apply a DNS forwarder, you can apply it on the Forwarders window. (Figure K).
  14. Click Finish (Figure L).

Figure E

Configure

Figure F

Forward lookup zone

Figure G

Desired zone

Figure H

IPv4 or IPv6

Figure I

Reverse lookup zone

Figure J

Choose new or existing DNS file

Figure K

Forwarders window

Figure L

Finish

Managing DNS records

You have now installed and configured your first DNS server, and you’re ready to add records to the zone(s) you created. There are various types of DNS records available. Many of them you will never use. We’ll be looking at these commonly used DNS records:
  • Start of Authority (SOA)
  • Name Servers
  • Host (A)
  • Pointer (PTR)
  • Canonical Name (CNAME) or Alias
  • Mail Exchange (MX)

Start of Authority (SOA) record

The Start of Authority (SOA) resource record is always first in any standard zone. The Start of Authority (SOA) tab allows you to make any adjustments necessary. You can change the primary server that holds the SOA record, and you can change the person responsible for managing the SOA. Finally, one of the most important features of Windows 2000 is that you can change your DNS server configuration without deleting your zones and having to re-create the wheel (Figure M).

Figure M

Change configuration

Name Servers

Name Servers specify all name servers for a particular domain. You set up all primary and secondary name servers through this record.
To create a Name Server, follow these steps:
  1. Select DNS from the Administrative Tools folder to open the DNS console.
  2. Expand the Forward Lookup Zone.
  3. Right-click on the appropriate domain and choose Properties (Figure N).
  4. Select the Name Servers tab and click Add.
  5. Enter the appropriate FQDN Server name and IP address of the DNS server you want to add.

Figure N

Name Server

Host (A) records

A Host (A) record maps a host name to an IP address. These records help you easily identify another server in a forward lookup zone. Host records improve query performance in multiple-zone environments, and you can also create a Pointer (PTR) record at the same time. A PTR record resolves an IP address to a host name.
To create a Host record:
  1. Select DNS from the Administrative Tools folder to open the DNS console.
  2. Expand the Forward Lookup Zone and click on the folder representing your domain.
  3. From the Action menu, select New Host.
  4. Enter the Name and IP Address of the host you are creating (Figure O).
  5. Select the Create Associated Pointer (PTR) Record check box if you want to create the PTR record at the same time. Otherwise, you can create it later.
  6. Click the Add Host button.

Figure O

A Host (A) record

Pointer (PTR) records

A Pointer (PTR) record creates the appropriate entry in the reverse lookup zone for reverse queries. As you saw in Figure H, you have the option of creating a PTR record when creating a Host record. If you did not choose to create your PTR record at that time, you can do it at any point.
To create a PTR record:
  1. Select DNS from the Administrative Tools folder to open the DNS console.
  2. Choose the reverse lookup zone where you want your PTR record created.
  3. From the Action menu, select New Pointer (Figure P).
  4. Enter the Host IP Number and Host Name.
  5. Click OK.

Figure P

New Pointer

Canonical Name (CNAME) or Alias records

A Canonical Name (CNAME) or Alias record allows a DNS server to have multiple names for a single host. For example, an Alias record can have several records that point to a single server in your environment. This is a common approach if you have both your Web server and your mail server running on the same machine.
To create a DNS Alias:
  1. Select DNS from the Administrative Tools folder to open the DNS console.
  2. Expand the Forward Lookup Zone and highlight the folder representing your domain.
  3. From the Action menu, select New Alias.
  4. Enter your Alias Name (Figure Q).
  5. Enter the fully qualified domain name (FQDN).
  6. Click OK.

Figure Q

Alias Name

Mail Exchange (MX) records

Mail Exchange records help you identify mail servers within a zone in your DNS database. With this feature, you can prioritize which mail servers will receive the highest priority. Creating MX records will help you keep track of the location of all of your mail servers.
To create a Mail Exchange (MX) record:
  1. Select DNS from the Administrative Tools folder to open the DNS console.
  2. Expand the Forward Lookup Zone and highlight the folder representing your domain.
  3. From the Action menu, select New Mail Exchanger.
  4. Enter the Host Or Domain (Figure R).
  5. Enter the Mail Server and Mail Server Priority.
  6. Click OK.

Figure R

Host or Domain

Other new records

You can create many other types of records. For a complete description, choose Action | Other New Records from the DNS console (Figure S). Select the record of your choice and view the description.

Figure S

Create records from the DNS console

Troubleshooting DNS servers

When troubleshooting DNS servers, the nslookup utility will become your best friend. This utility is easy to use and very versatile. It’s a command-line utility that is included within Windows 2008. With nslookup, you can perform query testing of your DNS servers. This information is useful in troubleshooting name resolution problems and debugging other server-related problems. You can access nslookup (Figure T) right from the DNS console.

Figure T

Tuesday, 20 September 2011

Transferring FSMO Roles in Windows Server 2008

Transferring FSMO Roles in Windows Server 2008

Published

:

August 24, 2009
Last Updated :August 24, 2009
   
Introduction

This is a must to read article for any system administrator who administers Microsoft Windows Servers. One of any system administrator duties, would be to upgrade a current domain controller to a new hardware server. One of the crucial steps required to successfully migrate your domain controller, is to be able to successfully transfer the FSMO roles to the new hardware server. FSMO stands for Flexible Single Master Operations, and in a forest there are at least five roles. In this article, I will be showing you how to transfer the FSMO in Windows Server 2008,
 
The five FSMO roles are:
  1. Schema Master
  2. Domain Naming Master
  3. Infrastructure Master
  4. Relative ID (RID) Master
  5. PDC Emulator
The FSMO roles are going to be transferred, using the following three MMC snap-ins :
  • Active Directory Schema snap-in  : Will be used to transfer the Schema Master role
  • Active Directory Domains and Trusts snap-in : Will be used to transfer the Domain Naming Master role
  • Active Directory Users and Computers snap-in : Will be used to transfer the RID Master, PDC Emulator, and Infrastructure Master roles

Note: The following steps are done on the Windows Server 2008 machine that I intend to set as the roles holder ( transfer the roles to it )
Lets start transferring the FSMO roles.
  • Using Active Directory Schema snap-in to transfer the Schema Master role
    You have to register schmmgmt.dll in order to be able to use the Active Directory Schema snap-in
  1. Click Start > Run
  2. Type regsvr32 schmmgmt.dll


  3. Click OK


    A popup message will confirm that schmmgmt.dll was successfully registered. Click
    OK
  4. Click Start > Run, type mmc, then click OK


  5. Click File > then click Add/Remove Snap-in...


  6. From the left side, under Available Snap-ins, click on Active Directory Schema, then click Add > and then click OK

  7. Right click Active Directory Schema, then click Change Active Directory Domain Controller...


  8. From the listed Domain Controllers, click on the domain controller that you want to be the schema master role holder and then click on OK



    You will receive a message box stating that the schema snap-in is not connected to a schema operations master. That is for sure, as we have not yet set this Windows Server 2008 domain controller as a Schema Master role holder. This will be done in the next step. Click OK


  9. In the console tree, right click Active Directory Schema [DomainController.DomainName], and then click Operations Master...


  10. On the Change Schema Master page, the current schema master role holder will be displayed ( ex. ELMAJ-DC.ELMAJDAL.NET) and the targeted schema holder as well (ex. ELMAJ-DC2K8.ELMAJDAL.NET). Once you click Change, the schema master holder will become
    ELMAJ-DC2K8.ELMAJDAL.NET
    , click Change




    Click Yes to confirm the role transfer



    The role will be transferred and a confirmation message will be displayed. Click
    OK


    Then click Close, as you can see in the below snapshot, the current schema master is ELMAJ-DC2K8.ELMAJDAL.NET




  • Using Active Directory Domains and Trusts snap-in to transfer the Domain Naming Master Role
  1. Click Start > Administrative Tools > then click Active Directory Domains and Trusts

  2. Right click Active Directory Domains and Trusts, then click Change Active Directory Domain Controller...

  3. From the listed Domain Controllers, click on the domain controller that you want to be the Domain Naming master role holder and then click on OK


  4. Right click Active Directory Domains and Trusts, then click Operations Master...


  5. On the Operations Master page, we are going to change the Domain Naming role holder from ELMAJ-DC.ELMAJDAL.NET to ELMAJ-DC2K8.ELMAJDAL.NET, Click Change



    Click YES to confirm the transfer of the Domain Naming role


    The role will be transferred and a confirmation message will be displayed. Click OK , then click Close



Till now, we have successfully transferred two FSMO roles, the Schema Master role and the Domain Naming role. The last three roles can be transferred using a single Snap-in.

  • Using Active Directory Users and Computers snap-in to transfer the RID Master, PDC Emulator, and Infrastructure Master Roles
  1. Click Start > Administrative Tools > then click Active Directory Users and Computers


  2. Right click Active Directory Users and Computers, then click All Tasks > Operations Master...


  3. You will have three Tabs, representing three FSMO roles (RID, PDC, Infrastructure). Click the Change button under each of these three tabs to transfer the roles.


    Click Yes to confirm the role transfer



    The role will be transferred and a confirmation message will be displayed. Click
    OK

    As for the Infrastructure role, once you click on the Change button you will receive the below message



    By default, when you first install your first Domain Controller, it holds the five roles and beside that it is a Global Catalog. If your environment is a multi-domain/forest, then you should think about structuring your FSMO roles and transfer the Infrastructure role to a none Global Catalog domain controller. Else if you have small number of domain controllers ( ex. two domain controllers) then you should not worry about this. Click Yes

  4. The Tabs should now look like this:


That's it, by now, you have successfully transferred the five FSMO roles to the Windows Server 2008 Domain Controller.

Summary
There are five FSMO roles in a forest, to transfer any of these roles you have to use the appropriate Active Directory snap-in. In my next article, I will be showing you the complete steps required to successfully migrate/upgrade your domain controller to a new hardware server.
 and in my next article, I will show you the complete steps required to successfully migrate/upgrade your domain controller to a new hardware server.