Active Directory Seminar Overview
Active Directory Seminar Overview
            John Craddock
            Principal Consultant
  v-jcradd@microsoft.com   jcrad@kimberry.co.uk
               Sally Storey
                 Consultant
            sallysto@kimberry.co.uk
                                                  Kimberry
                                                  _______
                                                    Associates
                                              2
Seminar Topics
•   Introduction
•   Anatomy of an Object
•   Data Storage
•   Securing Directory Objects
•   Advanced Delegation of Administration
•   Creating the Active Directory
•   Replication
                                    Kimberry
                                    _______
                                      Associates
                                                             3
Lots of Demos!
netads01
                                      example.com
London site
netads02
          netads03
                                 child.example.com
NewYork site
netads04
                                               Kimberry
                                               _______
                                                     Associates
                                                                                   4
   Demonstration Environment
                                 Windows XP
                                    Host
            netads01     netads02      netads03      netads04
  Virtual
 network
10.20.0.0
             4 virtual machines running Windows .NET Enterprise Server
                                                                         Kimberry
                                                                         _______
                                                                           Associates
                                                      5
                                            Kimberry
                                            _______
                                              Associates
                                                      6
Health Warning!!
                                         Kimberry
                                         _______
                                              Associates
                                                    7
Seminar Slides
                                          Kimberry
                                          _______
                                            Associates
                                                                    8
Seminar Topics
• Introduction
• Anatomy of an Object
• Data Storage
• Object Security/Securing Directory Objects
• Advanced Administration/Advanced
  Delegation
• Creating the Active Directory
• Replication
                                               Kimberry
                                               _______
                                                 Associates
                                                       10
                                              Kimberry
                                              _______
                                                Associates
                                                       11
 Grouping Objects
• Management tasks include:
  – Controlling object visibility
  – Controlling access to objects
  – Maintaining attribute values
  – Identifying users and computers that will share
    a common group policy
• Designed correctly, the AD will provide an
  ideal abstraction of resources for both users
  and management
                                              Kimberry
                                              _______
                                                Associates
                                                   12
An Ideal Model
                            Simple user access to
 Delegated Administration    data and resources
      Group Policy
     Resource Access
Seminar Topics
• Introduction
• Anatomy of an Object
• Data Storage
• Securing Directory Objects      •   Importing and Exporting
                                      Directory Objects
• Advanced Delegation of          •   Extending the User
  Administration                      Interface
                                  •   Replicating the Directory
• Creating the Active Directory   •   Adding Naming
• Replication                         Contexts
                                  •   The Global Catalog
                                  •   The Schema
                                                      Kimberry
                                                      _______
                                                         Associates
                                                           14
 Representing Entities
          Attributes
cn=john,ou=legal,ou=ed,ou=uk LN ED
    dc=mining,dc=xyzgroup,dc=com
                                                                         sales     legal
                                                                                    legal
       Naming Contexts
                                   mining.xyzgroup.com             xyzgroup.com
   Domain NC:
   dc=mining,dc=xyzgroup,dc=com
       Programmatic Access
  • LDAP provides programmatic access to the
    directory
         – Search, compare, add, modify, delete, rename
           (ModifyDN), and more…
  • Windows 2000 implements LDAPv3
         – It will answer v2 queries
  • ADSI provides COM access to the directory
         – Uses LDAP as the on-the-wire protocol
                                                   Kimberry
                                                   _______
LDAP = Lightweight Directory Access Protocol         Associates
                                                                          20
       RootDSE
  • All DCs maintain a node called RootDSE
  • RootDSE provides information on:
         – Supported naming contexts
         – The Root NC
         – LDAP versions
         – Supported controls
               • Extends the capabilities of LDAP
         – Policies and security
                                                                 Kimberry
                                                                 _______
RootDSE = Root DSA-Specific Entry, DSA=Directory Service Agent     Associates
                                                             21
                                                    Kimberry
                                                    _______
                                                      Associates
                                                              22
                                             AND
Logical                  Locality-Name
 AND                   identifies the City
Logical
  OR
                                                     Kimberry
                                                     _______
                                                       Associates
                                                                    23
ANR Searches
(&(ANR=john)(co=united kingdom))
dsHeuristics
                                               Kimberry
                                               _______
                                                 Associates
                                                                                   26
   Attribute Search-Flags
    Copy attribute
