The Remote Server Administration Tools (RSAT) used to be an external download that added two important PowerShell modules: ActiveDirectory and GroupPolicy. Unfortunately, major Windows updates removed installed RSAT tools so if your scripts require Active Directory cmdlets on your client, you were forced to manually identify and download the appropriate RSAT package for your new Windows 10 and install it manually.

This is somewhat easier now on Windows 10 Build 1809 and beyond. You can control RSAT status via PowerShell like this (provided you have Administrator privileges):

 
PS> Get-WindowsCapability -Online -Name *RSAT.ActiveDirectory*


Name         : Rsat.ActiveDirectory.DS-LDS.Tools~~~~0.0.1.0
State        : NotPresent
DisplayName  : RSAT: Active Directory Domain Services and Lightweight Directory Services Tools
Description  : Active Directory Domain Services (AD DS) and Active Directory Lightweight Directory Services (AD LDS) Tools include snap-ins and command-line tools for remotely managing AD DS and AD LDS on Windows Server.
DownloadSize : 5230337
InstallSize  : 17043386
 

To install RSAT, run this:

 
PS> Get-WindowsCapability -Online -Name *RSAT.ActiveDirectory* |
    Add-WindowsCapability -Online 


Path          : 
Online        : True
RestartNeeded : False




PS> Get-Module -Name ActiveDirectory -ListAvailable


    Directory: C:\WINDOWS\system32\WindowsPowerShell\v1.0\Modules


ModuleType Version    Name                                ExportedCommands                                                                                               
---------- -------    ----                                ----------------                                                                                               
Manifest   1.0.1.0    ActiveDirectory                     {Add-...
 

While you still have to download the RSAT package in some cases, you don’t have to search for the correct version and build manually any longer.


psconf.eu – PowerShell Conference EU 2019 – June 4-7, Hannover Germany – visit www.psconf.eu There aren’t too many trainings around for experienced PowerShell scripters where you really still learn something new. But there’s one place you don’t want to miss: PowerShell Conference EU - with 40 renown international speakers including PowerShell team members and MVPs, plus 350 professional and creative PowerShell scripters. Registration is open at www.psconf.eu, and the full 3-track 4-days agenda becomes available soon. Once a year it’s just a smart move to come together, update know-how, learn about security and mitigations, and bring home fresh ideas and authoritative guidance. We’d sure love to see and hear from you!

Twitter This Tip! ReTweet this Tip!

Anonymous
  • Sure, you've had the -online to install many Windows-Features via DISM / Online.
    With this command you will have the list name of the features:

        DISM /online /get-capabilities


    Yet, in 8x - 10x, they are already on the box. You just have to enabled them.
    This has been fully documented by Microsoft.

    Remote Server Administration Tools (RSAT) for Windows operating systems
    In the RSAT releases for Windows 10, Windows 8.1, and Windows 8, tools are again all enabled by default. You can open Turn Windows features on or off to disable tools that you don't want to use for Windows Vista and Windows 7.
    https://support.microsoft.com/en-us/help/2693643/remote-server-administration-tools-rsat-for-windows-operating-systems


    In Win10 1809 and beyond you have other options.

    Method 1 – Using Add a Feature Install RSAT Tools on Windows 10 version 1809

    To install RSAT Tools on Windows 10 version 1809, click Start. Click Settings and from the settings page, click Apps.
    On the right pane, under Apps & features, click Manage optional features.
    Now click + Add a feature.
    Wait for the list of features to be populated. Scroll down until you see RSAT features. Now select any of the RSAT feature that you wish to install. In this case, I am selecting RSAT: Group Policy Management Tools feature. Click Install.
    Click the back icon and wait until the feature is installed. Now you should find Group Policy Management Tools under Start > Windows Administrative Tools.


    Method 2 – Using DISM to Install RSAT Tools on Windows 10 version 1809

    In addition to installing via the graphical Settings app, you can also install specific RSAT tools via command line or automation using DISM /Add-Capability.

    On Windows 10 computer, launch the command prompt as administrator. Run the below command.
    DISM.exe /Online /Get-Capabilities

    Now in the same command prompt, run the below command to install RSAT Group policy management tools.
    DISM.exe /Online /add-capability /CapabilityName:Rsat.GroupPolicy.Management.Tools~~~~0.0.1.0

    Lastly...

    Offline install, you can use the Windows Server Feature on Demand ISO.
    https://software-download.microsoft.com/download/pr/17763.1.180914-1434.rs5_release_amd64fre_SERVER-FOD-PACKAGES_OEM_amd64fre_MULTI.iso

  • That cmdlet is kind of iffy, I have the AD module (and RSAT) installed on 2 different PCs which I use PowerShell constantly and both return NOT PRESENT, I'm guessing if you have installed the RSAT using Windows Update this gives the wrong result?