• In the past I have used and abandoned using a linked server to get AD information. It is slow and limited (e.g. max records it will return without telling you that it is not giving you everything)

    Instead, try using PowerShell. There are plenty of example out there. It is heaps quicker and I have not seen the limitations that the linked server implementation imposes.

    As a starter, have a look at https://gallery.technet.microsoft.com/scriptcenter/Powershell-script-to-5edcdaea