when object is copied                16        8   4         2        1
 (user account copy)
• enabled = 1, disabled = 0
    – Values can be changed programmatically
        • Limited access via Schema Manager
                                                                          Kimberry
                                                                          _______
                                                                            Associates
                                                          27
                                                 Kimberry
                                                 _______
                                                   Associates
                                                                       28
  (searchFlags:1.2.840.113556.1.4.803:=5)
  Rule OID provides an AND test, evaluates true if bits 0 AND 2
  are set
  (searchFlags:1.2.840.113556.1.4.804:=5)
  Rule OID provides an OR test, evaluates true if bits 0 OR 2
  are set
                                                            Kimberry
                                                            _______
                                                                Associates
                                                                 29
 LDAP v3 Controls
• Controls extend the functionality of LDAP
  – Server controls are sent to the server
  – Client controls affect the functionality of the
    LDAP API
• The controls are identified by OIDs
   Example Control Types:
   Show Deleted Objects:  1.2.840.113556.1.4.417
   Do Not Generate Referrals: 1.2.840.113556.1.4.1339
   See the SDK header file ntldap.h for all the defined controls
                                                         Kimberry
                                                         _______
                                                          Associates
                                   30
                          Kimberry
                          _______
                            Associates
                                                            31
 Operational Attributes
• Operational attributes provide a mechanism
  for triggering actions on the server via LDAP
  – They are not defined in the schema
  – Writing to the attributes causes the server to
    perform a predefined action
• Actions include (ntldap.h for details):
  – Updating the Schema
  – Transferring FSMO roles
  – Triggering the SD Propagator Thread
                                                Kimberry
                                                _______
                                                     Associates
                                                32
Operational Attributes
LDIF
                                       Kimberry
                                       _______
                                         Associates
                                                               35
LDIF examples
                                                      Kimberry
                                                      _______
                                                        Associates
                                                        36
CSV
                                               Kimberry
                                               _______
                                                 Associates
Extending the User Interface
                                                                       38
 Display Specifiers
                                            Specifier for current
                                              locale selected
                                                      Object
                                                      classes
Administration
   tools               Display
                      specifiers           Stored in locale-specific
                                               container in the
                                              configuration NC
                 Display specifiers are
                 defined for each locale
Extending the UI
                          GC
                               Partial replica of all domain
                               objects
                               Hosted on one or more DCs
Application Directory
Partitions
• Provides the ability to create new
  naming contexts within the directory
  – The DCs that host replicas of the NC can
    be defined
  – Cross-domain replication is supported
• With the exception of security principals
  any type of object/attribute can be
  supported
                                           Kimberry
                                           _______
                                               Associates
                                                                        44
  Application Directory
  Partitions
          Create                                 example.com
                       Application
                        Directory
                        Partition
          Replicated
Add Replica
     Application
      Directory
      Partition                      child.example.com
                                                               Kimberry
                                                               _______
                                                                 Associates
                                 45
Application Directory
Partitions and DNS
                        Kimberry
                        _______
                          Associates
                                                                      46
 Creating
 Application Directory Partitions
 • Application Directory Partitions can be
   created programmatically or using the
   ntdsutil command line utility
 • Create the new NC on one DC and then
   add a replica to other DCs
create nc dc=emea,dc=example,dc=com netads01.example.com
                                                            Kimberry
                                                            _______
                                                              Associates
The Global Catalog
                                                     48
    Deployment Issues
•   Adding attributes to the GC partial attribute
    set causes all GCs to fully synchronize
    –   Equivalent to repromoting all GCs
    –   No interruption in service
    –   Bandwidth, CPU intensive
•   Applications may add attributes to the GC
    partial attribute set
    – Exchange 2000
                                            Kimberry
                                            _______
                                              Associates
                                                           49
                                                Kimberry
                                                _______
                                                    Associates
                                                                                       50
    Deployment Issues
•   Logon fails if the GC is not available
    – Administrators can still logon
                                             Kimberry
                                             _______
                                                 Associates
                                                  52
Deployment Issues
                                         Kimberry
                                         _______
                                           Associates
                                                          53
Universal Group
Membership Caching
     DC      On first logon the users
             group details are cached
                                             GC
            Periodically updated
              default 8 hours
NewYork London
    Membership Changes
•   Changes to universal and global group
    membership will not be seen until after the
    cache has been refreshed
    – The user must also log off and on to rebuild
      the security token
