November 18, 2022 at 6:23 pm
I am trying to test to restore database from prod server to test server. It is a small database. On production server we have full backup at weekend, and then differential at weekday nights,
I am using UNC drive to connect to the backup location on production. I can add files of a full backup and a differential backup. It restored successfully. But if I do separately that is to do the full backup restore first with noRecovery, it is OK, then I do a separate restore with a differential backup, it will error out saying no full backup is selected.
Is there a way I can apply differential separately instead of having to do full and differential together?
Thanks
November 18, 2022 at 7:18 pm
No. A differential backup is just what the name implies. It is used to restored changes to the full backup. You can't restore the diff w/o first restoring the full.
November 18, 2022 at 7:37 pm
Thank you,
What I meant is can I restore the full backup and then differential backup at different time?
For example,
I restore full backup from production to test server database on Sunday night. with noRecovery mode.
Then at Monday night, can I just restore from differential backup to apply to the noRecovery mode test database?
Or I have to restore full again along with differential backup.
The test server database is just a copy for disaster recovery
Thanks,
November 18, 2022 at 7:51 pm
Only if you restore the full backup with no recovery (i.e., the database to which you restored is in restoring mode).
November 18, 2022 at 7:55 pm
Yes, that is what I did.
So first I restore the full backup with no recovery.
Then after an hour later I restore the database with diffrential only, then it errors out saying full backup is not selected.
November 18, 2022 at 9:38 pm
I found this can be done from T_SQL, but error out by using SSMS, it seems a bug from SSMS, or it has to select full backup in the list from SSMS along with differential or transaction log backups. It cannot do separately
November 20, 2022 at 2:59 pm
Post full backup restored as "No restore" option , it will accept only the next LSN differential backup, hope you are doing the same.
If in between some one restores a log or diff back, hope you are taking latest diff back or next log backup for the same?.
Post the error also.
Regards
Durai Nagarajan
November 21, 2022 at 6:42 pm
Thank you.
I found out if I use SSMS to do that, it failed with error: full backup not selected even I use the right LSN differential or transaction log backup.
But If I use T_SQL, it works fine. I am using SSMS 18.1.
This could be a defect of SSMS.
November 21, 2022 at 8:58 pm
You can prepare the restore with the settings and options with SSMS, but instead of running it, "Script to query window" and compare your T-SQL script with the SSMS generated script if you are curious about the differences.
November 21, 2022 at 9:00 pm
Yes, thanks that is what I did, in SSMS I have to choose the full backup and differential,
then I generated the script, and comment out the full backup line, and only run differential one, it works.
Viewing 10 posts - 1 through 9 (of 9 total)
You must be logged in to reply to this topic. Login to reply