Restoring backup DB in another Server

  • Hello,

    This is my first time to restore a backup db in another server. When I restore the Back-up db which is coming from a production Db, it has an error and the error is: "System.Data.SqlClient.SqlError: Directory lookup for the file "D:\Data_Files\OSM_eTech.mdf" failed with the operating system error 21(The device is not ready.). Microsoft.SqlServer.Smo)"

    The server that I used to restore has no drive D:\. Please help me how to resolve this.

  • Maria,

    you ned to use the MOVE TO option to provide the path where you want to place the database files. See BOL for the details

    Markus

    [font="Verdana"]Markus Bohse[/font]

  • Also if your using the online, go to the options page and replace the file names there. 

    Dont forget to use the replace option (SQL) or overwrite (GUI) options when doing the restore 

  • It is actually simple and no it has not changed you need to put the .bak file in the location below then go to Management Studio and right click tasks restore in the wizard click on restore from device and then click on the ellipse so SQL Server will create the file path.  This last part is very important because if you create the path SQL Server gets confused.  I just checked in my developement box it still works as 2000 the difference is the OLTP version is SQL 1.  Hope this helps.

    C:\Program Files\Microsoft SQL Server\MSSQL.1\MSSQL\Backup

     

    Kind regards,
    Gift Peddie

Viewing 4 posts - 1 through 3 (of 3 total)

You must be logged in to reply to this topic. Login to reply