•   No UI to refresh the cache
    – Refreshed via an operational attribute
      •   Programmatically via ADSI and WMI
      •   Manually using LDP
                                               Kimberry
                                               _______
                                                 Associates
The Schema
                                                            56
The Schema
                                      Attribute
                                       Attributedefinitions:
                                                 definitions:
                                      Unique  identifier
                                       Unique identifier
Object
 Objectdefinitions:
        definitions:                  Syntax
                                       Syntax
Must
 Mustcontain
      containattributes
               attributes             Range
                                       Range
May contain  attributes
 May contain attributes               Indexed
                                       Indexed
Possible
 Possibleparents
          parents                     Replicated
                                       ReplicatedtotoGC
                                                      GC
More…
 More…                                Linked
                                       Linked
                                      Property
                                       Propertyset
                                                 set
                                      More…
                                       More…
 Class Definitions
• Class definitions include:
  – Class identifiers
     • cn, ldapDisplayName, SchemaIDGUID, OID
  – mustContain, systemMustContain, mayContain,
    and systemMayContain attributes
     • Used when an object of this class is instantiated
  – Possible parents
  – SuperClasses and auxiliary classes
     • Every object class (except for top) is derived from
       another class
                                                      Kimberry
                                                      _______
                                                           Associates
                                                                                               59
      Class Inheritance
             abstract
                                              • An object class can be
      top
                                                derived from other
                                                classes
                  subClassOf
abstract                                          – Which may have also been
            Person
                                                    derived from other classes
                                              z    Classes may be:
     abstract            subClassOf
                                                   ¾    Structural
           organizationalPerson                    ¾    Abstract
                                                   ¾    Auxiliary
                                 subClassOf
            Structural                                  securityPrincipal      mailRecipient
                                 SystemAuxiliaryClass                                   auxiliary
                                                                   auxiliary
                          user
Aggregated Attributes
                                                Aggregated:
                                                mustContain
       Aggregated: possible parents
                                             systemMustContain
                                                 mayContain
                                             systemMayContain
                                                    Kimberry
                                                    _______
                                                        Associates
                                                     62
 Attribute Properties
• The properties of an attribute define settings
  which include:
  – Attribute identifiers
     • OID, ldapDisplayName, SchemaIDGUID
  – The syntax of the data stored in an instance of
    the attribute
  – Singlevalued or multivalued data storage
  – The allowable data range
  – Attribute management
     • Linked, indexed, member of ANR set, replicated to
       the GC and more…
                                                    Kimberry
                                                    _______
                                                      Associates
                                                         64
showInAdvancedViewOnly
isDefunct
searchFlags
isMemberOfPartialAttributeSet
                                Kimberry
                                _______
                                  Associates
                                                                                 66
 Linked Attributes
          Forward-link                            Back-link
                         Linked attributes
           Manager                               Direct Reports
           Paul
                                     The Direct reports (reports) attribute is
 Sally
                                     multivalued and contains the DNs of the
           Amy                       objects that contain forward links that
 Debbie                              reference this object
                                     Linked attributes are identified by their
           Simon                     linkID properties being set to n and n+1
 Peter
                                     The forward-link is identified by an even
                                     value of n, n+1 identifies the back-link
Database
    Phantom Records
    View presented by DSA
                                 A   DN of referenced object Z
Database
    Maintaining Phantoms
• The Infrastructure Master runs on one DC in
  the domain and maintains phantoms that are
  held in the DC’s database
    – It checks phantom record data against the
      corresponding GC entries
        • If changes to the referenced objects are detected
          these are replicated to all other DCs in the domain
                                          Create new
                                          object class
                                                              Existing
                                                              attributes
               Existing
              object class
    OIDs
•   Object classes, attributes and syntaxes are
    defined using OIDs
•   The preferred method of obtaining an OID
    is to obtain your own root ID
    –   web.ansi.org/public/services/reg_org.html
    –   www.iso.ch/addresse/membodies.html
                                                    Kimberry
                                                    _______
                                                      Associates
                                                                72
                                               Kimberry
                                               _______
                                                 Associates
                                                        74
 Schema Protection
• Only members of the Schema Admins group
  can make changes to the schema
  – Make sure that the Schema administrators are
    aware of their responsibilities
