“No backupset selected to be restored” SQL Server 2012

前端 未结 21 1719
一向
一向 2020-12-04 08:36

I have a SQL Server 2012 database with filestream enabled. However, when I backup it and try to restore it on another SQL Server 2012 instance (on another machine), I simply

相关标签:
21条回答
  • 2020-12-04 08:46

    For me, it was because the backup file was still open by another process. Here's the event log:

    BackupDiskFile::OpenMedia: Backup device 'X:\Backups\MyDatabase\MyDatabase_backup_2014_08_22_132234_8270986.bak' failed to open. Operating system error 32(The process cannot access the file because it is being used by another process.).

    Simply closing and reopening Sql Server Management Studio resolved it (so obviously it was ssms.exe that had the handle..)

    0 讨论(0)
  • 2020-12-04 08:46

    I have run into the same issue. Run SSMS as administrator then right click and do database restore. Should work.

    0 讨论(0)
  • 2020-12-04 08:48

    I had the same issue with SQL Server 2014 (Management Studio could not see the folder in which the backup file resided, when attempting to locate it for a Restore operation). This thread held the answer that solved my problem. Quote:

    The SQL Server service account can be found by Start->Control Panel->Administrative Tools->Services. Double-click on the SQL Server service->Log On tab. You'll either be using the "Local System account" or "This account" to define a specific account. If you are using the Local System account, you won't be able to reference backups that are not local to the server. If, instead, you have defined the account to use, this is the account that needs to have access to the backup file location. Your ability to access the backups using your personal logon is irrelevant; it is the SQL Server account that is used, even though you are initiating the backup. Your IT people should be able to determine what rights are granted to each account.

    Hope that helps someone.

    0 讨论(0)
  • 2020-12-04 08:52

    Run SQL Server Management Studio as an administrator (right-click the shortcut/exe, then select "Run as Administrator"), then try to restore.

    0 讨论(0)
  • 2020-12-04 08:54

    My problem was that my user was in the Builtin-Administrators group and no user with Sysadmin-role on SQL Server. I just started the Management Studio as Administrator. This way it was possible to restore the database.

    0 讨论(0)
  • 2020-12-04 08:55

    I thought I was not stupid enough to mix up the versions - however, I didn't realize that on my new server, a SQL Server 2005 instance was already installed from birth named SQLEXPRESS. When trying to restore my SQL Server 2008 R2 backed up database in SSMS 2012 to the SQLEXPRESS instance, the list of backup sets was empty.

    Eventually I realized that the SQLEXPRESS instance on the server was not a 2012 instance, but a 2005. I disconnected and connected to the actual 2012 instance (in my case named SQLEXPRESS2012), and it (obviously) worked.

    0 讨论(0)
提交回复
热议问题