(Solved) SQL Server backup to network share access denied

How to solve SQL Server backup to network share access denied (Operating system error 5)? Here are solutions and an effective alternative.

By @Delia Last Updated June 13, 2023

Operating system error 5: Access is denied

Many users have tried to backup SQL Server database to network share for better security or easier migration, but ended up receiving “Cannot open backup device. Operating system error 5 (Access is denied)”.

Why does this problem occur? As the prompt says, the backup terminates abnormally because it cannot open the backup device. This could be caused by 2 reasons:

1. The account you use to log in to SQL server does not have permission to read or write to the target share.

2. There is already a backup file with the same name in the target path, and it is read-only.

With this perception, it’s not difficult to solve the access denied problem.

How to solve SQL Server backup to network share access denied?

Almost all the backup methods support you to backup SQL database to network share - SSMS backup wizard, T-SQL or command line. But whichever way you use, you may find the SQL Server cannot access network share.

To avoid the Operating system error 5, you could refer to the following troubleshooting tutorial, or try an effective alternative directly.

1. Solutions for SQL Server cannot access network share

If the access to the specified network drive or share is denied, as mentioned earlier, you should first have a look at the target folder to see whether it contains a backup file of the same name.

If yes, right-click it and choose Properties to check its attribute. For a Read-only bak file, please uncheck its select box and hit Apply to confirm the change.

If not, then the access error should be caused by permissions issue. You could try following steps to fix it:

1. Press Win + R and type “services.msc” in the Run window. Press Enter to execute it.

2. Right-click “SQL Server (MSSQLSERVER)” in the Services interface, choose Properties > Log On to find (or copy) the full name of the account you use to log in the SQL Server.

3. Then, right-click the target network share and go to Properties > Security. If the account you just found is already listed in the “Group or user names”, please Edit it and Allow its Full Control.

Otherwise, you need to click Edit > Add to type the account name, click OK to search for it, select the correct one to add and give it full permissions.

If this network share does not require permission protection, you can also allow full control to Everyone.

4. Apply the changes and hit OK to exit. Then you can retry the SQL Server backup to see if the access denied problem has been solved.

2. Effective software to backup SQL database to network share without error

Apart from Operating system error 5 (Access is denied), there may be some other problems that arise when backing up SQL Server to network drive. If you are tired of troubleshooting or cannot complete the backup even after trying common solutions, maybe it’s time to try 3rd party software.

AOMEI Cyber Backup is a centralized backup and management solution for all SQL Servers and virtual machines within LAN. It contains a SQL Server Backup feature which supports SQL 2005-2022 and enables you to backup selected databases or instances to network share smoothly. Besides SQL databases, it also supports VMware and Hyper-V VMs backup.

Have a try on the 30-day free trial and get a up-to 60% off discount:

Download Free TrialMicrosoft SQL Server 2005-2022
Centralized and secure SQL backup

To set up the SQL backup software: run the installed program on the server machine, navigate to Source Device -> Microsoft SQL -> Add Microsoft SQL.

Choose Download proxy program (or Copy link) and install it on to the device with SQL Server installed. Then, click Already installed proxy and select the device to Confirm it.

After that, click  -> Authentication to validate the database instance. And then you can follow the steps below to back up SQL database.

How to backup SQL database to network share via easier alternative

1. Click Backup Task -> Create New Task, and select Backup Type as Microsoft SQL Backup.

2. Tap Device Name to select the SQL instances and databases for backup. You can select one or multiple databases as you need.

3. Specify a local path or network path as backup Target. To back up SQL database to remote location, you could click Add a new network storage to specify the network share. The added path will be saved in Add storage.

4. Set up a Schedule (optional) to run the SQL database backup daily/weekly/monthly, and set the backup method  as Full/Incremental/Differential.

✍More useful features:

  • Backup Cleanup helps you to delete older backup version automatically and therefore save storage space.
  • Email Notification enables you to receive email notifications when the task is abnormal or successful.

Now you can click Start Backup to create and execute the SQL Server automatic backup to network share.

As I tried, even when the SQL Server log-on account doesn’t have read & write permissions for the network share, the database backup can be fulfilled successfully. And the network share you’ve added once will be saved for quick use later. Easy peasy.

Final words

Why does SQL Server backup to network share access denied? This is usually because the account you log in SQL Server as doesn’t have the permissions to read and write to the target path. To solve it, you can either provide full control to the account, or use an effective alternative software to perform the backup.

AOMEI Cyber Backup is such a program that supports backing up multiple SQL databases or even instances to network share. With it, you won’t be bothered by the Operating system error 5 (Access is denied) or some other problems.