• A safety interlock is provided in the Registry
  before changes can be made
  HKLM\SYSTEM\CurrentControlSet…
     \Services\NTDS\Parameters\SchemaUpdateAllowed
  – Can be enabled via the Schema Manager
                                               Kimberry
                                               _______
                                                 Associates
                                                                               75
                                                Kimberry
                                                _______
                                                  Associates
                                                         77
Seminar Topics
•   Introduction
•   Anatomy of an Object
•   Data Storage
•   Securing Directory Objects
•   Advanced Delegation of Administration
•   Creating the Active Directory
•   Replication
                                       Kimberry
                                       _______
                                            Associates
                                                                    79
AD Architecture
     LDAP/ADSI    Replication     NT SAM         Outlook
                  transports       calls         clients
DB Layer
                                                           Kimberry
                                                           _______
                                                             Associates
                                                                        80
       ESE
  • Originally code named JET Blue
         – Completely different to the Access database
           (JET Red)
         – ESE97 – Exchange 5.5
         – ESENT – Windows 2000 (esent.dll)
               • Uses the same format and engine ulVersion (620,2)
                 as ESE97
         – ESE98 – Exchange 2000
               • Additional enhancements, including streaming file
                 support
                                                              Kimberry
                                                              _______
JET = Joint Engine Technology                                    Associates
                                                  81
 What’s Required?
• A fast and highly optimised way of storing
  and retrieving loosely-structured and semi-
  structured data
• Integrity and crash survival (ACID)
  – Transactions are:
     •   Atomic
     •   Consistent
     •   Isolated
     •   Durable
                                         Kimberry
                                         _______
                                           Associates
                                                                           82
      Transaction Logging
                                                   Update
                                                  Checkpoint
           c                                                    edb.chk
 Database                    Calculate database     Commit
write request    ESE              changes         transaction   h
                                       d
                                                   Write to
                             Transaction buffer
                  f
                                                   database     g
                                             e
          Confirm database        Write to                      ntds.dit
                write             log file          edb.log
 Log Files
• There is always a delay between the
  transaction log being written and the
  transaction being committed
  – This delta is referred to as the checkpoint depth
• The current log file is always edb.log
  – The older logs are identified as edb0000x.log
     • x is an incrementing hex number
  – The log file size is 10 MB
                                               Kimberry
                                               _______
                                                 Associates
                                                       84
 Circular Logging
• The Active Directory uses circular logging
  (no supported way of disabling)
  – When all the transactions in the log file have
    been committed, the file is deleted
• Non-circular logging is mainly used for
  incremental backup
  – The System State, which includes the directory,
    must be backed up as a single entity
  – Circular logging is used because other
    components of the System State do not support
                                             Kimberry
                                             _______
    incremental backup                         Associates
                                                        85
 Recovery
• If the system crashes before all of the
  transactions are committed, the lost
  transactions are recovered from the log file
• ESE determines which transactions have
  been committed by reading the dbTime
  value in the log file
  – edb.chk is only used to identify which log files
    should be checked
     • This speeds up the operation
                                               Kimberry
                                               _______
                                                 Associates
                                                             86
File Summary
ntdsutil
• Repair
  – Should only be used if backups are not available
     • There is no guarantee that it will work
• Offline defragmentation
  – Online defragmentation automatically occurs
    every 12 hrs
     • Recovers storage, but does not reduce the size of the
       database files
• Move
  – Changes the location of the database and log files
                                                           Kimberry
                                                           _______
                                                               Associates
                                                               90
Object Deletion
• On deletion
  – IsDeleted set TRUE
  – Marked as Tombstoned
    • Default tombstone life 60 days
  – Strips most attributes from object
    • Key attributes retained, defined by attribute search
      flag
  – Moved to Deleted Objects container
                                                     Kimberry
                                                     _______
                                                        Associates
                                                91
 Garbage collection
• Deleted objects with an expired tombstone
  are removed by the garbage collection
  services
• Default garbage collection every 12 hours
                                       Kimberry
                                       _______
                                         Associates
                                                 92
Be Careful
                                      Kimberry
                                      _______
                                          Associates
                                                   93
Seminar Topics
•   Introduction
•   Anatomy of an Object
•   Data Storage
•   Securing Directory Objects
•   Advanced Delegation of Administration
•   Creating the Active Directory
•   Replication
                                       Kimberry
                                       _______
                                            Associates
                                                                  94
   UI Security Tab
