Solved

SQL 2000; Restore Database device error

Posted on 2007-03-27
5
402 Views
Last Modified: 2012-06-27
ALTER DATABASE DatabaseName
SET SINGLE_USER WITH ROLLBACK IMMEDIATE
GO
RESTORE DATABASE DatabaseName
   FROM DISK = 'F:\Nightly_Backups\DtabaseName.BAK'---> this disk on a network (don't know if that makes a difference)

I tried the above and I am getting this error:

Msg 3201, Level 16, State 2, Line 1
Cannot open backup device 'F:\Nightly_Backups\DtabaseName.BAK'. Device error or device off-line. See the SQL Server error log for more details.
Msg 3013, Level 16, State 1, Line 1
RESTORE DATABASE is terminating abnormally.

Any ideas.  Thanks.
0
Comment
Question by:yanci1179
  • 2
  • 2
5 Comments
 
LVL 20

Expert Comment

by:Sirees
Comment Utility
Copy the backup to the local machine/server and then do the restore.
0
 
LVL 16

Accepted Solution

by:
rboyd56 earned 500 total points
Comment Utility
You cannot restore from a mapped drive.

Create a share to the F drive on the remote machine and use a UNC connection:

ALTER DATABASE DatabaseName
SET SINGLE_USER WITH ROLLBACK IMMEDIATE
GO
RESTORE DATABASE DatabaseName
   FROM DISK = '\\servername\F\Nightly_Backups\DtabaseName.BAK'

The SQL Server service account must have access to the share on the remote machine.
0
 

Author Comment

by:yanci1179
Comment Utility
hi rboyd56,
I tried this but I am still getting the same error
0
 
LVL 16

Expert Comment

by:rboyd56
Comment Utility
Log onto the SQL Server machine as the SQL Server service account and see if you can access the share on the remote machine where you are trying to restore the database from. From the error it appears that this account does not have access to the share.

0
 

Author Comment

by:yanci1179
Comment Utility
Hi rboyd56,
your solution worked.  I had the wrong file. :-)

Thanks for your help!!
0

Featured Post

Free Gift Card with Acronis Backup Purchase!

Backup any data in any location: local and remote systems, physical and virtual servers, private and public clouds, Macs and PCs, tablets and mobile devices, & more! For limited time only, buy any Acronis backup products and get a FREE Amazon/Best Buy gift card worth up to $200!

Join & Write a Comment

Performance is the key factor for any successful data integration project, knowing the type of transformation that you’re using is the first step on optimizing the SSIS flow performance, by utilizing the correct transformation or the design alternat…
JSON is being used more and more, besides XML, and you surely wanted to parse the data out into SQL instead of doing it in some Javascript. The below function in SQL Server can do the job for you, returning a quick table with the parsed data.
Via a live example, show how to setup several different housekeeping processes for a SQL Server.
Viewers will learn how to use the SELECT statement in SQL and will be exposed to the many uses the SELECT statement has.

772 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

11 Experts available now in Live!

Get 1:1 Help Now