SQL SERVER – FIX – ERROR : Msg 3201, Level 16 Cannot open backup device . Operating system error 5(Access is denied.)

Recently I formatted my computer and installed fresh SQL Server in it. I installed the AdventureWorks database in my database. Once done, I wanted to run few test scripts on my database. Just like every DBA, I decided to take backup of my database – this way I can restore it back to attain an original database state. As soon as I ran the backup command I ended up with the following error. This error is due to a permissions issue on the local disk and user account which is running SQL Server. In this blog post we will talk about the operating system error.


Msg 3201, Level 16, State 1, Line 1
Cannot open backup device ‘C:\AdventureWorks.bak’. Operating system error 5(Access is denied.).

Fix/Resolution/Workaround:

I checked which user accounts my SQL Server services are running.

SQL SERVER - FIX - ERROR : Msg 3201, Level 16 Cannot open backup device . Operating system error 5(Access is denied.) NetworkError1

I gave full permission to that account to get rid of the error.

SQL SERVER - FIX - ERROR : Msg 3201, Level 16 Cannot open backup device . Operating system error 5(Access is denied.) NetworkError2

NOTE: This whole experience was done on the my personal machine and not on the production server. Please check with your network administrator for permission on production server.

Let me know if you have ever faced such error and if you have, how did you fix the error. Please leave a comment with your answer. I hope you find this blog post helpful.

Reference: Pinal Dave (https://blog.sqlauthority.com)

SQL Backup and Restore, SQL Data Storage, SQL Error Messages, SQL Server
Previous Post
SQL SERVER – Query to Recent Query on Server with Execution Plan Function to Get SQL
Next Post
SQL SERVER – Transaction Log Impact Detection Using DMV – dm_tran_database_transactions

Related Posts

Leave a Reply