%SystemRoot%\System32\dssec.dat                Do NOT display object
 [serviceInstance]
 @=7
 adminDescription=7
 adminDisplayName=7
      …………………
 [user]
 aCSPolicyName=7
 adminCount=7
                                  Displayed
 allowedAttributes=7
                                  attributes
 allowedAttributesEffective=7
                                  controlled
 allowedChildClasses=7
      …………………                     by a file
 [volume]
 adminDescription=7
 adminDisplayName=7
 allowedAttributes=7
 allowedChildClassesEffective=7
 Extended Rights
• Only a limited number of operations can be
  defined through the access mask
  – Extended rights are used to define special
    operations and property sets
    • Special operations include resetting passwords,
      managing replication and changing FSMO roles
• Extended rights are identified by
  ControlAccessRight objects created in
 cn=extended-rights,cn=configuration…
                                                   Kimberry
                                                   _______
                                                        Associates
                                                                            98
appliesTo user
                                           ACL
                   RightsGUID
 Property Sets
• Property Sets (Attribute Sets) allow
  attributes to be grouped
  – Read/Write access to the set is controlled using
    a single ACE
• The set is identified by a GUID
  – All members of the same set have the same
    GUID in their attributeSecurityGUID property
• An example of a property set is a user’s
  personal details: address, phone, etc
  – GUID: 86b8b5774a94d1…                     Kimberry
                                              _______
                                                Associates
                                                100
Detective Work
                                        Kimberry
                                        _______
                                          Associates
                                                                                101
                                                          Do GUIDs
        Lookup attributeSecurityGUID                       Match?
                                                                     Kimberry
                                                                     _______
                                                                        Associates
                                                102
 ACEs
     DENY     Allow    Allow    Allow
     SID1     SID3     SID1     SID3
      W        RX       RX       W
                                        Kimberry
                                        _______
                                          Associates
                                                          103
 Canonical Ordering
          ALLOW
           DENY            ALLOW
                            DENY         ALLOW
       administrators
        NETWORK         administrators
                          NETWORK         Users
            Full
            RD               Full
                             RD            RD
 Object ACLs
                                 ACL applies to OU
                             ACL
                       OU
                                 ACL
                                       Inheritable ACL
                          ACL
                   Directory
                    Object ACL     Explicit ACL
  ACE Ordering
            DENY      Allow      Allow      Allow
            SID20     SID3       SID1       SID3
Explicit      W         R          R         W
                                                    Kimberry
                                                    _______
                                                      Associates
                                                                 107
Inheritance Propagation
ACL
        ACL                  ACL
              ou        ou              ou        ou
  ACL
        ou         ou   ACL        ou        ou   ACL
Controlling Inheritance
        ACL                         ACL
              ou        ou                ou        ou
ou ou ou ou
                                                          Kimberry
                                                          _______
                                                            Associates
                                                                                           109
