“RESTORE HEADERONLY is terminating abnormally” error when restoring backup

backup-restorationsql-server-2008sql-server-2008-r2

When I try to restore a database backup file, I get the following error:

An exception occurred while executing a Transact-SQL statement or batch.
(Microsoft.SqlServer.ConnectionInfo)

Additional information:

Cannot open backup device 'C:\Domains\Backup.bak'. Operating system error 5(Access is denied.).

RESTORE HEADERONLY is terminating abnormally. (Microsoft SQL Server, Error: 3201)

This only happens on our remote machine. The backup file restores fine locally. The user has administrative privileges on the remote machine and the network service has access to the database and backup file. What is the problem here?

Best Answer

The SQL user needs the rights to access that location. Network service and local user are not used by SQL anymore.