Sql-server – Adding another Secondary Log Shipping location

log-shippingsql-server-2016

I've seen a few variations of this question, but no clear cut answers to my situation.

I have an existing log shipping setup, and want to add a secondary server. Here is how I understand what will happen, please correct me if I am wrong.

  1. Restore backup from 12 hours ago to secondary, using no recovery.
  2. Add the secondary database to log shipping which creates the copy and restore job on the secondary and the copy job copies ALL
    the .trn files from shared backup location to secondary server. (no
    matter if they are needed or not)

  3. The restore job is able to look at the DB on the secondary and see what the last LSN applied is, then find the appropriate log
    backup to apply, then apply all subsequent log backups to bring the
    DB into a consistent state with the primary.

last questions is where I am not sure… Do I need to manually apply all the log backups since the full backup myself, or will log shipping work as I described above and do it automatically?

Best Answer

Yes, you should apply the latest FULL and all the applicable Transaction log backups in sequence after that full, manually on the secondary with no recovery, prior to setting up the log shipping jobs and turning them on (using the wizard with no initialization). When the log shipping wizard is used, it will, as you said, create the backup job on the primary and the copy and restore agent jobs on the secondary which looks for the next LSN to apply after the last one you applied manually when it starts applying the logs it needs for the log shipping process to begin.