ACE Inheritance
         ACE Type
  Inheritance      Audit
       Access Mask
        Object Type                                    Applies to
                                       Object      Attribute      Extended right
   Inherited Object Type
                                         Object type that will inherit this ACE
       Trustee(SID)                     All objects OR object specified by GUID
                   Inheritance FLAGS
                    Inherit this ACE
                Only propagate one level
    Inherit only – ACE does not apply to this object
                This ACE was inherited
                                                                                   Kimberry
                                                                                   _______
                                                                                     Associates
                                                                                                   110
 dsacls
 C:\>dsacls
  C:\>dsaclscn=jill,dc=child,dc=example,dc=com
                cn=jill,dc=child,dc=example,dc=com
 Access   list:
  Access list:
 Effective
  EffectivePermissions
             Permissionson  onthis
                               thisobject
                                    objectare:
                                           are:
 Allow  CHILD\Domain      Admins
  Allow CHILD\Domain Admins             FULL
                                          FULLCONTROL
                                                CONTROL
 Allow  NT  AUTHORITY\SYSTEM
  Allow NT AUTHORITY\SYSTEM              FULL   CONTROL
                                          FULL CONTROL
 Allow
  Allow BUILTIN\Account Operators FULLCONTROL
        BUILTIN\Account      Operators   FULL    CONTROL
 Allow  NT  AUTHORITY\SELF
  Allow NT AUTHORITY\SELF                SPECIAL
                                          SPECIALACCESS
                                                    ACCESSfor
                                                           forPersonal
                                                               PersonalInformation
                                                                         Information
                                         WRITE   PROPERTY
                                          WRITE PROPERTY
                                          READ
                                           READPROPERTY
                                                  PROPERTY
 Allow  NT  AUTHORITY\SELF
  Allow NT AUTHORITY\SELF                SPECIAL
                                          SPECIALACCESS
                                                    ACCESSfor
                                                           forPhone
                                                               Phoneand
                                                                      andMail
                                                                            MailOptions
                                                                                 Options
                                          WRITE   PROPERTY
                                           WRITE PROPERTY
                                          READ
                                           READPROPERTY
                                                  PROPERTY
 Allow  NT  AUTHORITY\SELF
  Allow NT AUTHORITY\SELF                SPECIAL
                                          SPECIALACCESS
                                                    ACCESSfor
                                                           forWeb
                                                               WebInformation
                                                                    Information
                                          WRITE   PROPERTY
                                           WRITE PROPERTY
                                          READ
                                           READPROPERTY
                                                  PROPERTY
 Allow  NT  AUTHORITY\Authenticated
  Allow NT AUTHORITY\Authenticated Users   Users
                                          SPECIAL
                                           SPECIALACCESS
                                                    ACCESSfor
                                                            forPersonal
                                                                PersonalInformation
                                                                          Information
                                          READ   PROPERTY
                                           READ PROPERTY
                       OU        ACL
                                       Inheritable ACL
                          ACL
                   Directory
                    Object ACL     Explicit ACL from
                                   the schema
                      G1: access
                      denied
                                                Kimberry
                                                _______
                                                     Associates
                                                                              116
     AdminSDHolder
                         If different, replace and
                            disable inheritance
                                                             Template
                                                               ACL
                                                     ACL
              ACL
 Default Template
• The default ACL template on
  AdminSDHolder cannot be fully edited
  through the UI
  – For example, there is no Change Password
    ACE for a container
• Change the template with dsacls
    dsacls cn=adminsdholder,cn=system,dc=….
         /G “Everyone:CA;Change Password”
                                          Kimberry
                                          _______
                                               Associates
                                            118
Seminar Topics
•   Introduction
•   Anatomy of an Object
•   Data Storage
•   Securing Directory Objects
•   Advanced Delegation of Administration
•   Creating the Active Directory
•   Replication
                                    Kimberry
                                    _______
                                      Associates
                                                  119
 Problem
• The European division is a child domain of
  corporate HQ in the US
  – The European Domain Administrators need to
    authorize their own DHCP servers
     • Authorization fails
• HQ is not prepared to elevate the European
  domain admins to Enterprise admins
• How do you solve the dilemma?
                                          Kimberry
                                          _______
                                            Associates
                                                             120
Solution
           Enable auditing on the directory
                          Smile
                                                     Kimberry
                                                     _______
                                                       Associates
                                                                               121
Solution
   cn=NetServices,cn=Services,cn=Configuration,dc=example,dc=com
                                                        Enable creation of
                ACL
                                                        dHCPClass objects
                                                       Enable updating
                      ACL                              of the DhcpRoot
                            cn=DhcpRoot
                                                  2. Update root
                                  X
dHCPClass                   cn=netads01.example.com
 objects
X cn=netads03.child.example.com
                                                                    Kimberry
                                                                    _______
                                                                       Associates
                                                122
                                        Kimberry
                                        _______
                                          Associates
                                                                                    123
                    ;------------------------------------------------------
                    [template1]
                    AppliesToClasses=domainDns,organizationalUnit,container
Seminar Topics
•   Introduction
•   Anatomy of an Object
•   Data Storage
•   Object Security
•   Advanced Delegation of Administration
•   Creating the Active Directory
•   Replication
                                       Kimberry
                                       _______
                                         Associates
                                                125
Creating Domains
                                        Kimberry
                                        _______
                                          Associates
                                                              126
Log Files
• dcpromoui.log
   – Logs user interaction with the wizard and the
     promotion process
   – Increase logging levels via the Registry value
     dcpromoui
   – HKLM\Software\Microsoft\Windows\
     CurrentVersion\AdminDebug
• dcpromo.log
   – Logs promotion process
• dcpromos.log
   – Logs domain upgrades
                                                      Kimberry
                                                      _______
                                                        Associates
                                                  127
Promotion Failure
                                          Kimberry
                                          _______
                                            Associates
                                                          128
