SQL Server administration and T-SQL development, Web Programming with ASP.NET, HTML5 and Javascript, Windows Phone 8 app development, SAP Smartforms and ABAP Programming, Windows 7, Visual Studio and MS Office software

Development Forums for Programmer, Administrators and Users

Development resources, articles, tutorials, code samples and tools and downloads for ASP.Net, SQL Server, R Script, Windows, Windows Phone, AWS, SAP HANA and ABAP, like SAP UI5, Screen Personas, etc.

Cannot open backup device - Operating system error 5(failed to retrieve text for this error. Reason: 1815)

Last post 11-23-2011, 3:17 PM by eralper. 3 replies.
Sort Posts:
  •  01-02-2002, 4:14 PM 10396

    Cannot open backup device - Operating system error 5(failed to retrieve text for this error. Reason: 1815)

    Hello all,

    While I'm trying to restore a database backup to a SQL Server 2008 instance on my local computer, I got the following error messages.

    Operating system error 5(failed to retrieve text for this error. Reason: 1815)

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

    Cannot open backup device 'C:\SQLDatabases\dbname.bak'. Operating system error 5(failed to retrieve text for this error. Reason: 1815).
    RESTORE HEADERONLY is terminating abnormally. (Microsoft SQL Server, Error: 3201)

  •  01-02-2002, 4:17 PM 10397 in reply to 10396

    Re: Cannot open backup device - Operating system error 5(failed to retrieve text for this error. Reason: 1815)

    Hello,

    I added the built-in SQL Server user SQLServerMSSQLUser$machine_name$MSSQLSERVER with Full Control permission to the ACL (Access Control List) of the backup .bak file.

    Then the restore operation continued with success

  •  11-22-2011, 5:43 PM 22776 in reply to 10397

    Re: Cannot open backup device - Operating system error 5(failed to retrieve text for this error. Reason: 1815)

    I am getting the same error could you explain bit more clearly pls?
  •  11-23-2011, 3:17 PM 22778 in reply to 22776

    Re: Cannot open backup device - Operating system error 5(failed to retrieve text for this error. Reason: 1815)

    Hello faydor, SQL Server service must have access permissions on the folder where the SQL database backup file is. The error "Cannot open backup device - Operating system error 5" is probably because the SQL Service cannot read the backup file there
View as RSS news feed in XML
Copyright © 2004 - 2019 Eralper YILMAZ. All rights reserved.
Community Server by Telligent Systems