Results 1 to 7 of 7
  1. #1
    Join Date
    Mar 2009
    Posts
    4

    Question Unanswered: Restoring SQL 2000 file to SQL 2005

    Hi

    i have the back up of a SQL 2000 database and i tried to restore it on my SQL 2005 but i ran into this error

    TITLE: Microsoft SQL Server Management Studio
    ------------------------------

    Restore failed for Server 'XP\SQLEXPRESS'. (Microsoft.SqlServer.Smo)

    For help, click: Source: ID: ( ) - Events And Errors Message Center: Message Details

    ------------------------------
    ADDITIONAL INFORMATION:

    System.Data.SqlClient.SqlError: The operating system returned the error '5(error not found)' while attempting 'RestoreContainer::ValidateTargetForCreation' on 'C:\Program Files\Microsoft SQL Server\MSSQL.3\MSSQL\LMH.MDF'. (Microsoft.SqlServer.Smo)

    For help, click: http://go.microsoft.com/fwlink?ProdN...0&LinkId=20476

    The steps i followed

    right clicked on databases--->restore database

    from device---> specified the path to the backup --> it dint appear bec the file dint have an extension and so i typed the name of the file--->ok

    selected the single entry in the backupsets to restore

    the name of the db LMH was displayed in the drop down for To Database--> seleceted that..
    in the left pane in options selected the overwrite existing db--> ok and i got the error mentioned above..

    please help

  2. #2
    Join Date
    Jan 2003
    Location
    Massachusetts
    Posts
    5,799
    Provided Answers: 11
    Did you specify any option like "Overwrite existing database"? Operating system Error 5 is Access Denied.

  3. #3
    Join Date
    Mar 2009
    Posts
    4
    yes i did specify the option to overwrite the existing database.. wat could i do to fix the access permissions.

  4. #4
    Join Date
    Jan 2003
    Location
    Massachusetts
    Posts
    5,799
    Provided Answers: 11
    Check to see if someone has set any of the database files to be read only. Also, make sure that the SQL Server service is running as a local admin, or Local System.

  5. #5
    Join Date
    Dec 2007
    Location
    London, UK
    Posts
    741
    Use the RESTORE command to restore the backup. Don't use the Management Studio GUI. RESTORE gives you more control and better error messages. Be sure the target file path exists and that the server has read/write access to it.

  6. #6
    Join Date
    Mar 2009
    Posts
    4
    I used the Transact SQL RESTORE command but I still get the same error Msg 3201, Level 16, State 2, Line 1
    Cannot open backup device 'C:\Program Files\Microsoft SQL Server\MSSQL.3\MSSQL\Backup\LMHBKUP.bak'. Operating system error 2(error not found).
    Msg 3013, Level 16, State 1, Line 1
    RESTORE DATABASE is terminating abnormally.

    I also modified access permissions on the file to grant full permissions but it dint help.

  7. #7
    Join Date
    Mar 2009
    Posts
    4
    Thanks everyone!!.. i was able to solve this.. I created a db with the same name as the one to be imported.. added a .bak extension to the backup file bec it dint have an extension earlier..then used the RESTORE transact SQL with overwrite. and it worked..

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •