Depending on how many files you’re migrating, this can be a lot.

When moving files to a new location, the permissions don’t always come with them.

There are a few ways to do this.

One favorite tool to perform file migrations isrobocopy.

When this happens, I’ll usually look into a tool calledicacls.

First, we’ll need to download an existing tool that’s already created for us.

In this case, we’re going to need a PowerShell module.

This PowerShell module can be found in thePowerShell Gallery.

If you have PowerShell v4 or later, you’ll already have some commands to grab this module quickly.

Now, we can restore this file.

To restore the permissions to the new folder path, we’d now use theRestore-Aclcommand.