Interpreting Error/Results
Codes
• Interpret decimal codes via
  – net helpmsg xxx
  – SDK files winerror.h or lmerr.h
     • If the error does not appear in winerror.h try
       subtracting 2100 and looking it up in lmerr.h
• Error codes in the format 8007xxxx
  – Require the 8007 to be dropped and xxxx
    converted from hex to decimal
                                                  Kimberry
                                                  _______
                                                    Associates
                                                        129
                                                Kimberry
                                                _______
                                                  Associates
                                                      130
                                            Kimberry
                                            _______
                                                Associates
                           131
                   Kimberry
                   _______
                     Associates
                                                        132
• Debug logging
                                               Kimberry
                                               _______
                                                  Associates
                                                            133
                    AD replication
                     via network
    DC
                                                          Target
                                                          server
dcpromo /adv
   Restore to an
alternative location           Store to media:
                               •DVD
                               •CDROM
                               •Tape
                               •File System
                                                          Kimberry
                                                          _______
                                                            Associates
                                                                 135
    Promotion
                  Original DC            Target server
                                                         Kimberry
                                                         _______
                                                           Associates
                                                  136
                                          Kimberry
                                          _______
                                            Associates
                                                               137
Metadata Cleanup
                                                   Kimberry
                                                   _______
                                                         Associates
                                                             138
Retiring an Orphaned DC
                                                    Kimberry
                                                    _______
                                                       Associates
                                     139
                             Kimberry
                             _______
                               Associates
                                                           140
    Functionality Levels
•    Initial compatibility with current systems is
     always important
     – Some new features may not be compatible
       with older systems
       • Windows 2000 Native mode only enabled after all
         the Windows NT 4 BDCs have been retired
•    Mixed/Native mode was not designed to be
     extensible
     – Functionality levels are future proof
                                                   Kimberry
                                                   _______
                                                     Associates
                                                                 141
    Identifying the
    Functionality Level
•    A new attribute msDC-Behavior-Version
     holds the functionality level
     – This attribute is used with three objects
        • NTDS Settings
          – Shows the functionality level of the DC
        • Domain Object (domainDNS)
          – Show the current domain functionality level
        • Partitions Container
          – Shows the current forest functionality level
     – If the attribute is missing then the version is
       taken as 0 (Windows 2000)                   Kimberry
                                                   _______
                                                           Associates
                                                 142
                                       Kimberry
                                       _______
                                           Associates
                                                143
                                           Kimberry
                                           _______
                                               Associates
                                               145
Seminar Topics
•   Introduction
•   Anatomy of an Object
•   Data Storage
•   Object Security
•   Advanced Delegation of Administration
•   Creating the Active Directory
•   Replication
                                       Kimberry
                                       _______
                                         Associates
                                                                        146
 Replication Model
• Replication is at attribute level
  – The replication model is described as
    multimaster, loose consistency with
    convergence
   • Multimaster
      ¾ Changes can be made at any DC
  • Loose consistency
      ¾ There is a latency between changes being made and their
        availability throughout the enterprise
  • Convergence
     ¾ Eventually the changes will propagate to all DCs and
       conflicts will have to be detected and resolved
                                                              Kimberry
                                                              _______
                                                                  Associates
                                                                                        147
     Identifying Changes
USN 1327           SRV1                                       SRV2
                          Send me your changes
USN 1326                                                             High-watermark
                          I have all changes up to USN 1324
USN 1325
                                                                     Before:1324
USN 1324                                                             After: 1327
USN 1323
USN 1322
USN 1321
   Propagation Dampening
                                       SRV1   Send me your changes                    SRV2
                    Originating               I have all changes up to USN 2232
                 database & USN Send          I have all the changes from SRV 3 up
USN 2237         SRV1 USN 2237 9              to USN 5430
USN 2236         SRV3 USN 5432 9
USN 2235         SRV1 USN 2235 9
USN 2234         SRV3 USN 5430 8
USN 2233         SRV1 USN 2233 9
USN 2232         SRV1 USN 2232
USN 2231         SRV1 USN 2231
SRV3
More details
                                                  Kimberry
                                                  _______
                                                    Associates
                                                                           150
    Observing Metadata
C:\>repadmin
 C:\>repadmin /showmeta
               /showmeta cn=g1,dc=child,dc=example,dc=com
                          cn=g1,dc=child,dc=example,dc=com
