{"id":2251,"date":"2017-07-20T18:32:05","date_gmt":"2017-07-20T18:32:05","guid":{"rendered":"http:\/\/microsoftgeek.com\/?p=2251"},"modified":"2017-07-20T18:32:05","modified_gmt":"2017-07-20T18:32:05","slug":"deploying-a-windows-server-2016-read-only-domain-controller-rodc-with-powershell","status":"publish","type":"post","link":"https:\/\/microsoftgeek.com\/?p=2251","title":{"rendered":"Deploying a Windows Server 2016 read-only domain controller (RODC) with PowerShell"},"content":{"rendered":"<p>An RODC is a domain controller (DC) that holds a read-only copy of the Active Directory database and the SYSVOL folder. It supports unidirectional replication and only pulls data from its replication partner when the data changes on writable domain controllers. Enterprises can deploy RODCs in branch offices where they cannot guarantee physical security.<\/p>\n<h2>RODC characteristics\u00a0^<\/h2>\n<p>The following characteristics differentiate RODCs from writeable DCs (RWDC).<\/p>\n<ol>\n<li>Write operations from clients are not possible on an RODC because it holds a read-only copy of the AD database.<\/li>\n<li>An RODC does not replicate AD and SYSVOL folder data to\u00a0to RWDCs.<\/li>\n<li>An RODC holds a complete copy of the AD database, except for credentials and credential-like attributes, called a filtered attributes set (FAS).<\/li>\n<li>When an RODC receives an authentication request from users from the branch site, it forwards the request to a writeable domain controller. Read more about the authentication process on RODCs\u00a0here.<\/li>\n<li>An RODC can cache credentials of least privileged users to provide better authentication performance to branch users. If the RODC has Password Replication Policy enabled and has already cached the credentials, it processes the authentication request locally. Read more about credential caching and FAS\u00a0here.<\/li>\n<li>It is possible to delegate rights to standard domain users for RODC administration. Read more about those RODC administration operations\u00a0here.<\/li>\n<\/ol>\n<p>&nbsp;<\/p>\n<h2>Deploying an RODC\u00a0^<\/h2>\n<h3>Prerequisites<\/h3>\n<p>Before you deploy an RODC, you need to have at least one writeable domain controller in your environment. In addition, the following conditions are required:<\/p>\n<ol>\n<li>An administrator account has a strong password.<\/li>\n<li>The server has a static IP address.<\/li>\n<li>The server has the latest Windows updates installed.<\/li>\n<li>The preferred DNS server IPv4 address is configured and points to the writeable DC.<\/li>\n<\/ol>\n<h3>Installing the Active Directory Domain Service<\/h3>\n<p>First, you have to install the Active Directory Domain Service (AD DS) feature on your Windows Server 2016 computer. To do so, execute the following PowerShell command and wait for the installation to complete.<\/p>\n<div id=\"crayon-5970ec9d3e77e829501243\" class=\"crayon-syntax crayon-theme-tomorrow-copy crayon-font-monaco crayon-os-pc print-yes notranslate\" data-settings=\" minimize scroll-always\">\n<div class=\"crayon-toolbar\" data-settings=\" show\"><\/div>\n<div class=\"crayon-plain-wrap\"><\/div>\n<div class=\"crayon-main\">\n<table class=\"crayon-table\">\n<tbody>\n<tr class=\"crayon-row\">\n<td class=\"crayon-nums \" data-settings=\"show\">\n<div class=\"crayon-nums-content\">\n<div class=\"crayon-num\" data-line=\"crayon-5970ec9d3e77e829501243-1\">1<\/div>\n<\/div>\n<\/td>\n<td class=\"crayon-code\">\n<div class=\"crayon-pre\">\n<div id=\"crayon-5970ec9d3e77e829501243-1\" class=\"crayon-line\"><span class=\"crayon-v\">Install<\/span><span class=\"crayon-o\">&#8211;<\/span><span class=\"crayon-e\">WindowsFeature <\/span><span class=\"crayon-v\">AD<\/span><span class=\"crayon-o\">&#8211;<\/span><span class=\"crayon-v\">Domain<\/span><span class=\"crayon-o\">&#8211;<\/span><span class=\"crayon-v\">Services<\/span><\/div>\n<\/div>\n<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<\/div>\n<p>If everything went well, you will end up with the result that the screenshot below displays.<\/p>\n<div id=\"attachment_119922\" class=\"wp-caption aligncenter\"><img loading=\"lazy\" decoding=\"async\" class=\"size-large wp-image-119922\" src=\"https:\/\/4sysops.com\/wp-content\/uploads\/2017\/04\/Installing-the-AD-DS-role-600x102.png\" sizes=\"auto, (max-width: 600px) 100vw, 600px\" srcset=\"https:\/\/4sysops.com\/wp-content\/uploads\/2017\/04\/Installing-the-AD-DS-role-600x102.png 600w, https:\/\/4sysops.com\/wp-content\/uploads\/2017\/04\/Installing-the-AD-DS-role.png 606w\" alt=\"Installing the AD DS role\" width=\"600\" height=\"102\" \/><\/p>\n<p class=\"wp-caption-text\">Installing the AD DS role<\/p>\n<\/div>\n<h3>Promoting a domain member to an RODC<\/h3>\n<p>The next step is to promote the server to an RODC with its own DNS server and global catalog by executing the command below. It will prompt you to provide the DSRM (Directory Services Restore Mode) password and credentials that have the permissions to add this DC to the domain.<\/p>\n<div id=\"crayon-5970ec9d3e789534235794\" class=\"crayon-syntax crayon-theme-tomorrow-copy crayon-font-monaco crayon-os-pc print-yes notranslate\" data-settings=\" minimize scroll-always\">\n<div class=\"crayon-toolbar\" data-settings=\" show\"><\/div>\n<div class=\"crayon-plain-wrap\"><\/div>\n<div class=\"crayon-main\">\n<table class=\"crayon-table\">\n<tbody>\n<tr class=\"crayon-row\">\n<td class=\"crayon-nums \" data-settings=\"show\">\n<div class=\"crayon-nums-content\">\n<div class=\"crayon-num\" data-line=\"crayon-5970ec9d3e789534235794-1\">1<\/div>\n<\/div>\n<\/td>\n<td class=\"crayon-code\">\n<div class=\"crayon-pre\">\n<div id=\"crayon-5970ec9d3e789534235794-1\" class=\"crayon-line\"><span class=\"crayon-v\">Install<\/span><span class=\"crayon-o\">&#8211;<\/span><span class=\"crayon-v\">ADDSDomainController<\/span> <span class=\"crayon-o\">&#8211;<\/span><span class=\"crayon-e\">Credential<\/span> <span class=\"crayon-sy\">(<\/span><span class=\"crayon-v\">Get<\/span><span class=\"crayon-o\">&#8211;<\/span><span class=\"crayon-v\">Credential<\/span><span class=\"crayon-sy\">)<\/span> <span class=\"crayon-o\">&#8211;<\/span><span class=\"crayon-v\">DomainName<\/span> <span class=\"crayon-o\">&lt;<\/span><span class=\"crayon-v\">domainName<\/span><span class=\"crayon-o\">&gt;<\/span> <span class=\"crayon-o\">&#8211;<\/span><span class=\"crayon-v\">InstallDNS<\/span><span class=\"crayon-o\">:<\/span><span class=\"crayon-sy\">$<\/span><span class=\"crayon-t\">true<\/span> <span class=\"crayon-o\">&#8211;<\/span><span class=\"crayon-v\">ReadOnlyReplica<\/span><span class=\"crayon-o\">:<\/span><span class=\"crayon-sy\">$<\/span><span class=\"crayon-t\">true<\/span> <span class=\"crayon-o\">&#8211;<\/span><span class=\"crayon-i\">SiteName<\/span> <span class=\"crayon-s\">&#8220;Default-First-Site-Name&#8221;<\/span> <span class=\"crayon-o\">&#8211;<\/span><span class=\"crayon-v\">Force<\/span><span class=\"crayon-o\">:<\/span><span class=\"crayon-sy\">$<\/span><span class=\"crayon-t\">true<\/span><\/div>\n<\/div>\n<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<\/div>\n<p>You use the same cmdlet (<em>Install-ADDSDomainController<\/em>) for deploying a writable DC. The only difference is the\u00a0<em>ReadOnlyReplica<\/em>\u00a0parameter that installs the domain controller as an RODC. If you don&#8217;t specify the path to the Active Directory log, the database, and the SYSVOL folder, it will use the default paths.<\/p>\n<p>After executing the command and successfully promoting your server to an RODC, the server will automatically reboot.<\/p>\n<div id=\"attachment_119923\" class=\"wp-caption aligncenter\"><img loading=\"lazy\" decoding=\"async\" class=\"size-large wp-image-119923\" src=\"https:\/\/4sysops.com\/wp-content\/uploads\/2017\/04\/Promoting-a-server-to-an-RODC-600x249.png\" sizes=\"auto, (max-width: 600px) 100vw, 600px\" srcset=\"https:\/\/4sysops.com\/wp-content\/uploads\/2017\/04\/Promoting-a-server-to-an-RODC-600x249.png 600w, https:\/\/4sysops.com\/wp-content\/uploads\/2017\/04\/Promoting-a-server-to-an-RODC.png 1024w\" alt=\"Promoting a server to an RODC\" width=\"600\" height=\"249\" \/><\/p>\n<p class=\"wp-caption-text\">Promoting a server to an RODC<\/p>\n<\/div>\n<p>&nbsp;<\/p>\n<h2>Configuring RODC password\u00a0caching\u00a0^<\/h2>\n<p>The new RODC it still using a writeable DC for authenticating branch users and computers. To force the RODC to authenticate users and computer accounts, you have to ensure that the RODC caches the corresponding credentials. For this, you have to configure the Password Replication Policy (PRP) to ensure that it replicates and caches the credentials on the RODC for subsequent authentications.<\/p>\n<h3>Allowed and Denied Password Replication Groups<\/h3>\n<p>There are two groups in PRP: the Allowed and the Denied Password Replication Groups. The RODC caches account credentials for members of the Allowed Password Replication Group but not those of the Denied Password Replication Group. By default, accounts from privileged groups such as Enterprise, Schema, and Domain Admins are members of the Denied RODC Password Replication Group. To get the complete list, execute the following command:<\/p>\n<div id=\"crayon-5970ec9d3e78f545871458\" class=\"crayon-syntax crayon-theme-tomorrow-copy crayon-font-monaco crayon-os-pc print-yes notranslate\" data-settings=\" minimize scroll-always\">\n<div class=\"crayon-toolbar\" data-settings=\" show\"><\/div>\n<div class=\"crayon-plain-wrap\"><\/div>\n<div class=\"crayon-main\">\n<table class=\"crayon-table\">\n<tbody>\n<tr class=\"crayon-row\">\n<td class=\"crayon-nums \" data-settings=\"show\">\n<div class=\"crayon-nums-content\">\n<div class=\"crayon-num\" data-line=\"crayon-5970ec9d3e78f545871458-1\">1<\/div>\n<\/div>\n<\/td>\n<td class=\"crayon-code\">\n<div class=\"crayon-pre\">\n<div id=\"crayon-5970ec9d3e78f545871458-1\" class=\"crayon-line\"><span class=\"crayon-v\">Get<\/span><span class=\"crayon-o\">&#8211;<\/span><span class=\"crayon-v\">ADGroupMember<\/span> <span class=\"crayon-o\">&#8211;<\/span><span class=\"crayon-i\">Identity<\/span> <span class=\"crayon-s\">&#8220;Denied RODC Password Replication Group&#8221;<\/span> <span class=\"crayon-o\">|<\/span> <span class=\"crayon-e\">ft <\/span><span class=\"crayon-v\">DistinguishedName<\/span><span class=\"crayon-sy\">,<\/span> <span class=\"crayon-v\">Name<\/span><span class=\"crayon-sy\">,<\/span> <span class=\"crayon-v\">ObjectClass<\/span><\/div>\n<\/div>\n<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<\/div>\n<div id=\"attachment_119952\" class=\"wp-caption aligncenter\"><img loading=\"lazy\" decoding=\"async\" class=\"size-large wp-image-119952\" src=\"https:\/\/4sysops.com\/wp-content\/uploads\/2017\/04\/Getting-a-list-of-Denied-RODC-Replication-Group-members-600x107.png\" sizes=\"auto, (max-width: 600px) 100vw, 600px\" srcset=\"https:\/\/4sysops.com\/wp-content\/uploads\/2017\/04\/Getting-a-list-of-Denied-RODC-Replication-Group-members-600x107.png 600w, https:\/\/4sysops.com\/wp-content\/uploads\/2017\/04\/Getting-a-list-of-Denied-RODC-Replication-Group-members.png 1024w\" alt=\"Getting a list of Denied RODC Replication Group members\" width=\"600\" height=\"107\" \/><\/p>\n<p class=\"wp-caption-text\">Getting a list of Denied RODC Replication Group members<\/p>\n<\/div>\n<h3>Adding users accounts to the Allowed Password Replication Group<\/h3>\n<p>To add branch user accounts to the Allowed RODC Password Replication Group without the system asking for confirmation, execute the following PowerShell command:<\/p>\n<div id=\"crayon-5970ec9d3e794072471868\" class=\"crayon-syntax crayon-theme-tomorrow-copy crayon-font-monaco crayon-os-pc print-yes notranslate\" data-settings=\" minimize scroll-always\">\n<div class=\"crayon-toolbar\" data-settings=\" show\"><\/div>\n<div class=\"crayon-plain-wrap\"><\/div>\n<div class=\"crayon-main\">\n<table class=\"crayon-table\">\n<tbody>\n<tr class=\"crayon-row\">\n<td class=\"crayon-nums \" data-settings=\"show\">\n<div class=\"crayon-nums-content\">\n<div class=\"crayon-num\" data-line=\"crayon-5970ec9d3e794072471868-1\">1<\/div>\n<\/div>\n<\/td>\n<td class=\"crayon-code\">\n<div class=\"crayon-pre\">\n<div id=\"crayon-5970ec9d3e794072471868-1\" class=\"crayon-line\"><span class=\"crayon-v\">Get<\/span><span class=\"crayon-o\">&#8211;<\/span><span class=\"crayon-v\">ADUser<\/span> <span class=\"crayon-o\">&#8211;<\/span><span class=\"crayon-i\">SearchBase<\/span> <span class=\"crayon-s\">&#8216;OU=Students,DC=yourdomain,DC=com&#8217;<\/span> <span class=\"crayon-o\">&#8211;<\/span><span class=\"crayon-e \">Filter *<\/span> <span class=\"crayon-o\">|<\/span> <span class=\"crayon-st\">ForEach<\/span><span class=\"crayon-o\">&#8211;<\/span><span class=\"crayon-t\">Object<\/span> <span class=\"crayon-sy\">{<\/span><span class=\"crayon-v\">Add<\/span><span class=\"crayon-o\">&#8211;<\/span><span class=\"crayon-v\">ADGroupMember<\/span> <span class=\"crayon-o\">&#8211;<\/span><span class=\"crayon-i\">Identity<\/span> <span class=\"crayon-s\">&#8216;Allowed RODC Password Replication Group&#8217;<\/span> <span class=\"crayon-o\">&#8211;<\/span><span class=\"crayon-i\">Members<\/span> <span class=\"crayon-sy\">$<\/span><span class=\"crayon-v\">_<\/span> <span class=\"crayon-o\">&#8211;<\/span><span class=\"crayon-v\">Confirm<\/span><span class=\"crayon-o\">:<\/span><span class=\"crayon-sy\">$<\/span><span class=\"crayon-t\">false<\/span> <span class=\"crayon-sy\">}<\/span><\/div>\n<\/div>\n<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<\/div>\n<p>The command fetches all user accounts from the Students organizational unit (OU) and then pipes those accounts to the\u00a0<em>Add-ADGroupMember<\/em>\u00a0cmdlet, which adds them to the group. To confirm that the operation succeeded, run the following command.<\/p>\n<div id=\"crayon-5970ec9d3e798115045668\" class=\"crayon-syntax crayon-theme-tomorrow-copy crayon-font-monaco crayon-os-pc print-yes notranslate\" data-settings=\" minimize scroll-always\">\n<div class=\"crayon-toolbar\" data-settings=\" show\"><\/div>\n<div class=\"crayon-plain-wrap\"><\/div>\n<div class=\"crayon-main\">\n<table class=\"crayon-table\">\n<tbody>\n<tr class=\"crayon-row\">\n<td class=\"crayon-nums \" data-settings=\"show\">\n<div class=\"crayon-nums-content\">\n<div class=\"crayon-num\" data-line=\"crayon-5970ec9d3e798115045668-1\">1<\/div>\n<\/div>\n<\/td>\n<td class=\"crayon-code\">\n<div class=\"crayon-pre\">\n<div id=\"crayon-5970ec9d3e798115045668-1\" class=\"crayon-line\"><span class=\"crayon-v\">Get<\/span><span class=\"crayon-o\">&#8211;<\/span><span class=\"crayon-v\">ADGroupMember<\/span> <span class=\"crayon-o\">&#8211;<\/span><span class=\"crayon-i\">Identity<\/span> <span class=\"crayon-s\">&#8220;Allowed RODC Password Replication Group&#8221;<\/span> <span class=\"crayon-o\">|<\/span> <span class=\"crayon-e\">ft <\/span><span class=\"crayon-v\">DistinguishedName<\/span><span class=\"crayon-sy\">,<\/span> <span class=\"crayon-v\">Name<\/span><span class=\"crayon-sy\">,<\/span> <span class=\"crayon-v\">ObjectClass<\/span><\/div>\n<\/div>\n<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<\/div>\n<div id=\"attachment_119954\" class=\"wp-caption aligncenter\"><img loading=\"lazy\" decoding=\"async\" class=\"size-large wp-image-119954\" src=\"https:\/\/4sysops.com\/wp-content\/uploads\/2017\/04\/Adding-user-accounts-to-the-Allowed-Password-Replication-Group-600x143.png\" sizes=\"auto, (max-width: 600px) 100vw, 600px\" srcset=\"https:\/\/4sysops.com\/wp-content\/uploads\/2017\/04\/Adding-user-accounts-to-the-Allowed-Password-Replication-Group-600x143.png 600w, https:\/\/4sysops.com\/wp-content\/uploads\/2017\/04\/Adding-user-accounts-to-the-Allowed-Password-Replication-Group.png 1024w\" alt=\"Adding user accounts to the Allowed Password Replication Group\" width=\"600\" height=\"143\" \/><\/p>\n<p class=\"wp-caption-text\">Adding user accounts to the Allowed Password Replication Group<\/p>\n<\/div>\n<h3>Prepopulating user passwords<\/h3>\n<p>If you would like to cache account credentials on the RODC before users log in, you can prepopulate their passwords by executing the following commands:<\/p>\n<div id=\"crayon-5970ec9d3e79d672764951\" class=\"crayon-syntax crayon-theme-tomorrow-copy crayon-font-monaco crayon-os-pc print-yes notranslate\" data-settings=\" minimize scroll-always\">\n<div class=\"crayon-toolbar\" data-settings=\" show\"><\/div>\n<div class=\"crayon-plain-wrap\"><\/div>\n<div class=\"crayon-main\">\n<table class=\"crayon-table\">\n<tbody>\n<tr class=\"crayon-row\">\n<td class=\"crayon-nums \" data-settings=\"show\">\n<div class=\"crayon-nums-content\">\n<div class=\"crayon-num\" data-line=\"crayon-5970ec9d3e79d672764951-1\">1<\/div>\n<div class=\"crayon-num crayon-striped-num\" data-line=\"crayon-5970ec9d3e79d672764951-2\">2<\/div>\n<div class=\"crayon-num\" data-line=\"crayon-5970ec9d3e79d672764951-3\">3<\/div>\n<div class=\"crayon-num crayon-striped-num\" data-line=\"crayon-5970ec9d3e79d672764951-4\">4<\/div>\n<\/div>\n<\/td>\n<td class=\"crayon-code\">\n<div class=\"crayon-pre\">\n<div id=\"crayon-5970ec9d3e79d672764951-1\" class=\"crayon-line\"><span class=\"crayon-sy\">$<\/span><span class=\"crayon-v\">users<\/span> <span class=\"crayon-o\">=<\/span> <span class=\"crayon-v\">Get<\/span><span class=\"crayon-o\">&#8211;<\/span><span class=\"crayon-v\">ADUser<\/span> <span class=\"crayon-o\">&#8211;<\/span><span class=\"crayon-i\">SearchBase<\/span> <span class=\"crayon-s\">&#8220;OU=Branch Users,dc=yourdomain,dc=com&#8221;<\/span> \u2011<span class=\"crayon-e \">Filter *<\/span><\/div>\n<div id=\"crayon-5970ec9d3e79d672764951-2\" class=\"crayon-line crayon-striped-line\"><span class=\"crayon-st\">foreach<\/span> <span class=\"crayon-sy\">(<\/span><span class=\"crayon-sy\">$<\/span><span class=\"crayon-e\">user <\/span><span class=\"crayon-st\">in<\/span> <span class=\"crayon-sy\">$<\/span><span class=\"crayon-v\">users<\/span><span class=\"crayon-sy\">)<\/span> <span class=\"crayon-sy\">{<\/span><\/div>\n<div id=\"crayon-5970ec9d3e79d672764951-3\" class=\"crayon-line\"><span class=\"crayon-h\">\u00a0\u00a0 <\/span><span class=\"crayon-v\">Get<\/span><span class=\"crayon-o\">&#8211;<\/span><span class=\"crayon-v\">ADObject<\/span> <span class=\"crayon-o\">&#8211;<\/span><span class=\"crayon-i\">identity<\/span> <span class=\"crayon-sy\">$<\/span><span class=\"crayon-v\">user<\/span> <span class=\"crayon-o\">|<\/span> <span class=\"crayon-v\">Sync<\/span><span class=\"crayon-o\">&#8211;<\/span><span class=\"crayon-v\">ADObject<\/span> <span class=\"crayon-o\">&#8211;<\/span><span class=\"crayon-e\">Source <\/span><span class=\"crayon-i\">SERVER2016<\/span> \u2011<span class=\"crayon-e\">Destination <\/span><span class=\"crayon-v\">SRV<\/span><span class=\"crayon-o\">&#8211;<\/span><span class=\"crayon-cn\">02RODC<\/span> <span class=\"crayon-o\">&#8211;<\/span><span class=\"crayon-i\">PasswordOnly<\/span><\/div>\n<div id=\"crayon-5970ec9d3e79d672764951-4\" class=\"crayon-line crayon-striped-line\"><span class=\"crayon-sy\">}<\/span><\/div>\n<\/div>\n<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<\/div>\n<h3>Getting an account list of stored RODC passwords<\/h3>\n<p>To get the list of accounts with cached passwords on the RODC, execute the following command:<\/p>\n<div id=\"crayon-5970ec9d3e7a1856693591\" class=\"crayon-syntax crayon-theme-tomorrow-copy crayon-font-monaco crayon-os-pc print-yes notranslate\" data-settings=\" minimize scroll-always\">\n<div class=\"crayon-toolbar\" data-settings=\" show\"><\/div>\n<div class=\"crayon-plain-wrap\"><\/div>\n<div class=\"crayon-main\">\n<table class=\"crayon-table\">\n<tbody>\n<tr class=\"crayon-row\">\n<td class=\"crayon-nums \" data-settings=\"show\">\n<div class=\"crayon-nums-content\">\n<div class=\"crayon-num\" data-line=\"crayon-5970ec9d3e7a1856693591-1\">1<\/div>\n<\/div>\n<\/td>\n<td class=\"crayon-code\">\n<div class=\"crayon-pre\">\n<div id=\"crayon-5970ec9d3e7a1856693591-1\" class=\"crayon-line\"><span class=\"crayon-v\">Get<\/span><span class=\"crayon-o\">&#8211;<\/span><span class=\"crayon-v\">ADDomainControllerPasswordReplicationPolicyUsage<\/span> <span class=\"crayon-o\">&#8211;<\/span><span class=\"crayon-i\">Identity<\/span> <span class=\"crayon-s\">&#8220;SRV-02&#8221;<\/span> \u2011<span class=\"crayon-v\">RevealedAccounts<\/span> <span class=\"crayon-o\">|<\/span> <span class=\"crayon-e\">ft <\/span><span class=\"crayon-v\">Name<\/span><span class=\"crayon-sy\">,<\/span><span class=\"crayon-v\">ObjectClass<\/span><\/div>\n<\/div>\n<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<\/div>\n<p>This will return the list of accounts with names and object classes of credentials stored or cached on the RODC with the name &#8220;SRV-02.&#8221;<\/p>\n<div id=\"attachment_119957\" class=\"wp-caption aligncenter\"><img loading=\"lazy\" decoding=\"async\" class=\"size-large wp-image-119957\" src=\"https:\/\/4sysops.com\/wp-content\/uploads\/2017\/04\/Getting-a-list-of-accounts-with-passwords-stored-on-the-RODC-600x106.png\" sizes=\"auto, (max-width: 600px) 100vw, 600px\" srcset=\"https:\/\/4sysops.com\/wp-content\/uploads\/2017\/04\/Getting-a-list-of-accounts-with-passwords-stored-on-the-RODC-600x106.png 600w, https:\/\/4sysops.com\/wp-content\/uploads\/2017\/04\/Getting-a-list-of-accounts-with-passwords-stored-on-the-RODC.png 1024w\" alt=\"Getting a list of accounts with passwords stored on the RODC\" width=\"600\" height=\"106\" \/><\/p>\n<p class=\"wp-caption-text\">Getting a list of accounts with passwords stored on the RODC<\/p>\n<\/div>\n<h3>Clearing the RODC password cache<\/h3>\n<p>Once an RODC caches passwords, there is no way to delete them on it directly. However, resetting the passwords on a writeable DC also removes them from the password cache on the RODC. The same applies to computers; resetting their accounts removes their credentials from the RODC.<\/p>\n<p>Let&#8217;s reset a password of the user with the name &#8220;John Ark&#8221;:<\/p>\n<div id=\"crayon-5970ec9d3e7a6466927752\" class=\"crayon-syntax crayon-theme-tomorrow-copy crayon-font-monaco crayon-os-pc print-yes notranslate\" data-settings=\" minimize scroll-always\">\n<div class=\"crayon-toolbar\" data-settings=\" show\"><\/div>\n<div class=\"crayon-plain-wrap\"><\/div>\n<div class=\"crayon-main\">\n<table class=\"crayon-table\">\n<tbody>\n<tr class=\"crayon-row\">\n<td class=\"crayon-nums \" data-settings=\"show\">\n<div class=\"crayon-nums-content\">\n<div class=\"crayon-num\" data-line=\"crayon-5970ec9d3e7a6466927752-1\">1<\/div>\n<\/div>\n<\/td>\n<td class=\"crayon-code\">\n<div class=\"crayon-pre\">\n<div id=\"crayon-5970ec9d3e7a6466927752-1\" class=\"crayon-line\"><span class=\"crayon-v\">Set<\/span><span class=\"crayon-o\">&#8211;<\/span><span class=\"crayon-e\">ADAccountPassword <\/span><span class=\"crayon-v\">jark<\/span> <span class=\"crayon-o\">&#8211;<\/span><span class=\"crayon-e\">NewPassword<\/span> <span class=\"crayon-sy\">(<\/span><span class=\"crayon-v\">Read<\/span><span class=\"crayon-o\">&#8211;<\/span><span class=\"crayon-v\">Host<\/span> <span class=\"crayon-o\">&#8211;<\/span><span class=\"crayon-i\">prompt<\/span> <span class=\"crayon-s\">&#8220;Provide New Password&#8221;<\/span> <span class=\"crayon-o\">&#8211;<\/span><span class=\"crayon-v\">AsSecureString<\/span><span class=\"crayon-sy\">)<\/span><\/div>\n<\/div>\n<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<\/div>\n<p>If you list the accounts with cached passwords using Get-ADDomainControllerPasswordReplicationPolicyUsage, John Ark&#8217;s account won&#8217;t appear anymore.<\/p>\n<div id=\"attachment_119958\" class=\"wp-caption aligncenter\"><img loading=\"lazy\" decoding=\"async\" class=\"size-large wp-image-119958\" src=\"https:\/\/4sysops.com\/wp-content\/uploads\/2017\/04\/Accounts-with-cached-passwords-after-resetting-the-password-of-a-user-600x102.png\" sizes=\"auto, (max-width: 600px) 100vw, 600px\" srcset=\"https:\/\/4sysops.com\/wp-content\/uploads\/2017\/04\/Accounts-with-cached-passwords-after-resetting-the-password-of-a-user-600x102.png 600w, https:\/\/4sysops.com\/wp-content\/uploads\/2017\/04\/Accounts-with-cached-passwords-after-resetting-the-password-of-a-user.png 1019w\" alt=\"Accounts with cached passwords after resetting the password of a user\" width=\"600\" height=\"102\" \/><\/p>\n<p class=\"wp-caption-text\">Accounts with cached passwords after resetting the password of a user<\/p>\n<\/div>\n","protected":false},"excerpt":{"rendered":"<p>An RODC is a domain controller (DC) that holds a read-only copy of the Active Directory database and the SYSVOL folder. It supports unidirectional replication and only pulls data from its replication partner when the data changes on writable domain controllers. Enterprises can deploy RODCs in branch offices where they cannot guarantee physical security. RODC [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[59,63],"tags":[],"class_list":["post-2251","post","type-post","status-publish","format-standard","hentry","category-powershell","category-server-2016-2016"],"_links":{"self":[{"href":"https:\/\/microsoftgeek.com\/index.php?rest_route=\/wp\/v2\/posts\/2251","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/microsoftgeek.com\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/microsoftgeek.com\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/microsoftgeek.com\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/microsoftgeek.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=2251"}],"version-history":[{"count":1,"href":"https:\/\/microsoftgeek.com\/index.php?rest_route=\/wp\/v2\/posts\/2251\/revisions"}],"predecessor-version":[{"id":2252,"href":"https:\/\/microsoftgeek.com\/index.php?rest_route=\/wp\/v2\/posts\/2251\/revisions\/2252"}],"wp:attachment":[{"href":"https:\/\/microsoftgeek.com\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=2251"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/microsoftgeek.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=2251"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/microsoftgeek.com\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=2251"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}