If you use the mklink command under CMD (Command Prompt) or Powershell, it is very likely that you will get the message
C:\>mklink C:\Users\danie\Apple\MobileSync\Backup p:\05_DataBackUp\iPhone\
Access is denied.
In this case, an attempt was made to bend the backup directory under iTunes to another storage location via a symlink. Symlinks, so-called symbolic links, are very well suited for this purpose, since they insert a corresponding reference into the system. Whenever a program tries to save files and folders under the specified path, they are saved under the referring path.
Possible causes and solutions
Unfortunately, the error message “Access is denied” is often displayed, which can have several reasons.
Run CMD as administrator
The first thing to make sure is that you run the CMD prompt or PowerShell as an administrator:
- Windows Start menu enter CMD
- Right-click on “Command Prompt” and click “Run as administrator“
Often the spelling is also suspected or can have a negative effect. There are spellings where the directory paths are put in quotation marks. However, this is not mandatory if the directory path does not contain any spaces.
Very often, a lack of privileges is cited as a possible cause. But this should not be the reason, because if you run the command prompt as administrator, you have pretty much all privileges. However, it may be worth a try. To view or change the permissions of the corresponding directory:
- Right click on the directory and select “Properties“.
- Select “Security” tab
Folder already exists
However, it is very likely that the folder for which the link is to be created via mklink already exists. Then it cannot be overwritten with the new link. That means you have to delete the directory first. In the example above it was the folder “Backup” under “C:\”. If you delete this folder, you can also run mklink.