Mapped drive stopped working with %username%

I'm trying to map a drive through group policy and create a folder for users profiles. I'm using the below but the drive isn't being mapped. If I remove the %username% the drive gets mapped.

\\SERVERNAME\UserProfiles\%username%

The user I'm testing it with is an administrator and has full control permissions to the 'UserProfiles' folder.
gpresult is showing it is being pulled through.
It's using a drive letter not being used anywhere else.
It has worked in the past.
Windows Server 2008 R2 Standard

Any ideas why this could be happening?
ryank85Asked:
Who is Participating?
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

Adam BrownSenior Systems AdminCommented:
How are you deploying? Group Policy Preferences or some other technique?
ryank85Author Commented:
I'm deploying it with Group Policy Preferences.
Shaun VermaakTechnical SpecialistCommented:
Press F3 for list. Use this:
%LogonUser%

Open in new window

gpp.png
CEOs need to know what they should worry about

Nearly every week during the past few years has featured a headline about the latest data breach, malware attack, ransomware demand, or unrecoverable corporate data loss. Those stories are frequently followed by news that the CEOs at those companies were forced to resign.

ryank85Author Commented:
I've tried it with %LogonUser% as well but have the same issue.
Scott SilvaNetwork AdministratorCommented:
Shouldn't the link need to end with a backslash too? Just tossing it out there...
Ben Personick (Previously QCubed)Lead SaaS Infrastructure EngineerCommented:
1) Are you SURE that mapping the user's home drive via the user's Object in AS wouldn't be the simpler method?

2) Does the user have permissions to /r/w/e on "\\SERVERNAME\UserProfiles\%username%" (That is the username Folder itself) & said folder exists?

3) Are you SURE it wouldn't be easier to just create the user's home drives through their AD User Objects?

I ask because if you create the User's Home drives by putting "\\SERVERNAME\UserProfiles\%username%" into their user object right in AD, the folder is automatically created with correct permissions by active directory, and every time you copy a user it automatically provisions the user's home directory.

It's a very one and done solution.

I only use scripts or group policy to map the other drives which require having a specific set of group memberships, and those group memberships are already the same security groups granting them permission to map the drive in those cases.

I will bet you dollars to donuts you have created a whole bunch of user folders by hand, but only the administrator can reach them, not the users themselves, you need to edit each folder's ACLs (NTFS Permissions) to make sure each user is associated with each folder correctly)

Oh, or, you COULD just use the user's Home Drive setting in their User object in AD which takes care of all of that for you.   Just saying...  USE IT. :) ;)  :)

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
ryank85Author Commented:
Thanks Ben, using the home drive was exactly what I needed to do.
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today
Windows OS

From novice to tech pro — start learning today.