troubleshooting Question

Roaming Profiles - AD Attribute

Avatar of mrfite
mrfiteFlag for United States of America asked on
Windows OSActive DirectoryShell ScriptingPowershell
1 Comment1 Solution421 ViewsLast Modified:
I am stuck.

I am trying to put together a termination script for former employees.

The issue is that we use gpo's to redirect their profiles to different servers.  One other issue is that when a user's username changes (ie married, divorced, etc), we continue to redirect their roaming profile to the old profile created under the original user account.

I have tried using the following AD attributes:
msTSProfilePath
msTSHomeDirectory
ProfilePath
psbase.InvokeGet("terminalservicesHomeDirectory")
psbase.InvokeGet("terminalservicesprofilepath")

The above all show as blank.  

If we manually input the users information in AD under Remote Desktop Services Profile, the correct information is only shown under psbase.InvokeGet("terminalservicesHomeDirectory") and psbase.InvokeGet("terminalservicesprofilepath")

Is there an AD attribute that holds the current roaming profile and roaming home directory information even if that location is redirected based on a GPO?


***The purpose of the script is to find a user's roaming profiles and roaming home directory on a file server and then to move those folders to an archive server after the user is no longer with us.
ASKER CERTIFIED SOLUTION
yo_bee
Director of Information Technology

Our community of experts have been thoroughly vetted for their expertise and industry experience.

Join our community to see this answer!
Unlock 1 Answer and 1 Comment.
Start Free Trial
Learn from the best

Network and collaborate with thousands of CTOs, CISOs, and IT Pros rooting for you and your success.

Andrew Hancock - VMware vExpert
See if this solution works for you by signing up for a 7 day free trial.
Unlock 1 Answer and 1 Comment.
Try for 7 days

”The time we save is the biggest benefit of E-E to our team. What could take multiple guys 2 hours or more each to find is accessed in around 15 minutes on Experts Exchange.

-Mike Kapnisakis, Warner Bros