Loc.USN
 Loc.USN originating
          originating DSA
                       DSA Org.USN
                            Org.USN Org.Time/Date
                                     Org.Time/Date Ver
                                                     Ver Attribute
                                                          Attribute
=======  ===============   =======  =============   ===  =========
 ======= =============== ======= ============= === =========
   9845
    9845 London\Srv1
          London\Srv1    9845
                          9845 2002-09-07
                                2002-09-07 15:34.02
                                            15:34.02 11 objectClass
                                                         objectClass
   9845  London\Srv1
    9845 London\Srv1     9845  2002-09-07  15:34.02  1
                          9845 2002-09-07 15:34.02 1 cn cn
   9847
    9847 London\Srv1
          London\Srv1    9847
                          9847 2002-09-07
                                2002-09-07 15:34.02
                                            15:34.02 11 description
                                                         description
   9863
    9863 London\Srv1
          London\Srv1    9863
                          9863 2002-09-07
                                2002-09-07 15:41.53
                                            15:41.53 22 member
                                                         member
   9845  London\Srv1
    9845 London\Srv1     9845  2002-09-07  15:34.02  1  instanceType
                          9845 2002-09-07 15:34.02 1 instanceType
   9845  London\Srv1
    9845 London\Srv1     9845
                          9845 2002-09-07
                                2002-09-07 15:34.02
                                            15:34.02 11 whenCreated
                                                         whenCreated
   9845  London\Srv1
    9845 London\Srv1     9845  2002-09-07  15:34.02  1  nTSecurityDescriptor
                          9845 2002-09-07 15:34.02 1 nTSecurityDescriptor
   9845  London\Srv1
    9845 London\Srv1     9845
                          9845 2002-09-07
                                2002-09-07 15:34.02
                                            15:34.02 11 name
                                                         name
   9845
    9845 London\Srv1
          London\Srv1    9845
                          9845 2002-09-07
                                2002-09-07 15:34.02
                                            15:34.02 11 objectSid
                                                         objectSid
   9845  London\Srv1
    9845 London\Srv1     9845  2002-09-07  15:34.02  1  sAMAccountName
                          9845 2002-09-07 15:34.02 1 sAMAccountName
   9845  London\Srv1
    9845 London\Srv1     9845
                          9845 2002-09-07
                                2002-09-07 15:34.02
                                            15:34.02 11 sAMAccountType
                                                         sAMAccountType
   9845  London\Srv1
    9845 London\Srv1     9845  2002-09-07  15:34.02  1  groupType
                          9845 2002-09-07 15:34.02 1 groupType
   9845  London\Srv1
    9845 London\Srv1     9845
                          9845 2002-09-07
                                2002-09-07 15:34.02
                                            15:34.02 11 objectCategory
                                                         objectCategory
                                                                  Kimberry
                                                                  _______
                                                                     Associates
                                                             151
Authoritative Restores
                                                     Kimberry
                                                     _______
                                                       Associates
                                                                      152
                                                          Kimberry
                                                          _______
                                                                Associates
                                                  153
SYSVOL Replication
                                          Kimberry
                                          _______
                                            Associates
                                                                                    154
 Resolving Conflicts
                     Unique stamp
 Other Issues
• An add or move operation to a container is
  performed on one DC as the container is
  deleted on another
  – The object is placed in the LostAndFound
    container
• Adding or moving objects on different DCs
  results in the objects having the same DNs
  – The RDN of the “newer” object is retained
  – The RDN of the other object becomes:
         RDN*CNF:<object GUID>                  Kimberry
                                                _______
                                                  Associates
                                                                          156
    Multivalued Attributes
                             Sally                                John
              Members                                   Members
                             Rod                                  Chloe
             G1                                     G1
                             Jane                                 Pete
      SRV1                                   SRV2
                                            Kimberry
                                            _______
                                                Associates
                                                        158
                                             Kimberry
                                             _______
                                                  Associates
                                                                       159
                            Microsoft IT Forum
                             19-23 November, Copenhagen, Denmark
                                                           ....connect
• Save €300 if you take advantage of the early bird
  special by registering on or before 21 October 2002.
• http://www.microsoft.com/europe/itforum/
                               i ng
                         co   m
                  fo   r
             y ou
       n k
T   ha
                                      Kimberry
                                      _______
                                        Associates