SQL Server Performance

Restoration problem in Log shipping process

Discussion in 'General DBA Questions' started by itbhushan, Aug 11, 2003.

  1. itbhushan New Member

    Iam using the partial concept of log shipping, the backups created during the maintenance plan on the production server is basically been reused for restoring the standby database on the backup server. As per the maintenance plan daily at midnight backup of the production database say "test" is been created as test_db_200308120115.BAK at 1.00 am, now this backup file is automatically transferred from production server to backup server say at 2.00 am, now as per a job created schedule to run at 5.00 am this transferred backup file is been restored, but it gives an error for me during restoration.

    SP used for restoring the database :-

    CREATE PROCEDURE restore_match_backup AS

    restore database test
    from disk = ' C:MSSQL7BACKUP est_db_200308120115.BAK'
    WITH
    replace,
    standby = 'C:MSSQL7BACKUPundo_test.ldf',
    move 'test1_Data' to 'c:program filesmicrosoft sql servermssqldata est.mdf',
    move 'test1_Log' to 'c:program filesmicrosoft sql servermssqldata est_log.ldf'
    GO

    Now this works fine if i had created a backup by taking a backup device, which the maintenance plan does not takes in. Could any one please tell me the rectified script for restoring the database.

    Thanks

    Bhushan
  2. rushmada New Member

    What is the error u are getting while restoring the backup.

    Rushendra
  3. itbhushan New Member

    Now u see this is what i call a silly error, as seen above in the script <br /><br />" from disk = ' C:MSSQL7BACKUP est_db_200308120115.BAK' "<br /><br />i have kept an extra space between single colon & the path c:.... which was causing me the problem, after breaking my head for not less then 3 hrs i discovered the problem <img src='/community/emoticons/emotion-1.gif' alt=':)' />.<br /><br />so its solved, as i was very sure initially that there is no problem within the script.<br /><br />Thanks<br /><br />Bhushan

Share This Page